Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.
Ruby b2b-commercee-commerceecommerceecommerce-apiecommerce-frameworkecommerce-platformheadlessheadless-commerceheadless-ecommercemarketplacemulti-tenantmulti-vendormulti-vendor-ecommerceopen-sourcespree-commerce
Changed Admin API to drop deprecated fields and typed country and currency codes
Damian Legawiec4d3e56a0ebe8
diff --git a/.changeset/typed-request-params.md b/.changeset/typed-request-params.mdindex e51283d110..3d57c9a19b 100644--- a/.changeset/typed-request-params.md+++ b/.changeset/typed-request-params.md@@ -6,3 +6,5 @@---Request body types are now generated from the API itself, so every create, update and action method takes exactly the fields its endpoint accepts. Fields the API never accepted are gone from the types, and fields it accepted but the types left out are added. Renamed types keep their old names as deprecated aliases (for example `VariantPrice` is now `PriceParams`, `LineItemInput` is now `LineItemInputParams`). The dashboard now saves the store's digital download limits, which the API used to drop.++Country and currency codes are typed as the closed `CountryCode` and `CurrencyCode` unions in both requests and responses. Deprecated fields are marked `@deprecated` in the types; the Store SDK keeps them until 6.1, while the Admin and Seller SDKs drop them (address `country_iso`/`state_abbr`, cart `number`, market `country_isos`, import `owner_type`/`owner_id`, payment method `auto_capture`).diff --git a/CLAUDE.md b/CLAUDE.mdindex 2409186920..a3b222c699 100644--- a/CLAUDE.md+++ b/CLAUDE.md@@ -244,7 +244,7 @@ The Store API (customer-facing) and Admin API (back-office) are two halves of th#### Flat request/response structure-API v3 uses flat params — no nested Rails-style wrapping. Declare a controller's writable attributes with **`request_params`** — one typed declaration that the controller permits from, the integration spec documents with `request_body_for`, and the SDK request types are generated from (`pnpm generate:params` → `src/types/params/`), so backend, OpenAPI and TypeScript cannot drift. Never hand-write a request body in an rswag spec or a request type in an SDK. Kinds: `string integer number decimal boolean date datetime id any object`; money is `decimal` (canonical string), never `number`. A shape two or more endpoints accept (address, price, stock level, media) is a class in `spree/api/app/request_schemas/` (`class AddressRequestSchema < Spree::Api::V3::RequestSchema`, `publishes 'XyzParams'` to give it its own type; Admin variants subclass the shared one, like serializers) — never copy a field list between controllers; a body used by one endpoint stays inline in its controller; a custom action declares `request_params 'XyzParams', action: :xyz`. `resource_permitted_attributes` (a plain list) still works but leaves the body undocumented and untyped. The base `permitted_attributes` appends extension-contributed attributes to it, and `permitted_params` permits and normalizes the result. `Spree::PermittedAttributes` and its model-name inference are **removed in 6.0** — a controller that declares neither `resource_permitted_attributes` nor `permitted_params` raises `NotImplementedError` on its first write.+API v3 uses flat params — no nested Rails-style wrapping. Declare a controller's writable attributes with **`request_params`** — one typed declaration that the controller permits from, the integration spec documents with `request_body_for`, and the SDK request types are generated from (`pnpm generate:params` → `src/types/params/`), so backend, OpenAPI and TypeScript cannot drift. Never hand-write a request body in an rswag spec or a request type in an SDK. Kinds: `string integer number decimal boolean date datetime id any object country currency`; money is `decimal` (canonical string), never `number`; a country or currency code is `country` / `currency`, never `string` — they publish the closed `CountryCode` / `CurrencyCode` types (from `Spree::IsoData.country_codes` and `Spree::Money::Rounding::CURRENCY_CODES`), which serializers declare with `enum_type_name: 'CountryCode'` / `'CurrencyCode'` so reads and writes share one type. A shape two or more endpoints accept (address, price, stock level, media) is a class in `spree/api/app/request_schemas/` (`class AddressRequestSchema < Spree::Api::V3::RequestSchema`, `publishes 'XyzParams'` to give it its own type; Admin variants subclass the shared one, like serializers) — never copy a field list between controllers; a body used by one endpoint stays inline in its controller; a custom action declares `request_params 'XyzParams', action: :xyz`. `resource_permitted_attributes` (a plain list) still works but leaves the body undocumented and untyped. The base `permitted_attributes` appends extension-contributed attributes to it, and `permitted_params` permits and normalizes the result. `Spree::PermittedAttributes` and its model-name inference are **removed in 6.0** — a controller that declares neither `resource_permitted_attributes` nor `permitted_params` raises `NotImplementedError` on its first write.Extensions add writable attributes to a core resource from an initializer, appending to the model's `additional_permitted_attributes` (a `class_attribute` on `Spree::Base`, default `[]`): `Spree::Product.additional_permitted_attributes += [:brand_id]`. Always `+=`, never `=` — assigning replaces what another extension added. Core STI subclasses set theirs with `self.additional_permitted_attributes = [...]` in the class body. Three rules that matter:@@ -417,6 +417,7 @@ end- **Registry-driven `type`** (the typed families above): plain `:string` + `comment:` listing the built-in shorthands. It *cannot* use `enum:` — registries fill in `to_prepare`/initializers, after serializer classes load, so generated types would depend on boot order and installed extensions. Cost: no autocomplete, no machine-readable list, and the comment is hand-maintained- Never use `typelize_from` — it connects to the database- **A deprecated field is marked, never only described.** Response attributes: `typelize state_abbr: [:string, nullable: true, deprecated: 'Use `state_code`. Removed in 6.1.']`. Request fields: `string :country_iso, deprecated: 'Use `country_code`. Removed in 6.1.'`. Both reach the API reference (`deprecated: true`) and the SDK types (`@deprecated`, struck through in editors). The message names the replacement and the release that removes it; a "Deprecated:" sentence in a `comment:` or `description:` alone is invisible to clients+- **Which API deprecates and which removes.** The Store API (the stable public contract) deprecates: a renamed or retired field keeps working, marked `deprecated:`, until the next minor release. Until 6.0 is stable, the Admin and Seller APIs remove instead — drop the field outright, move the dashboards to the replacement, and list it in the upgrade guide; an Admin/Seller serializer drops an inherited deprecated Store field with `_attributes.delete(:field)`. After 6.0 stable, the Admin and Seller APIs follow the Store API's deprecation procedure too- Customize via inheritance + `Spree.api.product_serializer = 'MyApp::ProductSerializer'`- NEVER create custom hash/arrays to represent associations or records inside the serializer - each record or a variant of a record (eg. lightweight variant of an existing serializer) should be it's own serializer- NEVER put too much logic in serializers, they should be lean and call models for custom methodsdiff --git a/docs/api-reference/admin.yaml b/docs/api-reference/admin.yamlindex cefa8d0684..3eef9e5d1e 100644--- a/docs/api-reference/admin.yaml+++ b/docs/api-reference/admin.yaml@@ -6396,8 +6396,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkmetadata: {}created_at: '2026-01-15T12:00:00.000Z'@@ -6496,8 +6494,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkmetadata: {}created_at: '2026-01-15T12:00:00.000Z'@@ -6587,8 +6583,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkmetadata: {}created_at: '2026-01-15T12:00:00.000Z'@@ -11781,8 +11775,6 @@ paths:status: pendingstore_id: store_UkLWZg9DAJseller_id:- owner_type: store- owner_id: store_UkLWZg9DAJuser_id: adm_UkLWZg9DAJprocessing_errors:delimiter: ","@@ -11988,8 +11980,6 @@ paths:status: mappingstore_id: store_UkLWZg9DAJseller_id:- owner_type: store- owner_id: store_UkLWZg9DAJuser_id: adm_UkLWZg9DAJprocessing_errors:delimiter: ","@@ -12459,8 +12449,6 @@ paths:status: pendingstore_id: store_UkLWZg9DAJseller_id:- owner_type: store- owner_id: store_UkLWZg9DAJuser_id: adm_UkLWZg9DAJprocessing_errors:delimiter: ","@@ -12724,8 +12712,6 @@ paths:status: completed_mappingstore_id: store_UkLWZg9DAJseller_id:- owner_type: store- owner_id: store_UkLWZg9DAJuser_id: adm_UkLWZg9DAJprocessing_errors:delimiter: ","@@ -13103,8 +13089,6 @@ paths:status: processingstore_id: store_UkLWZg9DAJseller_id:- owner_type: store- owner_id: store_UkLWZg9DAJuser_id: adm_UkLWZg9DAJprocessing_errors:delimiter: ","@@ -13465,8 +13449,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -13480,8 +13462,6 @@ paths:default: falsecountry_codes:- DE- country_isos:- - DEsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -13576,8 +13556,6 @@ paths:default: falsecountry_codes:- FR- country_isos:- - FRsupported_locales:- en- fr@@ -13680,8 +13658,6 @@ paths:default: falsecountry_codes:- DE- country_isos:- - DEsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -13763,8 +13739,6 @@ paths:default: falsecountry_codes:- DE- country_isos:- - DEsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -16704,8 +16678,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -17570,8 +17542,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -17920,8 +17890,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -18147,8 +18115,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -18305,8 +18271,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -18453,8 +18417,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -18653,8 +18615,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -18833,8 +18793,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -18974,8 +18932,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -19109,8 +19065,6 @@ paths:default: truecountry_codes:- US- country_isos:- - USsupported_locales:- encreated_at: '2026-01-15T12:00:00.000Z'@@ -20060,7 +20014,6 @@ paths:source_required: falsemetadata: {}active: true- auto_capture:capture_method:resolved_capture_method: checkoutstorefront_visible: true@@ -20120,7 +20073,6 @@ paths:source_required: falsemetadata: {}active: true- auto_capture:capture_method: manualresolved_capture_method: manualstorefront_visible: true@@ -20315,7 +20267,6 @@ paths:source_required: falsemetadata: {}active: true- auto_capture:capture_method:resolved_capture_method: checkoutstorefront_visible: true@@ -20367,7 +20318,6 @@ paths:source_required: falsemetadata: {}active: true- auto_capture:capture_method:resolved_capture_method: checkoutstorefront_visible: false@@ -38551,8 +38501,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkmetadata: {}created_at: '2026-01-15T12:00:00.000Z'@@ -38635,8 +38583,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: true- state_abbr: NY- country_iso: USstate_name: New Yorkmetadata: {}created_at: '2026-01-15T12:00:00.000Z'@@ -47238,8 +47184,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr:- country_iso: GBstate_name:metadata: {}created_at: '2026-01-15T12:00:00.000Z'@@ -51470,6 +51414,247 @@ components:type: stringcountry_code:type: string+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWstate_text:type: stringnullable: true@@ -51482,13 +51667,6 @@ components:type: booleanis_default_shipping:type: boolean- state_abbr:- type: string- nullable: true- deprecated: true- country_iso:- type: string- deprecated: truestate_name:type: stringnullable: true@@ -51532,8 +51710,6 @@ components:- quick_checkout- is_default_billing- is_default_shipping- - state_abbr- - country_iso- state_name- metadata- created_at@@ -51734,9 +51910,6 @@ components:po_document_byte_size:type: numbernullable: true- number:- type: string- deprecated: truetoken:type: stringemail:@@ -51750,6 +51923,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRlocale:type: stringnullable: true@@ -51862,7 +52214,6 @@ components:- po_number_required- po_document_filename- po_document_byte_size- - number- token- customer_note@@ -51933,6 +52284,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRcreated_at:type: stringupdated_at:@@ -51960,6 +52490,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRsource:type: stringenum:@@ -52585,12 +53294,432 @@ components:- fixedcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRtaxability_reason:type: stringnullable: truecountry_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWstate_code:type: stringnullable: true@@ -53789,6 +54918,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWstate_code:type: stringnullable: true@@ -54770,6 +56140,185 @@ components:currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRprefix:type: stringnullable: true@@ -54818,6 +56367,185 @@ components:more.currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRamount:type: stringamount_used:@@ -54977,14 +56705,6 @@ components:seller_id:type: stringnullable: true- owner_type:- type: string- nullable: true- deprecated: true- owner_id:- type: string- nullable: true- deprecated: trueuser_id:type: stringnullable: true@@ -55036,8 +56756,6 @@ components:- status- store_id- seller_id- - owner_type- - owner_id- user_id- processing_errors- delimiter@@ -55160,6 +56878,185 @@ components:type: numbercurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRname:type: stringslug:@@ -55280,6 +57177,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRdefault_locale:type: stringtax_inclusive:@@ -55290,11 +57366,247 @@ components:type: arrayitems:type: string- country_isos:- type: array- items:- type: string- deprecated: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWsupported_locales:type: arrayitems:@@ -55320,7 +57632,6 @@ components:- tax_inclusive- default- country_codes- - country_isos- supported_locales- created_at- updated_at@@ -55625,6 +57936,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRtotal:type: stringnullable: true@@ -55790,6 +58280,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRlocale:type: stringnullable: true@@ -56212,9 +58881,6 @@ components:type: objectactive:type: boolean- auto_capture:- type: boolean- nullable: truecapture_method:type: stringenum:@@ -56255,7 +58921,6 @@ components:- source_required- metadata- active- - auto_capture- capture_method- resolved_capture_method- storefront_visible@@ -56390,6 +59055,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRcreated_at:type: stringupdated_at:@@ -56510,6 +59354,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRamount:type: stringnullable: true@@ -56684,6 +59707,185 @@ components:currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRamount:type: stringnullable: true@@ -57283,6 +60485,185 @@ components:currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRcreated_at:type: stringupdated_at:@@ -57343,6 +60724,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRreference:type: stringnullable: true@@ -57793,8 +61353,366 @@ components:properties:currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRsettlement_currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRconverted:type: booleanseller_id:@@ -57839,6 +61757,185 @@ components:more.currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRreference:type: stringnullable: true@@ -58235,6 +62332,185 @@ components:more.currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRreference:type: stringnullable: true@@ -58252,6 +62528,185 @@ components:settled_currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRconverted:type: booleanseller_id:@@ -58346,6 +62801,185 @@ components:currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRformat:type: stringnullable: true@@ -58507,6 +63141,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWcountry_name:type: stringnullable: true@@ -59079,6 +63954,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRmemo:type: stringnullable: true@@ -59138,6 +64192,185 @@ components:type: stringdefault_currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRdefault_locale:type: stringdefault_country_code:@@ -59316,6 +64549,185 @@ components:type: arrayitems:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRsupported_locales:type: arrayitems:@@ -59436,6 +64848,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWpostal_code:type: stringnullable: true@@ -59542,6 +65195,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWstate_code:type: stringnullable: true@@ -59694,6 +65588,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWstate_code:type: stringnullable: true@@ -59767,6 +65902,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWstate_code:type: stringnullable: true@@ -59895,6 +66271,185 @@ components:cost_currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRbarcode:type: stringnullable: true@@ -59907,6 +66462,247 @@ components:country_of_origin:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWcustoms_description:type: stringnullable: true@@ -61031,6 +67827,430 @@ components:required:- type- preferences+ CurrencyCode:+ type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWR+ CountryCode:+ type: string+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWAddressInputParams:type: objectproperties:@@ -61056,7 +68276,8 @@ components:type: stringdescription: Legacy spelling of `postal_code`; send only one of the two.country_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 code, such as `US`.example: USstate_code:@@ -61189,7 +68410,8 @@ components:type: objectproperties:currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: ISO 4217 code. Required on create; one minimum per currency.example: USDamount:@@ -61993,7 +69215,8 @@ components:type: stringdescription: Legacy spelling of `postal_code`; send only one of the two.country_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 code, such as `US`.example: USstate_code:@@ -62187,7 +69410,8 @@ components:type: stringdescription: Legacy spelling of `postal_code`; send only one of the two.country_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 code, such as `US`.example: USstate_code:@@ -62316,7 +69540,8 @@ components:pattern: "^-?\\d+(\\.\\d+)?$"example: '50.00'currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"example: USDmemo:type: string@@ -62677,7 +69902,8 @@ components:- state- postal_codecountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"example: USstate_code:type: string@@ -63297,7 +70523,8 @@ components:batches over `gift_card_batch_web_limit` generate in the background.example: 100currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: ISO 4217 currency code. Defaults to the store currency.example: USDexpires_at:@@ -63319,7 +70546,8 @@ components:description: Greater than zero.example: '25.00'currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: ISO 4217 currency code. Defaults to the store currency.example: USDcode:@@ -63349,7 +70577,8 @@ components:description: Greater than zero.example: '25.00'currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: ISO 4217 currency code. Defaults to the store currency.example: USDcode:@@ -63528,7 +70757,8 @@ components:description: Display name, unique within the store.example: Europecurrency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: ISO 4217 currency code.example: EURdefault_locale:@@ -63562,7 +70792,7 @@ components:country_codes:type: arrayitems:- type: string+ "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 codes of the countries in this market. Atleast one is required.example:@@ -63581,7 +70811,8 @@ components:description: Display name, unique within the store.example: Europecurrency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: ISO 4217 currency code.example: EURdefault_locale:@@ -63615,7 +70846,7 @@ components:country_codes:type: arrayitems:- type: string+ "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 codes of the countries in this market. Atleast one is required.example:@@ -64018,7 +71249,8 @@ components:description: With `customer_id`, copies the customer's saved billing andshipping addresses onto the order.currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"example: USDmarket_id:type: string@@ -64150,7 +71382,8 @@ components:customer_id:type: stringcurrency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"example: USDmarket_id:type: string@@ -64420,11 +71653,6 @@ components:type: booleandescription: False keeps the method to the dashboard; true also offers iton the storefront.- auto_capture:- type: boolean- description: 'Deprecated: Use `capture_method`. Removed in 6.1.'- deprecated: true- nullable: truecapture_method:type: stringenum:@@ -64461,11 +71689,6 @@ components:type: booleandescription: False keeps the method to the dashboard; true also offers iton the storefront.- auto_capture:- type: boolean- description: 'Deprecated: Use `capture_method`. Removed in 6.1.'- deprecated: true- nullable: truecapture_method:type: stringenum:@@ -64563,7 +71786,8 @@ components:type: stringexample: variant_xY9currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"example: USDprice_list_id:type: string@@ -64597,7 +71821,8 @@ components:type: stringexample: variant_xY9currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"example: USDmin_quantity:type: integer@@ -64697,7 +71922,8 @@ components:type: stringexample: variant_xY9currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"example: USDmin_quantity:type: integer@@ -64797,7 +72023,8 @@ components:type: objectproperties:currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"example: USDamount:type: string@@ -64822,7 +72049,8 @@ components:type: stringexample: variant_xY9currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"example: USDmin_quantity:type: integer@@ -65343,7 +72571,7 @@ components:pattern: "^-?\\d+(\\.\\d+)?$"nullable: truecost_currency:- type: string+ "$ref": "#/components/schemas/CurrencyCode"weight:type: numbernullable: true@@ -65372,10 +72600,10 @@ components:- fths_code:type: string- country_of_origin:- type: stringcustoms_description:type: string+ country_of_origin:+ "$ref": "#/components/schemas/CountryCode"minimum_order_quantity:type: integernullable: true@@ -65759,7 +72987,8 @@ components:type: stringexample: sloc_1234567890currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: Defaults to the store's currency; set it for a foreign-currencyorder.example: USD@@ -65819,7 +73048,8 @@ components:type: stringexample: sloc_1234567890currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: Defaults to the store's currency; set it for a foreign-currencyorder.example: USD@@ -65975,7 +73205,7 @@ components:type: integerdescription: At most 1000.currency:- type: string+ "$ref": "#/components/schemas/CurrencyCode"required:- metricsReturnCancelParams:@@ -66160,7 +73390,8 @@ components:type: stringdescription: Legacy spelling of `postal_code`; send only one of the two.country_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 code, such as `US`.example: USstate_code:@@ -66526,7 +73757,8 @@ components:type: stringexample: My Storecountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 country the store sells from. It determinesthe default market, the warehouse, the delivery zones and the currency.example: US@@ -66535,7 +73767,8 @@ components:description: Storefront locale. Defaults to the country's own language.example: encurrency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: 'ISO 4217 currency. Defaults to the country''s own currency:pass one only when the store prices in something else.'example: USD@@ -66574,7 +73807,8 @@ components:description: What the merchant paid the carrier. Accounting data only; itnever touches the order's shipping charge.currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: Currency of the cost.file_format:type: string@@ -66728,7 +73962,8 @@ components:type: stringnullable: truecountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO-3166 alpha-2 country code.example: USnullable: true@@ -66818,7 +74053,8 @@ components:type: stringnullable: truecountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO-3166 alpha-2 country code.example: USnullable: true@@ -67054,14 +74290,6 @@ components:- manualdescription: The store-wide default for when a customer is charged ratherthan only authorized. A payment method's own setting wins when set.- preferred_auto_capture:- type: boolean- description: 'Deprecated: Use `capture_method`. Removed in 6.1.'- deprecated: true- preferred_auto_capture_on_dispatch:- type: boolean- description: 'Deprecated: Use `capture_method`. Removed in 6.1.'- deprecated: truetrack_inventory_levels:type: booleandescription: Counts on-hand quantities. Off means everything is treated@@ -67277,7 +74505,8 @@ components:example: NYnullable: truecountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"example: USnullable: truepostal_code:@@ -67330,7 +74559,8 @@ components:example: NYnullable: truecountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"example: USnullable: truepostal_code:@@ -67393,12 +74623,13 @@ components:format: date-timenullable: truecountry_code:- type: string- description: Where the certificate holds. Omit both for one valid everywhere.+ allOf:+ - "$ref": "#/components/schemas/CountryCode"+ description: Where the certificate holds. Omit it and `state_code` for one+ valid everywhere.nullable: truestate_code:type: string- description: Where the certificate holds. Omit both for one valid everywhere.nullable: truedocument_signed_id:type: string@@ -67446,7 +74677,8 @@ components:tax_category_id:type: stringcountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO country code. A rate naming no country taxes everywhere.example: DEnullable: true@@ -67509,7 +74741,7 @@ components:pattern: "^-?\\d+(\\.\\d+)?$"nullable: truecost_currency:- type: string+ "$ref": "#/components/schemas/CurrencyCode"weight:type: numbernullable: true@@ -67538,10 +74770,10 @@ components:- fths_code:type: string- country_of_origin:- type: stringcustoms_description:type: string+ country_of_origin:+ "$ref": "#/components/schemas/CountryCode"minimum_order_quantity:type: integernullable: true@@ -67648,7 +74880,7 @@ components:pattern: "^-?\\d+(\\.\\d+)?$"nullable: truecost_currency:- type: string+ "$ref": "#/components/schemas/CurrencyCode"weight:type: numbernullable: true@@ -67677,10 +74909,10 @@ components:- fths_code:type: string- country_of_origin:- type: stringcustoms_description:type: string+ country_of_origin:+ "$ref": "#/components/schemas/CountryCode"minimum_order_quantity:type: integernullable: truediff --git a/docs/api-reference/seller.yaml b/docs/api-reference/seller.yamlindex cd164f87ab..51636197c7 100644--- a/docs/api-reference/seller.yaml+++ b/docs/api-reference/seller.yaml@@ -17133,8 +17133,6 @@ paths:status: pendingstore_id: store_UkLWZg9DAJseller_id: sel_UkLWZg9DAJ- owner_type: seller- owner_id: sel_UkLWZg9DAJuser_id: adm_UkLWZg9DAJprocessing_errors:delimiter: ","@@ -17337,8 +17335,6 @@ paths:status: mappingstore_id: store_UkLWZg9DAJseller_id: sel_UkLWZg9DAJ- owner_type: seller- owner_id: sel_UkLWZg9DAJuser_id: adm_UkLWZg9DAJprocessing_errors:delimiter: ","@@ -17830,8 +17826,6 @@ paths:status: completed_mappingstore_id: store_UkLWZg9DAJseller_id: sel_UkLWZg9DAJ- owner_type: seller- owner_id: sel_UkLWZg9DAJuser_id: adm_UkLWZg9DAJprocessing_errors:delimiter: ","@@ -18407,8 +18401,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkbilling_address:id: addr_UkLWZg9DAJ@@ -18429,8 +18421,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkmeta:page: 1@@ -18594,8 +18584,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkbilling_address:id: addr_UkLWZg9DAJ@@ -18616,8 +18604,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkschema:"$ref": "#/components/schemas/Order"@@ -18777,8 +18763,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkbilling_address:id: addr_UkLWZg9DAJ@@ -18799,8 +18783,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkschema:"$ref": "#/components/schemas/Order"@@ -18952,8 +18934,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkbilling_address:id: addr_UkLWZg9DAJ@@ -18974,8 +18954,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkschema:"$ref": "#/components/schemas/Order"@@ -19136,8 +19114,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkbilling_address:id: addr_UkLWZg9DAJ@@ -19158,8 +19134,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkschema:"$ref": "#/components/schemas/Order"@@ -19295,8 +19269,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkbilling_address:id: addr_UkLWZg9DAJ@@ -19317,8 +19289,6 @@ paths:quick_checkout: falseis_default_billing: falseis_default_shipping: false- state_abbr: NY- country_iso: USstate_name: New Yorkschema:"$ref": "#/components/schemas/Order"@@ -21277,89 +21247,6 @@ components:additionalProperties: truerequired:- providers- Address:- type: object- properties:- id:- type: string- label:- type: string- nullable: true- first_name:- type: string- nullable: true- last_name:- type: string- nullable: true- full_name:- type: string- address1:- type: string- nullable: true- address2:- type: string- nullable: true- postal_code:- type: string- nullable: true- city:- type: string- nullable: true- phone:- type: string- nullable: true- company:- type: string- nullable: true- country_name:- type: string- country_code:- type: string- state_text:- type: string- nullable: true- state_code:- type: string- nullable: true- quick_checkout:- type: boolean- is_default_billing:- type: boolean- is_default_shipping:- type: boolean- state_abbr:- type: string- nullable: true- deprecated: true- country_iso:- type: string- deprecated: true- state_name:- type: string- nullable: true- required:- - id- - label- - first_name- - last_name- - full_name- - address1- - address2- - postal_code- - city- - phone- - company- - country_name- - country_code- - state_text- - state_code- - quick_checkout- - is_default_billing- - is_default_shipping- - state_abbr- - country_iso- - state_name- x-typelizer: trueCategory:type: objectproperties:@@ -21554,13 +21441,686 @@ components:- avatar_url- selected_localex-typelizer: true+ Address:+ type: object+ properties:+ id:+ type: string+ label:+ type: string+ nullable: true+ first_name:+ type: string+ nullable: true+ last_name:+ type: string+ nullable: true+ full_name:+ type: string+ address1:+ type: string+ nullable: true+ address2:+ type: string+ nullable: true+ postal_code:+ type: string+ nullable: true+ city:+ type: string+ nullable: true+ phone:+ type: string+ nullable: true+ company:+ type: string+ nullable: true+ country_name:+ type: string+ country_code:+ type: string+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZW+ state_text:+ type: string+ nullable: true+ state_code:+ type: string+ nullable: true+ quick_checkout:+ type: boolean+ is_default_billing:+ type: boolean+ is_default_shipping:+ type: boolean+ state_name:+ type: string+ nullable: true+ required:+ - id+ - label+ - first_name+ - last_name+ - full_name+ - address1+ - address2+ - postal_code+ - city+ - phone+ - company+ - country_name+ - country_code+ - state_text+ - state_code+ - quick_checkout+ - is_default_billing+ - is_default_shipping+ - state_name+ x-typelizer: trueBalance:type: objectproperties:currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRsettlement_currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRconverted:type: booleanearned:@@ -22352,14 +22912,6 @@ components:seller_id:type: stringnullable: true- owner_type:- type: string- nullable: true- deprecated: true- owner_id:- type: string- nullable: true- deprecated: trueuser_id:type: stringnullable: true@@ -22405,8 +22957,6 @@ components:- status- store_id- seller_id- - owner_type- - owner_id- user_id- processing_errors- delimiter@@ -22570,6 +23120,185 @@ components:type: numbercurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRprice:type: stringnullable: true@@ -22617,6 +23346,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRtotal_quantity:type: numberstatus:@@ -22844,6 +23752,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRcreated_at:type: stringauthorized_amount:@@ -22878,6 +23965,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRreference:type: stringnullable: true@@ -22947,6 +24213,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRamount:type: stringnullable: true@@ -22966,6 +24411,185 @@ components:currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRamount:type: stringnullable: true@@ -23266,10 +24890,368 @@ components:type: booleandefault_currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRsupported_currencies:type: arrayitems:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRproducts_count:type: numberbilling_address:@@ -23624,6 +25606,185 @@ components:currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRformat:type: stringnullable: true@@ -23733,6 +25894,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWcountry_name:type: stringnullable: true@@ -23874,6 +26276,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRreference:type: stringnullable: true@@ -23889,6 +26470,185 @@ components:settled_currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRconverted:type: booleanorder_id:@@ -24032,6 +26792,185 @@ components:cost_currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRbarcode:type: stringnullable: true@@ -24044,6 +26983,247 @@ components:country_of_origin:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWcustoms_description:type: stringnullable: true@@ -24386,6 +27566,430 @@ components:required:- type- preferences+ CurrencyCode:+ type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWR+ CountryCode:+ type: string+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWAccountUpdateParams:type: objectproperties:@@ -24883,7 +28487,8 @@ components:type: stringnullable: truecountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"example: USOrderCancelParams:type: object@@ -25093,7 +28698,8 @@ components:type: objectproperties:currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: Omit to price in the store's currency. A seller has nocurrency of their own.example: USD@@ -25282,7 +28888,8 @@ components:type: stringdescription: Legacy spelling of `postal_code`; send only one of the two.country_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 code, such as `US`.example: USstate_code:@@ -25379,7 +28986,7 @@ components:pattern: "^-?\\d+(\\.\\d+)?$"nullable: truecost_currency:- type: string+ "$ref": "#/components/schemas/CurrencyCode"weight:type: numbernullable: true@@ -25408,10 +29015,10 @@ components:- fths_code:type: string- country_of_origin:- type: stringcustoms_description:type: string+ country_of_origin:+ "$ref": "#/components/schemas/CountryCode"minimum_order_quantity:type: integernullable: true@@ -25465,7 +29072,8 @@ components:type: objectproperties:currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: Omit to price in the store's currency. A seller has nocurrency of their own.example: USD@@ -25529,7 +29137,8 @@ components:description: What the seller paid the carrier. Accounting data only; itnever touches the order's shipping charge.currency:- type: string+ allOf:+ - "$ref": "#/components/schemas/CurrencyCode"description: Currency of the cost.file_format:type: string@@ -25612,7 +29221,8 @@ components:type: stringnullable: truecountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO-3166 alpha-2 country code.example: USnullable: truediff --git a/docs/api-reference/store.yaml b/docs/api-reference/store.yamlindex 1e95e3e4d1..ce1eff6067 100644--- a/docs/api-reference/store.yaml+++ b/docs/api-reference/store.yaml@@ -13433,6 +13433,247 @@ components:type: stringcountry_code:type: string+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWstate_text:type: stringnullable: true@@ -13560,6 +13801,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRlocale:type: stringnullable: true@@ -14576,6 +14996,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWstate_code:type: stringnullable: true@@ -15127,6 +15788,185 @@ components:currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRprefix:type: stringnullable: true@@ -15175,6 +16015,185 @@ components:more.currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRamount:type: stringnullable: true@@ -15305,14 +16324,6 @@ components:seller_id:type: stringnullable: true- owner_type:- type: string- nullable: true- deprecated: true- owner_id:- type: string- nullable: true- deprecated: trueuser_id:type: stringnullable: true@@ -15326,8 +16337,6 @@ components:- status- store_id- seller_id- - owner_type- - owner_id- user_idx-typelizer: trueInvitation:@@ -15412,6 +16421,185 @@ components:type: numbercurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRname:type: stringslug:@@ -15547,6 +16735,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRdefault_locale:type: stringtax_inclusive:@@ -15557,6 +16924,247 @@ components:type: arrayitems:type: string+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWcountry_isos:type: arrayitems:@@ -15827,6 +17435,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRtotal:type: stringnullable: true@@ -15938,6 +17725,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRlocale:type: stringnullable: true@@ -16271,6 +18237,185 @@ components:more.currency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRexternal_id:type: stringexternal_data:@@ -16406,6 +18551,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRamount:type: stringnullable: true@@ -16428,6 +18752,185 @@ components:currency:type: stringnullable: true+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRamount:type: stringnullable: true@@ -16593,6 +19096,185 @@ components:type: stringcurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRrequired:- id- type@@ -17232,6 +19914,247 @@ components:country_code:type: stringnullable: true+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZWcountry_name:type: stringnullable: true@@ -17420,6 +20343,185 @@ components:nullable: truecurrency:type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRrequired:- id- amount@@ -17694,6 +20796,430 @@ components:- is_default- is_privatex-typelizer: true+ CountryCode:+ type: string+ enum:+ - AD+ - AE+ - AF+ - AG+ - AI+ - AL+ - AM+ - AO+ - AR+ - AS+ - AT+ - AU+ - AW+ - AZ+ - BA+ - BB+ - BD+ - BE+ - BF+ - BG+ - BH+ - BI+ - BJ+ - BL+ - BM+ - BN+ - BO+ - BQ+ - BR+ - BS+ - BT+ - BW+ - BY+ - BZ+ - CA+ - CC+ - CD+ - CF+ - CG+ - CH+ - CI+ - CK+ - CL+ - CM+ - CN+ - CO+ - CR+ - CU+ - CV+ - CW+ - CX+ - CY+ - CZ+ - DE+ - DJ+ - DK+ - DM+ - DO+ - DZ+ - EC+ - EE+ - EG+ - ER+ - ES+ - ET+ - FI+ - FJ+ - FK+ - FM+ - FO+ - FR+ - GA+ - GB+ - GD+ - GE+ - GF+ - GG+ - GH+ - GI+ - GL+ - GM+ - GN+ - GP+ - GQ+ - GR+ - GT+ - GU+ - GW+ - GY+ - HK+ - HN+ - HR+ - HT+ - HU+ - ID+ - IE+ - IL+ - IM+ - IN+ - IQ+ - IR+ - IS+ - IT+ - JE+ - JM+ - JO+ - JP+ - KE+ - KG+ - KH+ - KI+ - KM+ - KN+ - KP+ - KR+ - KW+ - KY+ - KZ+ - LA+ - LB+ - LC+ - LI+ - LK+ - LR+ - LS+ - LT+ - LU+ - LV+ - LY+ - MA+ - MC+ - MD+ - ME+ - MF+ - MG+ - MH+ - MK+ - ML+ - MM+ - MN+ - MO+ - MP+ - MQ+ - MR+ - MS+ - MT+ - MU+ - MV+ - MW+ - MX+ - MY+ - MZ+ - NA+ - NC+ - NE+ - NF+ - NG+ - NI+ - NL+ - 'NO'+ - NP+ - NR+ - NU+ - NZ+ - OM+ - PA+ - PE+ - PF+ - PG+ - PH+ - PK+ - PL+ - PM+ - PN+ - PR+ - PS+ - PT+ - PW+ - PY+ - QA+ - RE+ - RO+ - RS+ - RU+ - RW+ - SA+ - SB+ - SC+ - SD+ - SE+ - SG+ - SH+ - SI+ - SJ+ - SK+ - SL+ - SM+ - SN+ - SO+ - SR+ - SS+ - ST+ - SV+ - SX+ - SY+ - SZ+ - TC+ - TD+ - TG+ - TH+ - TJ+ - TK+ - TL+ - TM+ - TN+ - TO+ - TR+ - TT+ - TV+ - TW+ - TZ+ - UA+ - UG+ - US+ - UY+ - UZ+ - VA+ - VC+ - VE+ - VG+ - VI+ - VN+ - VU+ - WF+ - WS+ - YE+ - YT+ - ZA+ - ZM+ - ZW+ CurrencyCode:+ type: string+ enum:+ - AED+ - AFN+ - ALL+ - AMD+ - ANG+ - AOA+ - ARS+ - AUD+ - AWG+ - AZN+ - BAM+ - BBD+ - BDT+ - BGN+ - BHD+ - BIF+ - BMD+ - BND+ - BOB+ - BRL+ - BSD+ - BTN+ - BWP+ - BYN+ - BYR+ - BZD+ - CAD+ - CDF+ - CHF+ - CLF+ - CLP+ - CNY+ - COP+ - CRC+ - CUC+ - CUP+ - CVE+ - CZK+ - DJF+ - DKK+ - DOP+ - DZD+ - EEK+ - EGP+ - ERN+ - ETB+ - EUR+ - FJD+ - FKP+ - GBP+ - GEL+ - GHS+ - GIP+ - GMD+ - GNF+ - GTQ+ - GYD+ - HKD+ - HNL+ - HRK+ - HTG+ - HUF+ - IDR+ - ILS+ - INR+ - IQD+ - IRR+ - ISK+ - JMD+ - JOD+ - JPY+ - KES+ - KGS+ - KHR+ - KMF+ - KPW+ - KRW+ - KWD+ - KYD+ - KZT+ - LAK+ - LBP+ - LKR+ - LRD+ - LSL+ - LTL+ - LVL+ - LYD+ - MAD+ - MDL+ - MGA+ - MKD+ - MMK+ - MNT+ - MOP+ - MRO+ - MRU+ - MTL+ - MUR+ - MVR+ - MWK+ - MXN+ - MYR+ - MZN+ - NAD+ - NGN+ - NIO+ - NOK+ - NPR+ - NZD+ - OMR+ - PAB+ - PEN+ - PGK+ - PHP+ - PKR+ - PLN+ - PYG+ - QAR+ - RON+ - RSD+ - RUB+ - RWF+ - SAR+ - SBD+ - SCR+ - SDG+ - SEK+ - SGD+ - SHP+ - SKK+ - SLE+ - SLL+ - SOS+ - SRD+ - SSP+ - STD+ - STN+ - SVC+ - SYP+ - SZL+ - THB+ - TJS+ - TMM+ - TMT+ - TND+ - TOP+ - TRY+ - TTD+ - TWD+ - TZS+ - UAH+ - UGX+ - USD+ - UYI+ - UYU+ - UYW+ - UZS+ - VED+ - VEF+ - VES+ - VND+ - VUV+ - WST+ - XAF+ - XCD+ - XCG+ - XOF+ - XPF+ - YER+ - ZAR+ - ZMK+ - ZMW+ - ZWD+ - ZWG+ - ZWL+ - ZWN+ - ZWRAcceptCompanyInvitationParams:type: objectproperties:@@ -17761,7 +21287,8 @@ components:phone:type: stringcountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 country code, such as `US` or `DE`.example: USstate_code:@@ -17837,7 +21364,8 @@ components:phone:type: stringcountry_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 country code, such as `US` or `DE`.example: USstate_code:@@ -17885,7 +21413,8 @@ components:type: stringdescription: Legacy spelling of `postal_code`; send only one of the two.country_code:- type: string+ allOf:+ - "$ref": "#/components/schemas/CountryCode"description: ISO 3166-1 alpha-2 code, such as `US`.example: USstate_code:@@ -17933,7 +21462,7 @@ components:market_id:type: stringcurrency:- type: string+ "$ref": "#/components/schemas/CurrencyCode"locale:type: stringshipping_address_id:@@ -18287,7 +21816,7 @@ components:market_id:type: stringcurrency:- type: string+ "$ref": "#/components/schemas/CurrencyCode"locale:type: stringshipping_address_id:diff --git a/docs/developer/customization/api.mdx b/docs/developer/customization/api.mdxindex 37cd5a622a..b7b8b3d8dc 100644--- a/docs/developer/customization/api.mdx+++ b/docs/developer/customization/api.mdx@@ -198,6 +198,7 @@ controller, the reference and the TypeScript types cannot drift apart.| `decimal` | a canonical decimal string (`"19.99"`) — every amount of money || `number` | a JSON number — weights, dimensions, coordinates || `id` | a prefixed ID (`brand_k5nR8xLq`) |+| `country`, `currency` | an ISO 3166-1 alpha-2 or ISO 4217 code, typed `CountryCode` / `CurrencyCode` || `date`, `datetime` | ISO 8601 strings || `object` | a nested hash: any keys, a block of fields, or a shared `shape:` || `any` | a scalar, a list or a hash |diff --git a/docs/developer/upgrades/5.6-to-6.0.mdx b/docs/developer/upgrades/5.6-to-6.0.mdxindex 405a395cc4..259f368a62 100644--- a/docs/developer/upgrades/5.6-to-6.0.mdx+++ b/docs/developer/upgrades/5.6-to-6.0.mdx@@ -358,6 +358,19 @@ The full address surface is shared by Cart and Order through `Spree::Purchase::A- **`use_billing` is deprecated** (removed in 6.1): the shipping address is canonical — use `use_shipping` to copy ship → bill.- The `firstname`, `lastname` and `zipcode` **columns are renamed** to `first_name`, `last_name` and `postal_code`. The API has used the new names since 5.4, but two things carried the old ones and now change: **validation error keys** (a client sending `postal_code` used to get its error back under `zipcode`) and **Ransack filter keys** (`q[zipcode_cont]` becomes `q[postal_code_cont]`). The old method names still read for one release. The Admin and Seller APIs no longer accept `firstname` and `lastname` in an address payload: send `first_name` and `last_name`.+**The Admin and Seller APIs drop their deprecated fields in 6.0.** The Store API keeps its deprecated fields until 6.1, marked `deprecated` in the API reference and the SDK types; the Admin and Seller APIs remove theirs now:++| Removed from the Admin and Seller APIs | Use |+|---|---|+| Address `country_iso`, `state_abbr` (read and write) | `country_code`, `state_code` |+| Admin cart `number` | `id` |+| Admin market `country_isos` | `country_codes` |+| Import `owner_type`, `owner_id` | `store_id`, `seller_id` |+| Payment method `auto_capture` (read and write) | `capture_method` |+| Store settings `preferred_auto_capture`, `preferred_auto_capture_on_dispatch` | `capture_method` |+| Settings sent under their `preferred_<name>` key | `<name>` |+| Delivery method `calculator_type`, `calculator_preferences` | `calculator: { type, preferences }` |+## Returns, exchanges and claimsThe `ReturnAuthorization → CustomerReturn → Reimbursement` chain is replaced by three first-class records that each belong directly to an order: **`Spree::Return`** (items come back, money goes back), **`Spree::Exchange`** (items come back, different items go out), and **`Spree::Claim`** (something went wrong in delivery — no items required back).@@ -582,7 +595,7 @@ Settings no longer reach the Admin and Seller APIs in the shape of Ruby's prefer| Import (Admin and Seller) | `preferred_delimiter` | `delimiter` || Seller profile | `preferred_timezone` | `timezone` |-`order.preferred_stock_location_id` keeps its name: it is an association, not a setting. Validation errors name the field without the prefix too. Writes still accept the old `preferred_*` names until Spree 6.1, with a deprecation warning in the server log; responses only carry the new names. The store's `storefront_url` is the setting as saved, `null` when unset; `url` is the address customer links use. The store's `default_minimum_payout_amount` and `default_commission_tax_rate` are now exact decimal strings (`"0.23"`) instead of numbers.+`order.preferred_stock_location_id` keeps its name: it is an association, not a setting. Validation errors name the field without the prefix too. The Admin and Seller APIs no longer accept the old `preferred_*` names; send the new ones. The store's `storefront_url` is the setting as saved, `null` when unset; `url` is the address customer links use. The store's `default_minimum_payout_amount` and `default_commission_tax_rate` are now exact decimal strings (`"0.23"`) instead of numbers.**`preference_schema` is replaced by `schema`.** Rules, actions, payment methods and integrations no longer carry `preference_schema` on every row. Each family's `/types` endpoint (and the delivery-method and promotion-action calculator lists) returns a `schema` per type instead: the JSON Schema of its `preferences`, with `format`, `enum`, `default` and `x-spree-secret`. Read a row's type, then look up its schema there. `/payment_methods/types` now lists every provider, with `installed: true` on those the store already has, instead of leaving them out.@@ -590,7 +603,7 @@ Settings no longer reach the Admin and Seller APIs in the shape of Ruby's prefer**Id lists read as prefixed ids.** Preferences listing records, such as a rule's `channel_ids` or `customer_group_ids`, now return prefixed ids rather than database ids, the same form a write accepts.-**Delivery methods nest their calculator.** `calculator_type` and `calculator_preferences` are replaced by `calculator: { type, preferences }` on read and write, the shape promotion actions already use. Writes still accept the old two parameters until Spree 6.1, with a deprecation warning; their values follow the new rules (decimals as strings).+**Delivery methods nest their calculator.** `calculator_type` and `calculator_preferences` are replaced by `calculator: { type, preferences }` on read and write, the shape promotion actions already use. The old two parameters are no longer accepted; their values follow the new rules (decimals as strings).A preference marked deprecated, such as a flat rate calculator's `minimum_item_total`, is still accepted on write until its removal, with its deprecation warning, but is not read back.@@ -1062,6 +1075,21 @@ Stored markup is also held to a narrower allowlist than 5.6 — see [the rich-teA storefront built on the Store API and `@spree/sdk`, such as the [Spree storefront](https://github.com/spree/storefront), needs `@spree/sdk` 2.0 and the changes below. Most are type errors that point at the line to change.+**The quickest path, for a person or a coding agent:**++1. Upgrade `@spree/sdk` to 2.x and run the type checker (`pnpm exec tsc --noEmit`, or your framework's build).+2. Match each error against the table below and apply its fix. Fix values where they come from (a context, a form, an API response), not with a cast at each call site.+3. Search for the deprecated names in the [deprecated fields](#deprecated-fields-still-work-until-61) section and switch them, even where nothing fails to compile.++| Type error mentions | Cause | Fix |+|---|---|---|+| `CountryCode` or `CurrencyCode` | Country and currency codes are typed | [Country and currency codes](#country-and-currency-codes-are-typed) |+| `amount_in_cents`, `compare_at_amount_in_cents` | Removed from prices | Read `amount` ([Money](#money)) |+| `string \| null` where a price or amount is read | Money fields are `null` for guests when the store hides prices | [Money can be null](#money-can-be-null) |+| A property that "does not exist" in a `…Params` type | Request types now list exactly what the endpoint accepts | [Request types](#request-types-match-the-api) |+| `ProductSort`, or a filter key | List filters and sort are typed | [List filters and sort](#list-filters-and-sort-are-typed) |+| `number` is not assignable to `string` in a filter or amount | Money is a decimal string everywhere | Send `'20.00'`, not `20` ([Money](#money)) |+### List filters and sort are typedEach `list()` method now takes the filters and sort fields its endpoint accepts. A misspelled filter, a filter the endpoint doesn't support, or an unknown sort field used to return the unfiltered list; it is now a compile error. `ProductListParams`, `CategoryListParams`, `CollectionListParams` and `OrderListParams` keep their names but no longer accept arbitrary keys.@@ -1097,6 +1125,56 @@ const result = await client.carts.complete(cartId)const orders = isOrderGroup(result) ? result.orders : [result]```+### Request types match the API++Request types (`CreateCartParams`, `UpdateCartParams`, `AddLineItemParams`, `AddressParams` and the rest) are generated from what each endpoint accepts. Fields the API never accepted are gone, so a type error there means the value was being dropped. Fields the API accepted but the old types left out are now available.++- **A cart's addresses take `CartAddressParams`, not `AddressParams`.** `AddressParams` is the customer's address book entry. A cart address also takes `id` (an address from the book) and `quick_checkout` (relaxed validation for a wallet's partial address):++ ```ts src/lib/data/express-checkout-flow.ts+ import type { CartAddressParams } from '@spree/sdk'++ const shipping_address: CartAddressParams = { ...walletAddress, quick_checkout: true }+ await client.carts.update(cartId, { shipping_address })+ ```++- **Some requirements relaxed.** `AddLineItemParams.quantity` is optional (it defaults to 1), and `RegisterParams.password_confirmation` is optional.+- **Renamed types keep their old names until 6.1, marked deprecated:** `LineItemInput` is `LineItemInputParams`.++### Country and currency codes are typed++`country_code` and `currency` are typed as `CountryCode` (ISO 3166-1 alpha-2, such as `'US'`) and `CurrencyCode` (ISO 4217, such as `'EUR'`) in requests and responses. A plain `string` no longer type-checks where a request expects one. The values come from the API already typed (`Market.currency`, `Market.country_codes`, `Country.iso`, `Currency.iso_code`, `Address.country_code`), so type the state that holds them rather than casting each use:++```ts src/contexts/StoreContext.tsx+import type { CountryCode, CurrencyCode } from '@spree/sdk'++interface StoreContextValue {+ currency: CurrencyCode+ country: CountryCode+}+```++A code typed by a shopper or read from the URL is still a `string`. Check it against the store's own list (`market.country_codes`, the currencies endpoint) before using it, which also narrows its type:++```ts+const country = market.country_codes.find((code) => code === params.country.toUpperCase())+```++### Money can be null++Every money field, including `display_*` amounts (a gift card's or store credit's `display_amount_remaining`, a delivery rate's `cost`), is typed `string | null`: it is `null` for a guest when the store hides prices (`prices_hidden`). Handle `null` where you format or add amounts, for example by showing nothing, or a "price on request" label.++### Deprecated fields still work until 6.1++These Store API fields keep working in 6.0 and are marked `@deprecated` in the SDK types, so editors strike them through. Switch now; they are removed in 6.1:++| Deprecated | Use |+|---|---|+| Address `country_iso`, read and written | `country_code` |+| Address `state_abbr`, read and written | `state_code` |+| Cart `number` | `id` |+| Market `country_isos` | `country_codes` |+### Other Store API changes to check| Change | What to update | Details |diff --git a/packages/admin-sdk/src/params.ts b/packages/admin-sdk/src/params.tsindex c4da541c36..1a6a8bc189 100644--- a/packages/admin-sdk/src/params.ts+++ b/packages/admin-sdk/src/params.ts@@ -2,7 +2,7 @@// Based on the Admin API OpenAPI specificationimport type { PaginationMeta, PreferenceSchema } from '@spree/sdk-core'-import type { SellerRequirementStatus, StoreCredit } from './types'+import type { CountryCode, CurrencyCode, SellerRequirementStatus, StoreCredit } from './types'import type {CollectionRuleParams,CommissionRuleDraftParams,@@ -168,10 +168,10 @@ export interface SetupStatus {/** A country the store can be set up in, with everything derived from it. */export interface SetupCountry {/** ISO 3166-1 alpha-2 code, e.g. `CH`. */- code: string+ code: CountryCodename: string/** ISO 4217 currency the store gets when this country is chosen, e.g. `CHF`. */- currency: string | null+ currency: CurrencyCode | null/** Official languages, e.g. `['de', 'fr', 'it', 'rm']`. */locales: string[]}diff --git a/packages/admin-sdk/src/types/generated/Address.ts b/packages/admin-sdk/src/types/generated/Address.tsindex 5412e29c9c..1fdd56d744 100644--- a/packages/admin-sdk/src/types/generated/Address.ts+++ b/packages/admin-sdk/src/types/generated/Address.ts@@ -1,6 +1,7 @@-// Typelizer digest bd4dccbbd370bbcb404e26ae0750029d+// Typelizer digest 10679acf10ac2dfd20c3a96c7bb87d35//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'interface Address {id: string;@@ -15,16 +16,12 @@ interface Address {phone: string | null;company: string | null;country_name: string;- country_code: string;+ country_code: CountryCode;state_text: string | null;state_code: string | null;quick_checkout: boolean;is_default_billing: boolean;is_default_shipping: boolean;- /** @deprecated Use `state_code`. Removed in 6.1. */- state_abbr: string | null;- /** @deprecated Use `country_code`. Removed in 6.1. */- country_iso: string;state_name: string | null;metadata: Record<string, unknown>;created_at: string;diff --git a/packages/admin-sdk/src/types/generated/Cart.ts b/packages/admin-sdk/src/types/generated/Cart.tsindex b5c2a27019..d9c4a3e70b 100644--- a/packages/admin-sdk/src/types/generated/Cart.ts+++ b/packages/admin-sdk/src/types/generated/Cart.ts@@ -1,7 +1,7 @@-// Typelizer digest d7b7084b2992afee215f08d29a555f13+// Typelizer digest f738f60ecfdf9e1b139bcb39e1c0867c//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {FreightSummary, LineItem, Address, Market, AppliedPromotion} from '@/types'+import type {FreightSummary, LineItem, Address, Market, AppliedPromotion, CurrencyCode} from '@/types'interface Cart {id: string;@@ -13,13 +13,11 @@ interface Cart {po_number_required: boolean;po_document_filename: string | null;po_document_byte_size: number | null;- /** @deprecated Use `id`; a cart has no order number. Removed in 6.1. */- number: string;token: string;email: string | null;customer_note: string | null;po_number: string | null;- currency: string;+ currency: CurrencyCode;locale: string | null;total_quantity: number;warnings: Array<{code: string, message: string, line_item_id?: string, variant_id?: string, item_index?: number}>;diff --git a/packages/admin-sdk/src/types/generated/CatalogOrderMinimum.ts b/packages/admin-sdk/src/types/generated/CatalogOrderMinimum.tsindex f13221d289..044bb00c9e 100644--- a/packages/admin-sdk/src/types/generated/CatalogOrderMinimum.ts+++ b/packages/admin-sdk/src/types/generated/CatalogOrderMinimum.ts@@ -1,10 +1,11 @@-// Typelizer digest f1d403b0033e328db840c12a2f8faf3b+// Typelizer digest 2feeeb4173a673513575018889e22ba2//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface CatalogOrderMinimum {id: string;- currency: string;+ currency: CurrencyCode;created_at: string;updated_at: string;amount: string;diff --git a/packages/admin-sdk/src/types/generated/CatalogPrice.ts b/packages/admin-sdk/src/types/generated/CatalogPrice.tsindex 61532ba51e..7bd52576e7 100644--- a/packages/admin-sdk/src/types/generated/CatalogPrice.ts+++ b/packages/admin-sdk/src/types/generated/CatalogPrice.ts@@ -1,13 +1,13 @@-// Typelizer digest 759dd3b4f5365b5327ce0c68017d518c+// Typelizer digest 16964c48b98947cd36d889cd96a4bc95//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {CatalogPriceTier} from '@/types'+import type {CatalogPriceTier, CurrencyCode} from '@/types'interface CatalogPrice {id: string | null;label: string | null;sku: string | null;- currency: string;+ currency: CurrencyCode;source: 'explicit' | 'automatic' | 'base';break_count: number;amount: string;diff --git a/packages/admin-sdk/src/types/generated/CommissionLine.ts b/packages/admin-sdk/src/types/generated/CommissionLine.tsindex 5bb3144e6f..683921146b 100644--- a/packages/admin-sdk/src/types/generated/CommissionLine.ts+++ b/packages/admin-sdk/src/types/generated/CommissionLine.ts@@ -1,14 +1,14 @@-// Typelizer digest be799513fac0fe11084ea97905df8908+// Typelizer digest 9a551712a7656f16306a38529ccb5d48//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {CommissionRate} from '@/types'+import type {CommissionRate, CurrencyCode, CountryCode} from '@/types'interface CommissionLine {id: string;kind: 'percentage' | 'fixed';- currency: string;+ currency: CurrencyCode;taxability_reason: string | null;- country_code: string | null;+ country_code: CountryCode | null;state_code: string | null;created_at: string;updated_at: string;diff --git a/packages/admin-sdk/src/types/generated/Country.ts b/packages/admin-sdk/src/types/generated/Country.tsindex 42f756a4fb..fce90edd94 100644--- a/packages/admin-sdk/src/types/generated/Country.ts+++ b/packages/admin-sdk/src/types/generated/Country.ts@@ -1,10 +1,10 @@-// Typelizer digest 6e35bb28fc74637d6a28153ea857b182+// Typelizer digest 22cd8a8d7e67bf8a9331d3361c74a773//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Market, State} from '@/types'+import type {Market, State, CountryCode} from '@/types'interface Country {- iso: string;+ iso: CountryCode;iso3: string;name: string;states_required: boolean;diff --git a/packages/admin-sdk/src/types/generated/DeliveryZoneMember.ts b/packages/admin-sdk/src/types/generated/DeliveryZoneMember.tsindex a013b4ecd5..41250c06a6 100644--- a/packages/admin-sdk/src/types/generated/DeliveryZoneMember.ts+++ b/packages/admin-sdk/src/types/generated/DeliveryZoneMember.ts@@ -1,11 +1,12 @@-// Typelizer digest 4c74bb1bb68a69803891f3f2652b8cae+// Typelizer digest 428ec3841b5404e2cdad2159e2b2fbb9//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'interface DeliveryZoneMember {id: string;member_type: 'country' | 'state' | 'postal_code';- country_code: string | null;+ country_code: CountryCode | null;state_code: string | null;postal_code_prefix: string | null;postal_code_from: string | null;diff --git a/packages/admin-sdk/src/types/generated/Enums.ts b/packages/admin-sdk/src/types/generated/Enums.tsindex 877c2a40d8..c8b9b94f48 100644--- a/packages/admin-sdk/src/types/generated/Enums.ts+++ b/packages/admin-sdk/src/types/generated/Enums.ts@@ -1,8 +1,10 @@-// Typelizer digest 149c77e881731e5cfd0e38efa7a1561b+// Typelizer digest fbbf3b4bb49d44bb14fbac0c38bfaebb//// DO NOT MODIFY: This file was automatically generated by Typelizer.export type ActorKind = 'admin_user' | 'api_key' | (string & {});export type ClaimStatus = 'open' | 'approved' | 'resolved' | 'denied' | 'canceled' | (string & {});+export type CountryCode = 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO' | 'AR' | 'AS' | 'AT' | 'AU' | 'AW' | 'AZ' | 'BA' | 'BB' | 'BD' | 'BE' | 'BF' | 'BG' | 'BH' | 'BI' | 'BJ' | 'BL' | 'BM' | 'BN' | 'BO' | 'BQ' | 'BR' | 'BS' | 'BT' | 'BW' | 'BY' | 'BZ' | 'CA' | 'CC' | 'CD' | 'CF' | 'CG' | 'CH' | 'CI' | 'CK' | 'CL' | 'CM' | 'CN' | 'CO' | 'CR' | 'CU' | 'CV' | 'CW' | 'CX' | 'CY' | 'CZ' | 'DE' | 'DJ' | 'DK' | 'DM' | 'DO' | 'DZ' | 'EC' | 'EE' | 'EG' | 'ER' | 'ES' | 'ET' | 'FI' | 'FJ' | 'FK' | 'FM' | 'FO' | 'FR' | 'GA' | 'GB' | 'GD' | 'GE' | 'GF' | 'GG' | 'GH' | 'GI' | 'GL' | 'GM' | 'GN' | 'GP' | 'GQ' | 'GR' | 'GT' | 'GU' | 'GW' | 'GY' | 'HK' | 'HN' | 'HR' | 'HT' | 'HU' | 'ID' | 'IE' | 'IL' | 'IM' | 'IN' | 'IQ' | 'IR' | 'IS' | 'IT' | 'JE' | 'JM' | 'JO' | 'JP' | 'KE' | 'KG' | 'KH' | 'KI' | 'KM' | 'KN' | 'KP' | 'KR' | 'KW' | 'KY' | 'KZ' | 'LA' | 'LB' | 'LC' | 'LI' | 'LK' | 'LR' | 'LS' | 'LT' | 'LU' | 'LV' | 'LY' | 'MA' | 'MC' | 'MD' | 'ME' | 'MF' | 'MG' | 'MH' | 'MK' | 'ML' | 'MM' | 'MN' | 'MO' | 'MP' | 'MQ' | 'MR' | 'MS' | 'MT' | 'MU' | 'MV' | 'MW' | 'MX' | 'MY' | 'MZ' | 'NA' | 'NC' | 'NE' | 'NF' | 'NG' | 'NI' | 'NL' | 'NO' | 'NP' | 'NR' | 'NU' | 'NZ' | 'OM' | 'PA' | 'PE' | 'PF' | 'PG' | 'PH' | 'PK' | 'PL' | 'PM' | 'PN' | 'PR' | 'PS' | 'PT' | 'PW' | 'PY' | 'QA' | 'RE' | 'RO' | 'RS' | 'RU' | 'RW' | 'SA' | 'SB' | 'SC' | 'SD' | 'SE' | 'SG' | 'SH' | 'SI' | 'SJ' | 'SK' | 'SL' | 'SM' | 'SN' | 'SO' | 'SR' | 'SS' | 'ST' | 'SV' | 'SX' | 'SY' | 'SZ' | 'TC' | 'TD' | 'TG' | 'TH' | 'TJ' | 'TK' | 'TL' | 'TM' | 'TN' | 'TO' | 'TR' | 'TT' | 'TV' | 'TW' | 'TZ' | 'UA' | 'UG' | 'US' | 'UY' | 'UZ' | 'VA' | 'VC' | 'VE' | 'VG' | 'VI' | 'VN' | 'VU' | 'WF' | 'WS' | 'YE' | 'YT' | 'ZA' | 'ZM' | 'ZW';+export type CurrencyCode = 'AED' | 'AFN' | 'ALL' | 'AMD' | 'ANG' | 'AOA' | 'ARS' | 'AUD' | 'AWG' | 'AZN' | 'BAM' | 'BBD' | 'BDT' | 'BGN' | 'BHD' | 'BIF' | 'BMD' | 'BND' | 'BOB' | 'BRL' | 'BSD' | 'BTN' | 'BWP' | 'BYN' | 'BYR' | 'BZD' | 'CAD' | 'CDF' | 'CHF' | 'CLF' | 'CLP' | 'CNY' | 'COP' | 'CRC' | 'CUC' | 'CUP' | 'CVE' | 'CZK' | 'DJF' | 'DKK' | 'DOP' | 'DZD' | 'EEK' | 'EGP' | 'ERN' | 'ETB' | 'EUR' | 'FJD' | 'FKP' | 'GBP' | 'GEL' | 'GHS' | 'GIP' | 'GMD' | 'GNF' | 'GTQ' | 'GYD' | 'HKD' | 'HNL' | 'HRK' | 'HTG' | 'HUF' | 'IDR' | 'ILS' | 'INR' | 'IQD' | 'IRR' | 'ISK' | 'JMD' | 'JOD' | 'JPY' | 'KES' | 'KGS' | 'KHR' | 'KMF' | 'KPW' | 'KRW' | 'KWD' | 'KYD' | 'KZT' | 'LAK' | 'LBP' | 'LKR' | 'LRD' | 'LSL' | 'LTL' | 'LVL' | 'LYD' | 'MAD' | 'MDL' | 'MGA' | 'MKD' | 'MMK' | 'MNT' | 'MOP' | 'MRO' | 'MRU' | 'MTL' | 'MUR' | 'MVR' | 'MWK' | 'MXN' | 'MYR' | 'MZN' | 'NAD' | 'NGN' | 'NIO' | 'NOK' | 'NPR' | 'NZD' | 'OMR' | 'PAB' | 'PEN' | 'PGK' | 'PHP' | 'PKR' | 'PLN' | 'PYG' | 'QAR' | 'RON' | 'RSD' | 'RUB' | 'RWF' | 'SAR' | 'SBD' | 'SCR' | 'SDG' | 'SEK' | 'SGD' | 'SHP' | 'SKK' | 'SLE' | 'SLL' | 'SOS' | 'SRD' | 'SSP' | 'STD' | 'STN' | 'SVC' | 'SYP' | 'SZL' | 'THB' | 'TJS' | 'TMM' | 'TMT' | 'TND' | 'TOP' | 'TRY' | 'TTD' | 'TWD' | 'TZS' | 'UAH' | 'UGX' | 'USD' | 'UYI' | 'UYU' | 'UYW' | 'UZS' | 'VED' | 'VEF' | 'VES' | 'VND' | 'VUV' | 'WST' | 'XAF' | 'XCD' | 'XCG' | 'XOF' | 'XPF' | 'YER' | 'ZAR' | 'ZMK' | 'ZMW' | 'ZWD' | 'ZWG' | 'ZWL' | 'ZWN' | 'ZWR';export type DataRequestStatus = 'pending' | 'processing' | 'completed' | 'failed' | (string & {});export type ExchangeStatus = 'requested' | 'approved' | 'received' | 'fulfilled' | 'canceled' | (string & {});export type FeeKind = 'surcharge' | 'handling' | 'gift_wrap' | 'cod' | 'payment' | 'duty' | 'exchange' | (string & {});diff --git a/packages/admin-sdk/src/types/generated/GiftCard.ts b/packages/admin-sdk/src/types/generated/GiftCard.tsindex 9dd47f1342..80b0a1e1d8 100644--- a/packages/admin-sdk/src/types/generated/GiftCard.ts+++ b/packages/admin-sdk/src/types/generated/GiftCard.ts@@ -1,13 +1,13 @@-// Typelizer digest cbb2485bc8eaf7c50c37131e7b63b388+// Typelizer digest 9d50401c76d3e7f24ea4bda35076a571//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Customer, AdminUser, GiftCardBatch, Order, GiftCardStatus} from '@/types'+import type {Customer, AdminUser, GiftCardBatch, Order, GiftCardStatus, CurrencyCode} from '@/types'interface GiftCard {id: string;code: string;status: GiftCardStatus;- currency: string;+ currency: CurrencyCode;amount: string;amount_used: string;amount_authorized: string;diff --git a/packages/admin-sdk/src/types/generated/GiftCardBatch.ts b/packages/admin-sdk/src/types/generated/GiftCardBatch.tsindex 449a91e5c4..0ca376a0c3 100644--- a/packages/admin-sdk/src/types/generated/GiftCardBatch.ts+++ b/packages/admin-sdk/src/types/generated/GiftCardBatch.ts@@ -1,11 +1,12 @@-// Typelizer digest 784b5e96992dd0313dd9e127def57ba3+// Typelizer digest fae514b2ad11fb5d712283798c7f4f24//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface GiftCardBatch {id: string;codes_count: number;- currency: string | null;+ currency: CurrencyCode | null;prefix: string | null;created_at: string;updated_at: string;diff --git a/packages/admin-sdk/src/types/generated/Import.ts b/packages/admin-sdk/src/types/generated/Import.tsindex b06c536cff..a0daaece78 100644--- a/packages/admin-sdk/src/types/generated/Import.ts+++ b/packages/admin-sdk/src/types/generated/Import.ts@@ -1,4 +1,4 @@-// Typelizer digest 25e6ac91e2aaf16e39759fabdfb90a44+// Typelizer digest b85bbe53aeda363eb0baa21e861b3b6c//// DO NOT MODIFY: This file was automatically generated by Typelizer.import type {ImportMapping, ImportStatus} from '@/types'@@ -14,10 +14,6 @@ interface Import {status: ImportStatus;store_id: string | null;seller_id: string | null;- /** @deprecated Read `store_id` / `seller_id`. Removed in 6.1. */- owner_type: string | null;- /** @deprecated Read `store_id` / `seller_id`. Removed in 6.1. */- owner_id: string | null;user_id: string | null;processing_errors: string | null;delimiter: string;diff --git a/packages/admin-sdk/src/types/generated/LineItem.ts b/packages/admin-sdk/src/types/generated/LineItem.tsindex 12724a4cd1..8273a1a461 100644--- a/packages/admin-sdk/src/types/generated/LineItem.ts+++ b/packages/admin-sdk/src/types/generated/LineItem.ts@@ -1,7 +1,7 @@-// Typelizer digest 15bdd7daef6207658ed7e1a20d766bd0+// Typelizer digest 39fd90f012cce17b02063c674dcbe4fc//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Seller, OptionValue, DigitalLink, TaxLine, Variant, TaxCategory} from '@/types'+import type {Seller, OptionValue, DigitalLink, TaxLine, Variant, TaxCategory, CurrencyCode} from '@/types'interface LineItem {id: string;@@ -10,7 +10,7 @@ interface LineItem {preorder: boolean;preorder_ships_at: string | null;quantity: number;- currency: string;+ currency: CurrencyCode;name: string;slug: string;options_text: string;diff --git a/packages/admin-sdk/src/types/generated/Market.ts b/packages/admin-sdk/src/types/generated/Market.tsindex ca0122ef00..e4cc9ff08e 100644--- a/packages/admin-sdk/src/types/generated/Market.ts+++ b/packages/admin-sdk/src/types/generated/Market.ts@@ -1,18 +1,16 @@-// Typelizer digest e213ce061f1b5da0aad9a5fe9610ddfd+// Typelizer digest 0482e3e0902c22a0c0016c2196805bc7//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Country} from '@/types'+import type {Country, CurrencyCode, CountryCode} from '@/types'interface Market {id: string;name: string;- currency: string;+ currency: CurrencyCode;default_locale: string;tax_inclusive: boolean;default: boolean;- country_codes: Array<string>;- /** @deprecated Use `country_codes`. Removed in 6.1. */- country_isos: Array<string>;+ country_codes: Array<CountryCode>;supported_locales: Array<string>;countries?: Array<Country>;created_at: string;diff --git a/packages/admin-sdk/src/types/generated/Order.ts b/packages/admin-sdk/src/types/generated/Order.tsindex cd565f2d56..bcba733682 100644--- a/packages/admin-sdk/src/types/generated/Order.ts+++ b/packages/admin-sdk/src/types/generated/Order.ts@@ -1,7 +1,7 @@-// Typelizer digest 839c6ea3758a8da6f47a867daae55b52+// Typelizer digest 4c90e1db894d2005fe7f3731fe39ad0c//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {FreightSummary, LineItem, Fulfillment, Payment, Address, GiftCard, Market, Seller, Actor, AppliedPromotion, PaymentSplit, Cart, Channel, StockLocation, PaymentMethod, Customer, OrderCancellationReason, Return, Exchange, Claim, ActorKind} from '@/types'+import type {FreightSummary, LineItem, Fulfillment, Payment, Address, GiftCard, Market, Seller, Actor, AppliedPromotion, PaymentSplit, Cart, Channel, StockLocation, PaymentMethod, Customer, OrderCancellationReason, Return, Exchange, Claim, CurrencyCode, ActorKind} from '@/types'interface Order {id: string;@@ -18,7 +18,7 @@ interface Order {email: string;customer_note: string | null;po_number: string | null;- currency: string;+ currency: CurrencyCode;locale: string | null;total_quantity: number;coupon_code: string | null;diff --git a/packages/admin-sdk/src/types/generated/OrderGroup.ts b/packages/admin-sdk/src/types/generated/OrderGroup.tsindex d15795ec76..ba9eb282aa 100644--- a/packages/admin-sdk/src/types/generated/OrderGroup.ts+++ b/packages/admin-sdk/src/types/generated/OrderGroup.ts@@ -1,13 +1,13 @@-// Typelizer digest b2e536b91816d5c77c3fe612108cc4e5+// Typelizer digest ec6a0033a30f99bb20eac2ebeb6daa79//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Address, Order, Payment} from '@/types'+import type {Address, Order, Payment, CurrencyCode} from '@/types'interface OrderGroup {id: string;number: string;email: string | null;- currency: string;+ currency: CurrencyCode;total: string | null;item_total: string | null;fulfillment_status: 'backorder' | 'canceled' | 'partial' | 'unfulfilled' | 'fulfilled' | 'delivered' | 'pending' | 'ready' | 'shipped' | null;diff --git a/packages/admin-sdk/src/types/generated/PaymentMethod.ts b/packages/admin-sdk/src/types/generated/PaymentMethod.tsindex 90ee4eaf70..93836061b7 100644--- a/packages/admin-sdk/src/types/generated/PaymentMethod.ts+++ b/packages/admin-sdk/src/types/generated/PaymentMethod.ts@@ -1,4 +1,4 @@-// Typelizer digest 177a1ae2803dbd7e23cb8450d56e9bed+// Typelizer digest 84379bdf3481d4510b6820091ea58e02//// DO NOT MODIFY: This file was automatically generated by Typelizer.@@ -12,7 +12,6 @@ interface PaymentMethod {source_required: boolean;metadata: Record<string, unknown>;active: boolean;- auto_capture: boolean | null;capture_method: 'checkout' | 'on_dispatch' | 'manual' | null;resolved_capture_method: 'checkout' | 'on_dispatch' | 'manual';storefront_visible: boolean;diff --git a/packages/admin-sdk/src/types/generated/PaymentSplit.ts b/packages/admin-sdk/src/types/generated/PaymentSplit.tsindex 0d09b41cc3..eb3cd2d215 100644--- a/packages/admin-sdk/src/types/generated/PaymentSplit.ts+++ b/packages/admin-sdk/src/types/generated/PaymentSplit.ts@@ -1,10 +1,11 @@-// Typelizer digest 1c72a414a94321c8686619d9076bd4e7+// Typelizer digest 7c0be54d61225da47361a83df5c0e352//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface PaymentSplit {id: string;- currency: string;+ currency: CurrencyCode;created_at: string;updated_at: string;authorized_amount: string;diff --git a/packages/admin-sdk/src/types/generated/Price.ts b/packages/admin-sdk/src/types/generated/Price.tsindex ebc1008263..f54013cb6a 100644--- a/packages/admin-sdk/src/types/generated/Price.ts+++ b/packages/admin-sdk/src/types/generated/Price.ts@@ -1,11 +1,11 @@-// Typelizer digest 0a5ab4199939d0ef54728a1c609588ec+// Typelizer digest b4973d56f8ea3f32e4d6b33583795ff1//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Variant} from '@/types'+import type {Variant, CurrencyCode} from '@/types'interface Price {id: string;- currency: string | null;+ currency: CurrencyCode | null;amount: string | null;compare_at_amount: string | null;price_list_id: string | null;diff --git a/packages/admin-sdk/src/types/generated/PriceHistory.ts b/packages/admin-sdk/src/types/generated/PriceHistory.tsindex 625c296084..142d36eca6 100644--- a/packages/admin-sdk/src/types/generated/PriceHistory.ts+++ b/packages/admin-sdk/src/types/generated/PriceHistory.ts@@ -1,10 +1,11 @@-// Typelizer digest a54ce4d17da72f19f38678b4c22e55d1+// Typelizer digest 0ba76ace7bf046f0674ae1f05eb00a32//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface PriceHistory {id: string;- currency: string;+ currency: CurrencyCode;amount: string | null;recorded_at: string;variant_id: string;diff --git a/packages/admin-sdk/src/types/generated/PurchaseOrder.ts b/packages/admin-sdk/src/types/generated/PurchaseOrder.tsindex efb2f125f9..d23cb2cec2 100644--- a/packages/admin-sdk/src/types/generated/PurchaseOrder.ts+++ b/packages/admin-sdk/src/types/generated/PurchaseOrder.ts@@ -1,13 +1,13 @@-// Typelizer digest c24830604333237cea5c3a58ab5e364f+// Typelizer digest d53a7b0bb42bafc3e4d0eac554537e48//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {PurchaseOrderItem, StockReceipt, Supplier, StockLocation} from '@/types'+import type {PurchaseOrderItem, StockReceipt, Supplier, StockLocation, CurrencyCode} from '@/types'interface PurchaseOrder {id: string;number: string;status: string;- currency: string;+ currency: CurrencyCode;reference: string | null;notes: string | null;metadata: Record<string, unknown>;diff --git a/packages/admin-sdk/src/types/generated/PurchaseOrderItem.ts b/packages/admin-sdk/src/types/generated/PurchaseOrderItem.tsindex 24086fffbc..ed520e14ee 100644--- a/packages/admin-sdk/src/types/generated/PurchaseOrderItem.ts+++ b/packages/admin-sdk/src/types/generated/PurchaseOrderItem.ts@@ -1,6 +1,7 @@-// Typelizer digest e51c619b5a5af493443d53dc14cec994+// Typelizer digest d4e49ce22327b363b312b3457ec80093//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface PurchaseOrderItem {id: string;@@ -9,7 +10,7 @@ interface PurchaseOrderItem {quantity_rejected: number;quantity_over: number;outstanding: number;- currency: string | null;+ currency: CurrencyCode | null;created_at: string;updated_at: string;unit_cost: string;diff --git a/packages/admin-sdk/src/types/generated/SellerBalance.ts b/packages/admin-sdk/src/types/generated/SellerBalance.tsindex 1b16aa4bc1..b3edfb2fcd 100644--- a/packages/admin-sdk/src/types/generated/SellerBalance.ts+++ b/packages/admin-sdk/src/types/generated/SellerBalance.ts@@ -1,10 +1,11 @@-// Typelizer digest c0d773873787c6ac21399efb60d0b5eb+// Typelizer digest d00ddc980463cb805a0269d52305c98e//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface SellerBalance {- currency: string;- settlement_currency: string;+ currency: CurrencyCode;+ settlement_currency: CurrencyCode;converted: boolean;seller_id: string;earned: string;diff --git a/packages/admin-sdk/src/types/generated/SellerPayout.ts b/packages/admin-sdk/src/types/generated/SellerPayout.tsindex 206813e423..4c5ed359d2 100644--- a/packages/admin-sdk/src/types/generated/SellerPayout.ts+++ b/packages/admin-sdk/src/types/generated/SellerPayout.ts@@ -1,12 +1,12 @@-// Typelizer digest 78ce69932e5fb881d2d6b5575da14d33+// Typelizer digest 85be9e7959543d26d60d75139418ae65//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {SellerPayoutStatus} from '@/types'+import type {SellerPayoutStatus, CurrencyCode} from '@/types'interface SellerPayout {id: string;status: SellerPayoutStatus;- currency: string;+ currency: CurrencyCode;reference: string | null;metadata: unknown;period_start: string | null;diff --git a/packages/admin-sdk/src/types/generated/SellerTransfer.ts b/packages/admin-sdk/src/types/generated/SellerTransfer.tsindex 5daa317af3..458407342f 100644--- a/packages/admin-sdk/src/types/generated/SellerTransfer.ts+++ b/packages/admin-sdk/src/types/generated/SellerTransfer.ts@@ -1,20 +1,20 @@-// Typelizer digest 3a9ea2f5fc08e559c47cb1072d896009+// Typelizer digest e01ef70229a465c5746dde98eafd77e6//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {SellerTransferStatus} from '@/types'+import type {SellerTransferStatus, CurrencyCode} from '@/types'interface SellerTransfer {id: string;kind: 'earning' | 'refund_reversal';status: SellerTransferStatus;- currency: string;+ currency: CurrencyCode;reference: string | null;metadata: unknown;created_at: string;updated_at: string;amount: string;settled_amount: string | null;- settled_currency: string | null;+ settled_currency: CurrencyCode | null;converted: boolean;seller_id: string;order_id: string | null;diff --git a/packages/admin-sdk/src/types/generated/ShippingLabel.ts b/packages/admin-sdk/src/types/generated/ShippingLabel.tsindex 65997edd49..e8696254d9 100644--- a/packages/admin-sdk/src/types/generated/ShippingLabel.ts+++ b/packages/admin-sdk/src/types/generated/ShippingLabel.ts@@ -1,7 +1,7 @@-// Typelizer digest 175ac842e43ce206f43f335317cc65e4+// Typelizer digest 0629575beb871e90e563e8e58d80d34a//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {ShippingLabelStatus} from '@/types'+import type {ShippingLabelStatus, CurrencyCode} from '@/types'interface ShippingLabel {id: string;@@ -11,7 +11,7 @@ interface ShippingLabel {carrier_name: string | null;service: string | null;tracking_number: string | null;- currency: string | null;+ currency: CurrencyCode | null;format: string | null;external_id: string | null;metadata: Record<string, unknown>;diff --git a/packages/admin-sdk/src/types/generated/StockLocation.ts b/packages/admin-sdk/src/types/generated/StockLocation.tsindex ece0e284d6..7f4373fbb1 100644--- a/packages/admin-sdk/src/types/generated/StockLocation.ts+++ b/packages/admin-sdk/src/types/generated/StockLocation.ts@@ -1,7 +1,7 @@-// Typelizer digest 2d75320cec88b48926700b1f096cb2ae+// Typelizer digest 38f1c1b21dbde822551f56856ae0b6d5//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Seller, StockLocationKind} from '@/types'+import type {Seller, CountryCode, StockLocationKind} from '@/types'interface StockLocation {id: string;@@ -9,7 +9,7 @@ interface StockLocation {address1: string | null;city: string | null;zipcode: string | null;- country_code: string | null;+ country_code: CountryCode | null;country_name: string | null;state_code: string | null;state_text: string | null;diff --git a/packages/admin-sdk/src/types/generated/Store.ts b/packages/admin-sdk/src/types/generated/Store.tsindex 28fed2a189..cbf9e8dba5 100644--- a/packages/admin-sdk/src/types/generated/Store.ts+++ b/packages/admin-sdk/src/types/generated/Store.ts@@ -1,14 +1,14 @@-// Typelizer digest a759a5bc2842ad75a22725199d78443d+// Typelizer digest ceb55fed4c0acf8c45548f43904f8b22//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {SetupTask} from '@/types'+import type {SetupTask, CurrencyCode} from '@/types'interface Store {id: string;metadata: Record<string, unknown>;name: string;code: string;- default_currency: string;+ default_currency: CurrencyCode;default_locale: string;default_country_code: string | null;mail_from_address: string | null;@@ -68,7 +68,7 @@ interface Store {url: string;api_url: string;setup_tasks: Array<SetupTask>;- supported_currencies: Array<string>;+ supported_currencies: Array<CurrencyCode>;supported_locales: Array<string>;available_locales: Array<string>;logo_url: string | null;diff --git a/packages/admin-sdk/src/types/generated/StoreCredit.ts b/packages/admin-sdk/src/types/generated/StoreCredit.tsindex e3e8507ab4..edd2b48dda 100644--- a/packages/admin-sdk/src/types/generated/StoreCredit.ts+++ b/packages/admin-sdk/src/types/generated/StoreCredit.ts@@ -1,14 +1,14 @@-// Typelizer digest 86c2263e0de7480b5bc259d309ac270d+// Typelizer digest 9ef583163454ff4ae6481085a63377a4//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Customer, AdminUser} from '@/types'+import type {Customer, AdminUser, CurrencyCode} from '@/types'interface StoreCredit {id: string;amount: string;amount_used: string;amount_remaining: string;- currency: string;+ currency: CurrencyCode;memo: string | null;metadata: Record<string, unknown>;created_at: string;diff --git a/packages/admin-sdk/src/types/generated/Supplier.ts b/packages/admin-sdk/src/types/generated/Supplier.tsindex ea97931417..bf4fa603a5 100644--- a/packages/admin-sdk/src/types/generated/Supplier.ts+++ b/packages/admin-sdk/src/types/generated/Supplier.ts@@ -1,6 +1,7 @@-// Typelizer digest 8aa26f6f5cdb74c9c833570ee65f18c9+// Typelizer digest 5bd820b72dcfc076e4fe5870d4a3e659//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'interface Supplier {id: string;@@ -14,7 +15,7 @@ interface Supplier {city: string | null;state_name: string | null;state_code: string | null;- country_code: string | null;+ country_code: CountryCode | null;postal_code: string | null;purchase_orders_count: number;metadata: Record<string, unknown>;diff --git a/packages/admin-sdk/src/types/generated/TaxExemptionCertificate.ts b/packages/admin-sdk/src/types/generated/TaxExemptionCertificate.tsindex 2cf650ae0d..8ab233b304 100644--- a/packages/admin-sdk/src/types/generated/TaxExemptionCertificate.ts+++ b/packages/admin-sdk/src/types/generated/TaxExemptionCertificate.ts@@ -1,7 +1,7 @@-// Typelizer digest f848b57f802494e1d7cb539a0368c521+// Typelizer digest 032a43324d0961779d3ce9f302bda211//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {TaxExemptionCertificateStatus} from '@/types'+import type {TaxExemptionCertificateStatus, CountryCode} from '@/types'interface TaxExemptionCertificate {id: string;@@ -16,7 +16,7 @@ interface TaxExemptionCertificate {created_at: string;updated_at: string;company_id: string;- country_code: string | null;+ country_code: CountryCode | null;state_code: string | null;active: boolean;lapsed: boolean;diff --git a/packages/admin-sdk/src/types/generated/TaxLine.ts b/packages/admin-sdk/src/types/generated/TaxLine.tsindex 35b4c584d6..5a5d6f7926 100644--- a/packages/admin-sdk/src/types/generated/TaxLine.ts+++ b/packages/admin-sdk/src/types/generated/TaxLine.ts@@ -1,6 +1,7 @@-// Typelizer digest bceefed7aacd35ee76b09c0dfc636907+// Typelizer digest 886d4172796e07eb2769ad4c38a5023d//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'interface TaxLine {id: string;@@ -19,7 +20,7 @@ interface TaxLine {provider_id: string | null;metadata: Record<string, unknown> | null;taxability_reason: string | null;- country_code: string | null;+ country_code: CountryCode | null;state_code: string | null;data: Record<string, unknown> | null;created_at: string;diff --git a/packages/admin-sdk/src/types/generated/TaxRate.ts b/packages/admin-sdk/src/types/generated/TaxRate.tsindex 313ce8eb84..7b71fb45a8 100644--- a/packages/admin-sdk/src/types/generated/TaxRate.ts+++ b/packages/admin-sdk/src/types/generated/TaxRate.ts@@ -1,6 +1,7 @@-// Typelizer digest 4b03a367a8150e55df52da427af8dbe0+// Typelizer digest 70d5f8795a5a2434de8eb97649f8343d//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'interface TaxRate {id: string;@@ -15,7 +16,7 @@ interface TaxRate {rate_percent: string | null;tax_category_id: string | null;store_id: string | null;- country_code: string | null;+ country_code: CountryCode | null;state_code: string | null;}diff --git a/packages/admin-sdk/src/types/generated/Variant.ts b/packages/admin-sdk/src/types/generated/Variant.tsindex 159c162805..de4570ef42 100644--- a/packages/admin-sdk/src/types/generated/Variant.ts+++ b/packages/admin-sdk/src/types/generated/Variant.ts@@ -1,7 +1,7 @@-// Typelizer digest e02a30b6f82fbd9309c1fd1cc18148f9+// Typelizer digest c7115ed981503ee3bdfb833a7382b79c//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Price, PriceHistory, Seller, Media, OptionValue, CustomField, StockLevel} from '@/types'+import type {Price, PriceHistory, Seller, Media, OptionValue, CustomField, StockLevel, CurrencyCode, CountryCode} from '@/types'interface Variant {id: string;@@ -38,11 +38,11 @@ interface Variant {external_references: Record<string, string>;metadata: Record<string, unknown>;position: number;- cost_currency: string | null;+ cost_currency: CurrencyCode | null;barcode: string | null;backorder_limit: number | null;hs_code: string | null;- country_of_origin: string | null;+ country_of_origin: CountryCode | null;customs_description: string | null;carton_weight: string | null;cartons_per_pallet: number | null;diff --git a/packages/admin-sdk/src/types/generated/emails/EmailAddress.ts b/packages/admin-sdk/src/types/generated/emails/EmailAddress.tsindex b2898e5d59..add3c3149b 100644--- a/packages/admin-sdk/src/types/generated/emails/EmailAddress.ts+++ b/packages/admin-sdk/src/types/generated/emails/EmailAddress.ts@@ -1,6 +1,7 @@-// Typelizer digest f05e8d3e26af3633bfbfa09a60ffa1b7+// Typelizer digest a10a9c61045ad2f099ab87561f63e134//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '.'interface EmailAddress {id: string;@@ -15,7 +16,7 @@ interface EmailAddress {phone: string | null;company: string | null;country_name: string;- country_code: string;+ country_code: CountryCode;state_text: string | null;state_code: string | null;quick_checkout: boolean;diff --git a/packages/admin-sdk/src/types/generated/emails/EmailGiftCard.ts b/packages/admin-sdk/src/types/generated/emails/EmailGiftCard.tsindex 03508a4037..dbd84e7cfb 100644--- a/packages/admin-sdk/src/types/generated/emails/EmailGiftCard.ts+++ b/packages/admin-sdk/src/types/generated/emails/EmailGiftCard.ts@@ -1,13 +1,13 @@-// Typelizer digest a85e739e40017900674c992ece4bccb2+// Typelizer digest 3957a94f3e00c16ce7aa1ad43ca53299//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {GiftCardStatus} from '.'+import type {GiftCardStatus, CurrencyCode} from '.'interface EmailGiftCard {id: string;code: string;status: GiftCardStatus;- currency: string;+ currency: CurrencyCode;amount: string | null;amount_used: string | null;amount_authorized: string | null;diff --git a/packages/admin-sdk/src/types/generated/emails/EmailLineItem.ts b/packages/admin-sdk/src/types/generated/emails/EmailLineItem.tsindex a4a1225651..e34aba42e3 100644--- a/packages/admin-sdk/src/types/generated/emails/EmailLineItem.ts+++ b/packages/admin-sdk/src/types/generated/emails/EmailLineItem.ts@@ -1,7 +1,7 @@-// Typelizer digest 9fc6250e889f0ea74c3df00a42542fd6+// Typelizer digest 18dfb65fa64a909cc0e7944e74c7ae2d//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {EmailOptionValue} from '.'+import type {EmailOptionValue, CurrencyCode} from '.'interface EmailLineItem {id: string;@@ -10,7 +10,7 @@ interface EmailLineItem {preorder: boolean;preorder_ships_at: string | null;quantity: number;- currency: string;+ currency: CurrencyCode;name: string;slug: string;options_text: string;diff --git a/packages/admin-sdk/src/types/generated/emails/EmailMarket.ts b/packages/admin-sdk/src/types/generated/emails/EmailMarket.tsindex 179e7336f1..4579da518f 100644--- a/packages/admin-sdk/src/types/generated/emails/EmailMarket.ts+++ b/packages/admin-sdk/src/types/generated/emails/EmailMarket.ts@@ -1,15 +1,16 @@-// Typelizer digest 1d2c25c1df3720f29490942a596b5696+// Typelizer digest f0094d480a752f1db1a37d4d0c8c2dd9//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode, CountryCode} from '.'interface EmailMarket {id: string;name: string;- currency: string;+ currency: CurrencyCode;default_locale: string;tax_inclusive: boolean;default: boolean;- country_codes: Array<string>;+ country_codes: Array<CountryCode>;/** @deprecated Use `country_codes`. Removed in 6.1. */country_isos: Array<string>;supported_locales: Array<string>;diff --git a/packages/admin-sdk/src/types/generated/emails/EmailOrder.ts b/packages/admin-sdk/src/types/generated/emails/EmailOrder.tsindex eb9d736067..7ff03f1ae3 100644--- a/packages/admin-sdk/src/types/generated/emails/EmailOrder.ts+++ b/packages/admin-sdk/src/types/generated/emails/EmailOrder.ts@@ -1,7 +1,7 @@-// Typelizer digest 56e482a620888128fd80f86fdebafa43+// Typelizer digest 2703884d9195a46457f23d1fecd0334d//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {EmailAppliedPromotion, EmailFee, EmailLineItem, EmailFulfillment, EmailPayment, EmailAddress, EmailGiftCard, EmailMarket, EmailAmountLine} from '.'+import type {EmailAppliedPromotion, EmailFee, EmailLineItem, EmailFulfillment, EmailPayment, EmailAddress, EmailGiftCard, EmailMarket, EmailAmountLine, CurrencyCode} from '.'interface EmailOrder {id: string;@@ -18,7 +18,7 @@ interface EmailOrder {email: string;customer_note: string | null;po_number: string | null;- currency: string;+ currency: CurrencyCode;locale: string | null;total_quantity: number;coupon_code: string | null;diff --git a/packages/admin-sdk/src/types/generated/emails/EmailOrderGroup.ts b/packages/admin-sdk/src/types/generated/emails/EmailOrderGroup.tsindex a9a4139b59..c19ea150bc 100644--- a/packages/admin-sdk/src/types/generated/emails/EmailOrderGroup.ts+++ b/packages/admin-sdk/src/types/generated/emails/EmailOrderGroup.ts@@ -1,13 +1,13 @@-// Typelizer digest 3f61504d7418841f9174c638518d0090+// Typelizer digest ef1236ef103cf5062d09ba432a0f4696//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {EmailAddress, EmailLineItem, EmailAmountLine, EmailFulfillmentGroup} from '.'+import type {EmailAddress, EmailLineItem, EmailAmountLine, EmailFulfillmentGroup, CurrencyCode} from '.'interface EmailOrderGroup {id: string;number: string;email: string | null;- currency: string;+ currency: CurrencyCode;total: string | null;display_total: string | null;item_total: string | null;diff --git a/packages/admin-sdk/src/types/generated/emails/EmailStockLocation.ts b/packages/admin-sdk/src/types/generated/emails/EmailStockLocation.tsindex f6c5edfa8f..7869998be0 100644--- a/packages/admin-sdk/src/types/generated/emails/EmailStockLocation.ts+++ b/packages/admin-sdk/src/types/generated/emails/EmailStockLocation.ts@@ -1,6 +1,7 @@-// Typelizer digest 0d3f6a3246f9daf6acbaac746f518488+// Typelizer digest da0e5e1f06910a878a7ba45e4d52ea27//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '.'interface EmailStockLocation {id: string;@@ -8,7 +9,7 @@ interface EmailStockLocation {address1: string | null;city: string | null;zipcode: string | null;- country_code: string | null;+ country_code: CountryCode | null;country_name: string | null;state_code: string | null;state_text: string | null;diff --git a/packages/admin-sdk/src/types/generated/emails/Enums.ts b/packages/admin-sdk/src/types/generated/emails/Enums.tsindex 5fe0e02b46..282ed76c9e 100644--- a/packages/admin-sdk/src/types/generated/emails/Enums.ts+++ b/packages/admin-sdk/src/types/generated/emails/Enums.ts@@ -1,6 +1,8 @@-// Typelizer digest 765c6d4931ce3ff70a584f17f0239c6a+// Typelizer digest df636e9b498440f4e9359baa2b93d981//// DO NOT MODIFY: This file was automatically generated by Typelizer.+export type CountryCode = 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO' | 'AR' | 'AS' | 'AT' | 'AU' | 'AW' | 'AZ' | 'BA' | 'BB' | 'BD' | 'BE' | 'BF' | 'BG' | 'BH' | 'BI' | 'BJ' | 'BL' | 'BM' | 'BN' | 'BO' | 'BQ' | 'BR' | 'BS' | 'BT' | 'BW' | 'BY' | 'BZ' | 'CA' | 'CC' | 'CD' | 'CF' | 'CG' | 'CH' | 'CI' | 'CK' | 'CL' | 'CM' | 'CN' | 'CO' | 'CR' | 'CU' | 'CV' | 'CW' | 'CX' | 'CY' | 'CZ' | 'DE' | 'DJ' | 'DK' | 'DM' | 'DO' | 'DZ' | 'EC' | 'EE' | 'EG' | 'ER' | 'ES' | 'ET' | 'FI' | 'FJ' | 'FK' | 'FM' | 'FO' | 'FR' | 'GA' | 'GB' | 'GD' | 'GE' | 'GF' | 'GG' | 'GH' | 'GI' | 'GL' | 'GM' | 'GN' | 'GP' | 'GQ' | 'GR' | 'GT' | 'GU' | 'GW' | 'GY' | 'HK' | 'HN' | 'HR' | 'HT' | 'HU' | 'ID' | 'IE' | 'IL' | 'IM' | 'IN' | 'IQ' | 'IR' | 'IS' | 'IT' | 'JE' | 'JM' | 'JO' | 'JP' | 'KE' | 'KG' | 'KH' | 'KI' | 'KM' | 'KN' | 'KP' | 'KR' | 'KW' | 'KY' | 'KZ' | 'LA' | 'LB' | 'LC' | 'LI' | 'LK' | 'LR' | 'LS' | 'LT' | 'LU' | 'LV' | 'LY' | 'MA' | 'MC' | 'MD' | 'ME' | 'MF' | 'MG' | 'MH' | 'MK' | 'ML' | 'MM' | 'MN' | 'MO' | 'MP' | 'MQ' | 'MR' | 'MS' | 'MT' | 'MU' | 'MV' | 'MW' | 'MX' | 'MY' | 'MZ' | 'NA' | 'NC' | 'NE' | 'NF' | 'NG' | 'NI' | 'NL' | 'NO' | 'NP' | 'NR' | 'NU' | 'NZ' | 'OM' | 'PA' | 'PE' | 'PF' | 'PG' | 'PH' | 'PK' | 'PL' | 'PM' | 'PN' | 'PR' | 'PS' | 'PT' | 'PW' | 'PY' | 'QA' | 'RE' | 'RO' | 'RS' | 'RU' | 'RW' | 'SA' | 'SB' | 'SC' | 'SD' | 'SE' | 'SG' | 'SH' | 'SI' | 'SJ' | 'SK' | 'SL' | 'SM' | 'SN' | 'SO' | 'SR' | 'SS' | 'ST' | 'SV' | 'SX' | 'SY' | 'SZ' | 'TC' | 'TD' | 'TG' | 'TH' | 'TJ' | 'TK' | 'TL' | 'TM' | 'TN' | 'TO' | 'TR' | 'TT' | 'TV' | 'TW' | 'TZ' | 'UA' | 'UG' | 'US' | 'UY' | 'UZ' | 'VA' | 'VC' | 'VE' | 'VG' | 'VI' | 'VN' | 'VU' | 'WF' | 'WS' | 'YE' | 'YT' | 'ZA' | 'ZM' | 'ZW';+export type CurrencyCode = 'AED' | 'AFN' | 'ALL' | 'AMD' | 'ANG' | 'AOA' | 'ARS' | 'AUD' | 'AWG' | 'AZN' | 'BAM' | 'BBD' | 'BDT' | 'BGN' | 'BHD' | 'BIF' | 'BMD' | 'BND' | 'BOB' | 'BRL' | 'BSD' | 'BTN' | 'BWP' | 'BYN' | 'BYR' | 'BZD' | 'CAD' | 'CDF' | 'CHF' | 'CLF' | 'CLP' | 'CNY' | 'COP' | 'CRC' | 'CUC' | 'CUP' | 'CVE' | 'CZK' | 'DJF' | 'DKK' | 'DOP' | 'DZD' | 'EEK' | 'EGP' | 'ERN' | 'ETB' | 'EUR' | 'FJD' | 'FKP' | 'GBP' | 'GEL' | 'GHS' | 'GIP' | 'GMD' | 'GNF' | 'GTQ' | 'GYD' | 'HKD' | 'HNL' | 'HRK' | 'HTG' | 'HUF' | 'IDR' | 'ILS' | 'INR' | 'IQD' | 'IRR' | 'ISK' | 'JMD' | 'JOD' | 'JPY' | 'KES' | 'KGS' | 'KHR' | 'KMF' | 'KPW' | 'KRW' | 'KWD' | 'KYD' | 'KZT' | 'LAK' | 'LBP' | 'LKR' | 'LRD' | 'LSL' | 'LTL' | 'LVL' | 'LYD' | 'MAD' | 'MDL' | 'MGA' | 'MKD' | 'MMK' | 'MNT' | 'MOP' | 'MRO' | 'MRU' | 'MTL' | 'MUR' | 'MVR' | 'MWK' | 'MXN' | 'MYR' | 'MZN' | 'NAD' | 'NGN' | 'NIO' | 'NOK' | 'NPR' | 'NZD' | 'OMR' | 'PAB' | 'PEN' | 'PGK' | 'PHP' | 'PKR' | 'PLN' | 'PYG' | 'QAR' | 'RON' | 'RSD' | 'RUB' | 'RWF' | 'SAR' | 'SBD' | 'SCR' | 'SDG' | 'SEK' | 'SGD' | 'SHP' | 'SKK' | 'SLE' | 'SLL' | 'SOS' | 'SRD' | 'SSP' | 'STD' | 'STN' | 'SVC' | 'SYP' | 'SZL' | 'THB' | 'TJS' | 'TMM' | 'TMT' | 'TND' | 'TOP' | 'TRY' | 'TTD' | 'TWD' | 'TZS' | 'UAH' | 'UGX' | 'USD' | 'UYI' | 'UYU' | 'UYW' | 'UZS' | 'VED' | 'VEF' | 'VES' | 'VND' | 'VUV' | 'WST' | 'XAF' | 'XCD' | 'XCG' | 'XOF' | 'XPF' | 'YER' | 'ZAR' | 'ZMK' | 'ZMW' | 'ZWD' | 'ZWG' | 'ZWL' | 'ZWN' | 'ZWR';export type FeeKind = 'surcharge' | 'handling' | 'gift_wrap' | 'cod' | 'payment' | 'duty' | 'exchange' | (string & {});export type FulfillmentStatus = 'unfulfilled' | 'fulfilled' | 'delivered' | 'canceled' | (string & {});export type GiftCardStatus = 'active' | 'partially_redeemed' | 'redeemed' | 'canceled' | 'expired' | (string & {});diff --git a/packages/admin-sdk/src/types/generated/emails/index.ts b/packages/admin-sdk/src/types/generated/emails/index.tsindex 5fc9abbbd3..4fb75b92c9 100644--- a/packages/admin-sdk/src/types/generated/emails/index.ts+++ b/packages/admin-sdk/src/types/generated/emails/index.ts@@ -1,7 +1,7 @@-// Typelizer digest 313539cc052ef50b271177d25af80662+// Typelizer digest dccf27f753c2c7480ceedaca57e17a09//// DO NOT MODIFY: This file was automatically generated by Typelizer.-export type { FeeKind, FulfillmentStatus, GiftCardStatus, PaymentStatus, ReturnStatus } from './Enums'+export type { CountryCode, CurrencyCode, FeeKind, FulfillmentStatus, GiftCardStatus, PaymentStatus, ReturnStatus } from './Enums'export type { default as EmailAddress } from './EmailAddress'export type { default as EmailAmountLine } from './EmailAmountLine'export type { default as EmailAppliedPromotion } from './EmailAppliedPromotion'diff --git a/packages/admin-sdk/src/types/generated/index.ts b/packages/admin-sdk/src/types/generated/index.tsindex 7f37e88f39..e42cf30982 100644--- a/packages/admin-sdk/src/types/generated/index.ts+++ b/packages/admin-sdk/src/types/generated/index.ts@@ -1,7 +1,7 @@-// Typelizer digest 3c75528941f0091cb81c67924a9d9232+// Typelizer digest d334abde8134967feb397d5a639f743a//// DO NOT MODIFY: This file was automatically generated by Typelizer.-export type { ActorKind, ClaimStatus, DataRequestStatus, ExchangeStatus, FeeKind, FulfillmentItemStatus, FulfillmentStatus, GiftCardStatus, ImportRowStatus, ImportStatus, InvitationStatus, PaymentStatus, PriceListStatus, ProductStatus, ProductSubmissionStatus, ReturnStatus, SellerPayoutStatus, SellerRequirementSubmissionStatus, SellerStatus, SellerTransferStatus, ShippingLabelStatus, StockLocationKind, TaxExemptionCertificateStatus } from './Enums'+export type { ActorKind, ClaimStatus, CountryCode, CurrencyCode, DataRequestStatus, ExchangeStatus, FeeKind, FulfillmentItemStatus, FulfillmentStatus, GiftCardStatus, ImportRowStatus, ImportStatus, InvitationStatus, PaymentStatus, PriceListStatus, ProductStatus, ProductSubmissionStatus, ReturnStatus, SellerPayoutStatus, SellerRequirementSubmissionStatus, SellerStatus, SellerTransferStatus, ShippingLabelStatus, StockLocationKind, TaxExemptionCertificateStatus } from './Enums'export type { default as Actor } from './Actor'export type { default as Address } from './Address'export type { default as AdminUser } from './AdminUser'diff --git a/packages/admin-sdk/src/types/params/AddressInputParams.ts b/packages/admin-sdk/src/types/params/AddressInputParams.tsindex d53a6cbfd7..1308a211a8 100644--- a/packages/admin-sdk/src/types/params/AddressInputParams.ts+++ b/packages/admin-sdk/src/types/params/AddressInputParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type AddressInputParams = {first_name?: stringlast_name?: string@@ -13,7 +15,7 @@ export type AddressInputParams = {/** Legacy spelling of `postal_code`; send only one of the two. */zipcode?: string/** ISO 3166-1 alpha-2 code, such as `US`. */- country_code?: string+ country_code?: CountryCode/** The state or province abbreviation, such as `NY`. */state_code?: string/** For countries without states in the database. */diff --git a/packages/admin-sdk/src/types/params/CatalogOrderMinimumParams.ts b/packages/admin-sdk/src/types/params/CatalogOrderMinimumParams.tsindex 54a0327f60..afdedb06ed 100644--- a/packages/admin-sdk/src/types/params/CatalogOrderMinimumParams.ts+++ b/packages/admin-sdk/src/types/params/CatalogOrderMinimumParams.ts@@ -1,7 +1,9 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type CatalogOrderMinimumParams = {/** ISO 4217 code. Required on create; one minimum per currency. */- currency?: string+ currency?: CurrencyCodeamount?: string}diff --git a/packages/admin-sdk/src/types/params/CompanyAddressParams.ts b/packages/admin-sdk/src/types/params/CompanyAddressParams.tsindex b4057b6568..c0fa153a69 100644--- a/packages/admin-sdk/src/types/params/CompanyAddressParams.ts+++ b/packages/admin-sdk/src/types/params/CompanyAddressParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type CompanyAddressParams = {first_name?: stringlast_name?: string@@ -13,7 +15,7 @@ export type CompanyAddressParams = {/** Legacy spelling of `postal_code`; send only one of the two. */zipcode?: string/** ISO 3166-1 alpha-2 code, such as `US`. */- country_code?: string+ country_code?: CountryCode/** The state or province abbreviation, such as `NY`. */state_code?: string/** For countries without states in the database. */diff --git a/packages/admin-sdk/src/types/params/CustomerAddressParams.ts b/packages/admin-sdk/src/types/params/CustomerAddressParams.tsindex 3047fc0945..09f34d48eb 100644--- a/packages/admin-sdk/src/types/params/CustomerAddressParams.ts+++ b/packages/admin-sdk/src/types/params/CustomerAddressParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type CustomerAddressParams = {first_name?: stringlast_name?: string@@ -13,7 +15,7 @@ export type CustomerAddressParams = {/** Legacy spelling of `postal_code`; send only one of the two. */zipcode?: string/** ISO 3166-1 alpha-2 code, such as `US`. */- country_code?: string+ country_code?: CountryCode/** The state or province abbreviation, such as `NY`. */state_code?: string/** For countries without states in the database. */diff --git a/packages/admin-sdk/src/types/params/CustomerStoreCreditCreateParams.ts b/packages/admin-sdk/src/types/params/CustomerStoreCreditCreateParams.tsindex aa34149889..2c4ad87dc6 100644--- a/packages/admin-sdk/src/types/params/CustomerStoreCreditCreateParams.ts+++ b/packages/admin-sdk/src/types/params/CustomerStoreCreditCreateParams.ts@@ -1,7 +1,9 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type CustomerStoreCreditCreateParams = {amount: string- currency: string+ currency: CurrencyCodememo?: string}diff --git a/packages/admin-sdk/src/types/params/DeliveryZoneMemberParams.ts b/packages/admin-sdk/src/types/params/DeliveryZoneMemberParams.tsindex 9a0cceb5fd..a9e008301c 100644--- a/packages/admin-sdk/src/types/params/DeliveryZoneMemberParams.ts+++ b/packages/admin-sdk/src/types/params/DeliveryZoneMemberParams.ts@@ -1,8 +1,10 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type DeliveryZoneMemberParams = {member_type: 'country' | 'state' | 'postal_code'- country_code?: string+ country_code?: CountryCode/*** A subdivision code or name. Without `country_code` the country is inferred when only one* country matches.diff --git a/packages/admin-sdk/src/types/params/GiftCardBatchCreateParams.ts b/packages/admin-sdk/src/types/params/GiftCardBatchCreateParams.tsindex 85a0d421cd..7e47355d5d 100644--- a/packages/admin-sdk/src/types/params/GiftCardBatchCreateParams.ts+++ b/packages/admin-sdk/src/types/params/GiftCardBatchCreateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type GiftCardBatchCreateParams = {/** Lowercased and prepended to every generated code. */prefix: string@@ -11,6 +13,6 @@ export type GiftCardBatchCreateParams = {*/codes_count: number/** ISO 4217 currency code. Defaults to the store currency. */- currency?: string+ currency?: CurrencyCodeexpires_at?: string | null}diff --git a/packages/admin-sdk/src/types/params/GiftCardCreateParams.ts b/packages/admin-sdk/src/types/params/GiftCardCreateParams.tsindex 3e3f239986..9d773b6c0a 100644--- a/packages/admin-sdk/src/types/params/GiftCardCreateParams.ts+++ b/packages/admin-sdk/src/types/params/GiftCardCreateParams.ts@@ -1,10 +1,12 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type GiftCardCreateParams = {/** Greater than zero. */amount: string/** ISO 4217 currency code. Defaults to the store currency. */- currency?: string+ currency?: CurrencyCode/** Generated when omitted. */code?: stringexpires_at?: string | nulldiff --git a/packages/admin-sdk/src/types/params/GiftCardUpdateParams.ts b/packages/admin-sdk/src/types/params/GiftCardUpdateParams.tsindex 412a636929..6ed3fde712 100644--- a/packages/admin-sdk/src/types/params/GiftCardUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/GiftCardUpdateParams.ts@@ -1,10 +1,12 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type GiftCardUpdateParams = {/** Greater than zero. */amount?: string/** ISO 4217 currency code. Defaults to the store currency. */- currency?: string+ currency?: CurrencyCode/** Generated when omitted. */code?: stringexpires_at?: string | nulldiff --git a/packages/admin-sdk/src/types/params/MarketCreateParams.ts b/packages/admin-sdk/src/types/params/MarketCreateParams.tsindex b33aaf95fe..fdb37ac2f6 100644--- a/packages/admin-sdk/src/types/params/MarketCreateParams.ts+++ b/packages/admin-sdk/src/types/params/MarketCreateParams.ts@@ -1,10 +1,13 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+import type { CurrencyCode } from '../generated'+export type MarketCreateParams = {/** Display name, unique within the store. */name: string/** ISO 4217 currency code. */- currency: string+ currency: CurrencyCode/** Locale used as the market default. Always part of `supported_locales`. */default_locale: string/** Display prices with tax included. */@@ -21,5 +24,5 @@ export type MarketCreateParams = {/** Locales available in this market. The default locale is always included. */supported_locales?: string[]/** ISO 3166-1 alpha-2 codes of the countries in this market. At least one is required. */- country_codes: string[]+ country_codes: CountryCode[]}diff --git a/packages/admin-sdk/src/types/params/MarketUpdateParams.ts b/packages/admin-sdk/src/types/params/MarketUpdateParams.tsindex 854ad76994..51acb21446 100644--- a/packages/admin-sdk/src/types/params/MarketUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/MarketUpdateParams.ts@@ -1,10 +1,13 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+import type { CurrencyCode } from '../generated'+export type MarketUpdateParams = {/** Display name, unique within the store. */name?: string/** ISO 4217 currency code. */- currency?: string+ currency?: CurrencyCode/** Locale used as the market default. Always part of `supported_locales`. */default_locale?: string/** Display prices with tax included. */@@ -21,5 +24,5 @@ export type MarketUpdateParams = {/** Locales available in this market. The default locale is always included. */supported_locales?: string[]/** ISO 3166-1 alpha-2 codes of the countries in this market. At least one is required. */- country_codes?: string[]+ country_codes?: CountryCode[]}diff --git a/packages/admin-sdk/src/types/params/OrderCreateParams.ts b/packages/admin-sdk/src/types/params/OrderCreateParams.tsindex c4bbd70a88..bd9fec807a 100644--- a/packages/admin-sdk/src/types/params/OrderCreateParams.ts+++ b/packages/admin-sdk/src/types/params/OrderCreateParams.ts@@ -1,6 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.import type { AddressInputParams } from './AddressInputParams'+import type { CurrencyCode } from '../generated'export type OrderCreateParams = {/**@@ -16,7 +17,7 @@ export type OrderCreateParams = {* With `customer_id`, copies the customer's saved billing and shipping addresses onto the order.*/use_customer_default_address?: boolean- currency?: string+ currency?: CurrencyCodemarket_id?: string/** Defaults to the store primary channel when omitted. */channel_id?: stringdiff --git a/packages/admin-sdk/src/types/params/OrderUpdateParams.ts b/packages/admin-sdk/src/types/params/OrderUpdateParams.tsindex aa7d15e3ed..c6c0263883 100644--- a/packages/admin-sdk/src/types/params/OrderUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/OrderUpdateParams.ts@@ -1,6 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.import type { AddressInputParams } from './AddressInputParams'+import type { CurrencyCode } from '../generated'export type OrderUpdateParams = {/**@@ -12,7 +13,7 @@ export type OrderUpdateParams = {external_references?: Record<string, unknown>email?: stringcustomer_id?: string- currency?: string+ currency?: CurrencyCodemarket_id?: string/** Defaults to the store primary channel when omitted. */channel_id?: stringdiff --git a/packages/admin-sdk/src/types/params/PaymentMethodCreateParams.ts b/packages/admin-sdk/src/types/params/PaymentMethodCreateParams.tsindex 995f57e8e6..2cc5bebe20 100644--- a/packages/admin-sdk/src/types/params/PaymentMethodCreateParams.ts+++ b/packages/admin-sdk/src/types/params/PaymentMethodCreateParams.ts@@ -8,8 +8,6 @@ export type PaymentMethodCreateParams = {active?: boolean/** False keeps the method to the dashboard; true also offers it on the storefront. */storefront_visible?: boolean- /** @deprecated Use `capture_method`. Removed in 6.1. */- auto_capture?: boolean | null/** When customers are charged for this method. Null inherits the store setting. */capture_method?: 'checkout' | 'on_dispatch' | 'manual' | nullposition?: numberdiff --git a/packages/admin-sdk/src/types/params/PaymentMethodUpdateParams.ts b/packages/admin-sdk/src/types/params/PaymentMethodUpdateParams.tsindex 9306cff3b5..fabf631179 100644--- a/packages/admin-sdk/src/types/params/PaymentMethodUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/PaymentMethodUpdateParams.ts@@ -6,8 +6,6 @@ export type PaymentMethodUpdateParams = {active?: boolean/** False keeps the method to the dashboard; true also offers it on the storefront. */storefront_visible?: boolean- /** @deprecated Use `capture_method`. Removed in 6.1. */- auto_capture?: boolean | null/** When customers are charged for this method. Null inherits the store setting. */capture_method?: 'checkout' | 'on_dispatch' | 'manual' | nullposition?: numberdiff --git a/packages/admin-sdk/src/types/params/PriceBulkUpsertRowParams.ts b/packages/admin-sdk/src/types/params/PriceBulkUpsertRowParams.tsindex 406a80d611..33ec8b9450 100644--- a/packages/admin-sdk/src/types/params/PriceBulkUpsertRowParams.ts+++ b/packages/admin-sdk/src/types/params/PriceBulkUpsertRowParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type PriceBulkUpsertRowParams = {/*** Present: updates that row. Absent: upserts on@@ -7,7 +9,7 @@ export type PriceBulkUpsertRowParams = {*/id?: string | nullvariant_id: string- currency: string+ currency: CurrencyCode/** Omit or null for a base price. */price_list_id?: string | null/**diff --git a/packages/admin-sdk/src/types/params/PriceCreateParams.ts b/packages/admin-sdk/src/types/params/PriceCreateParams.tsindex 512bfb244b..09cb4e8d70 100644--- a/packages/admin-sdk/src/types/params/PriceCreateParams.ts+++ b/packages/admin-sdk/src/types/params/PriceCreateParams.ts@@ -1,8 +1,10 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type PriceCreateParams = {variant_id: string- currency: string+ currency: CurrencyCode/*** The quantity a line must reach for this price to apply. Omit for the bottom rung of the ladder.* Anything above 1 requires a `price_list_id`.diff --git a/packages/admin-sdk/src/types/params/PriceListPriceOverrideParams.ts b/packages/admin-sdk/src/types/params/PriceListPriceOverrideParams.tsindex 807d29be40..5f957a012d 100644--- a/packages/admin-sdk/src/types/params/PriceListPriceOverrideParams.ts+++ b/packages/admin-sdk/src/types/params/PriceListPriceOverrideParams.ts@@ -1,12 +1,14 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type PriceListPriceOverrideParams = {/*** Updates this price row. Without it, the row upserts on `(variant_id, currency, min_quantity)`.*/id?: stringvariant_id?: string- currency?: string+ currency?: CurrencyCode/** The rung of the variant's ladder. Omit for the bottom rung. */min_quantity?: numberamount?: string | nulldiff --git a/packages/admin-sdk/src/types/params/PriceParams.ts b/packages/admin-sdk/src/types/params/PriceParams.tsindex 237f235d67..80dd73a439 100644--- a/packages/admin-sdk/src/types/params/PriceParams.ts+++ b/packages/admin-sdk/src/types/params/PriceParams.ts@@ -1,7 +1,9 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type PriceParams = {- currency: string+ currency: CurrencyCode/*** A canonical decimal string (`"1234.56"`: period decimal, no grouping). The API does not parse* localized input.diff --git a/packages/admin-sdk/src/types/params/PriceUpdateParams.ts b/packages/admin-sdk/src/types/params/PriceUpdateParams.tsindex efb1e61d37..1986620e77 100644--- a/packages/admin-sdk/src/types/params/PriceUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/PriceUpdateParams.ts@@ -1,8 +1,10 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type PriceUpdateParams = {variant_id?: string- currency?: string+ currency?: CurrencyCode/*** The quantity a line must reach for this price to apply. Omit for the bottom rung of the ladder.* Anything above 1 requires a `price_list_id`.diff --git a/packages/admin-sdk/src/types/params/ProductVariantParams.ts b/packages/admin-sdk/src/types/params/ProductVariantParams.tsindex 288ece75fb..466c6444c8 100644--- a/packages/admin-sdk/src/types/params/ProductVariantParams.ts+++ b/packages/admin-sdk/src/types/params/ProductVariantParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+import type { CurrencyCode } from '../generated'import type { PriceParams } from './PriceParams'import type { StockLevelParams } from './StockLevelParams'import type { VariantOptionParams } from './VariantOptionParams'@@ -9,7 +11,7 @@ export type ProductVariantParams = {sku?: stringbarcode?: stringcost_price?: string | null- cost_currency?: string+ cost_currency?: CurrencyCodeweight?: number | nullheight?: number | nullwidth?: number | null@@ -17,8 +19,8 @@ export type ProductVariantParams = {weight_unit?: 'g' | 'kg' | 'lb' | 'oz'dimensions_unit?: 'mm' | 'cm' | 'in' | 'ft'hs_code?: string- country_of_origin?: stringcustoms_description?: string+ country_of_origin?: CountryCodeminimum_order_quantity?: number | nullorder_multiple?: number | nullpurchase_unit?: stringdiff --git a/packages/admin-sdk/src/types/params/PurchaseOrderCreateParams.ts b/packages/admin-sdk/src/types/params/PurchaseOrderCreateParams.tsindex 1eb0b09855..a203af4b72 100644--- a/packages/admin-sdk/src/types/params/PurchaseOrderCreateParams.ts+++ b/packages/admin-sdk/src/types/params/PurchaseOrderCreateParams.ts@@ -1,12 +1,13 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'import type { PurchaseOrderItemParams } from './PurchaseOrderItemParams'export type PurchaseOrderCreateParams = {supplier_id: stringdestination_location_id: string/** Defaults to the store's currency; set it for a foreign-currency order. */- currency?: string | null+ currency?: CurrencyCode | null/** The day the supplier promised. `null` clears it. */expected_at?: string | null/** The day after which the goods are no longer wanted. `null` clears it. */diff --git a/packages/admin-sdk/src/types/params/PurchaseOrderUpdateParams.ts b/packages/admin-sdk/src/types/params/PurchaseOrderUpdateParams.tsindex 3485aa8d2e..c89ea6f9f0 100644--- a/packages/admin-sdk/src/types/params/PurchaseOrderUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/PurchaseOrderUpdateParams.ts@@ -1,12 +1,13 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'import type { PurchaseOrderItemParams } from './PurchaseOrderItemParams'export type PurchaseOrderUpdateParams = {supplier_id?: stringdestination_location_id?: string/** Defaults to the store's currency; set it for a foreign-currency order. */- currency?: string | null+ currency?: CurrencyCode | null/** The day the supplier promised. `null` clears it. */expected_at?: string | null/** The day after which the goods are no longer wanted. `null` clears it. */diff --git a/packages/admin-sdk/src/types/params/ReportingQueryParams.ts b/packages/admin-sdk/src/types/params/ReportingQueryParams.tsindex 1f567461b7..b803f91fb5 100644--- a/packages/admin-sdk/src/types/params/ReportingQueryParams.ts+++ b/packages/admin-sdk/src/types/params/ReportingQueryParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type ReportingQueryParams = {/** Registered metric names, from the reporting schema endpoint. */metrics: string[]@@ -41,5 +43,5 @@ export type ReportingQueryParams = {sort?: string/** At most 1000. */limit?: number- currency?: string+ currency?: CurrencyCode}diff --git a/packages/admin-sdk/src/types/params/SellerAddressParams.ts b/packages/admin-sdk/src/types/params/SellerAddressParams.tsindex b532b5e081..3f65add5aa 100644--- a/packages/admin-sdk/src/types/params/SellerAddressParams.ts+++ b/packages/admin-sdk/src/types/params/SellerAddressParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type SellerAddressParams = {first_name?: stringlast_name?: string@@ -13,7 +15,7 @@ export type SellerAddressParams = {/** Legacy spelling of `postal_code`; send only one of the two. */zipcode?: string/** ISO 3166-1 alpha-2 code, such as `US`. */- country_code?: string+ country_code?: CountryCode/** The state or province abbreviation, such as `NY`. */state_code?: string/** For countries without states in the database. */diff --git a/packages/admin-sdk/src/types/params/SetupParams.ts b/packages/admin-sdk/src/types/params/SetupParams.tsindex eceb3b5c63..3ed4e4c40c 100644--- a/packages/admin-sdk/src/types/params/SetupParams.ts+++ b/packages/admin-sdk/src/types/params/SetupParams.ts@@ -1,5 +1,8 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+import type { CurrencyCode } from '../generated'+export type SetupParams = {/** The one-time token from the install output. */setup_token: string@@ -13,14 +16,14 @@ export type SetupParams = {* ISO 3166-1 alpha-2 country the store sells from. It determines the default market, the* warehouse, the delivery zones and the currency.*/- country_code: string+ country_code: CountryCode/** Storefront locale. Defaults to the country's own language. */locale?: string/*** ISO 4217 currency. Defaults to the country's own currency: pass one only when the store prices* in something else.*/- currency?: string+ currency?: CurrencyCode/*** Load the demo catalog, customers and orders in the background once the admin account exists.* The load takes minutes, so the response does not wait for it.diff --git a/packages/admin-sdk/src/types/params/ShippingLabelCreateParams.ts b/packages/admin-sdk/src/types/params/ShippingLabelCreateParams.tsindex e0e6a28e98..5e4a53dea3 100644--- a/packages/admin-sdk/src/types/params/ShippingLabelCreateParams.ts+++ b/packages/admin-sdk/src/types/params/ShippingLabelCreateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type ShippingLabelCreateParams = {/*** A `signed_id` from `files.upload()`. Its presence records a label bought elsewhere instead of@@ -21,7 +23,7 @@ export type ShippingLabelCreateParams = {*/cost?: string/** Currency of the cost. */- currency?: string+ currency?: CurrencyCode/** Taken from the file when omitted. */file_format?: 'pdf' | 'png' | 'zpl'/** Tracking page for the consignment the label mints. */diff --git a/packages/admin-sdk/src/types/params/StockLocationCreateParams.ts b/packages/admin-sdk/src/types/params/StockLocationCreateParams.tsindex 4a07ac438a..95233509bc 100644--- a/packages/admin-sdk/src/types/params/StockLocationCreateParams.ts+++ b/packages/admin-sdk/src/types/params/StockLocationCreateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type StockLocationCreateParams = {/*** Identities the record has in external systems, keyed by system: the same@@ -25,7 +27,7 @@ export type StockLocationCreateParams = {phone?: string | nullcompany?: string | null/** ISO-3166 alpha-2 country code. */- country_code?: string | null+ country_code?: CountryCode | null/** State or province abbreviation, resolved against the selected country's states. */state_code?: string | null/** Free-text state for countries that don't have a states list. */diff --git a/packages/admin-sdk/src/types/params/StockLocationUpdateParams.ts b/packages/admin-sdk/src/types/params/StockLocationUpdateParams.tsindex 3ad13fbfb5..d612ecb776 100644--- a/packages/admin-sdk/src/types/params/StockLocationUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/StockLocationUpdateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type StockLocationUpdateParams = {/*** Identities the record has in external systems, keyed by system: the same@@ -25,7 +27,7 @@ export type StockLocationUpdateParams = {phone?: string | nullcompany?: string | null/** ISO-3166 alpha-2 country code. */- country_code?: string | null+ country_code?: CountryCode | null/** State or province abbreviation, resolved against the selected country's states. */state_code?: string | null/** Free-text state for countries that don't have a states list. */diff --git a/packages/admin-sdk/src/types/params/StoreUpdateParams.ts b/packages/admin-sdk/src/types/params/StoreUpdateParams.tsindex 5ba5e9662b..a8e6f66e1e 100644--- a/packages/admin-sdk/src/types/params/StoreUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/StoreUpdateParams.ts@@ -31,10 +31,6 @@ export type StoreUpdateParams = {* method's own setting wins when set.*/capture_method?: 'checkout' | 'on_dispatch' | 'manual'- /** @deprecated Use `capture_method`. Removed in 6.1. */- preferred_auto_capture?: boolean- /** @deprecated Use `capture_method`. Removed in 6.1. */- preferred_auto_capture_on_dispatch?: boolean/** Counts on-hand quantities. Off means everything is treated as always available. */track_inventory_levels?: boolean/** Holds stock for shoppers while they check out, so the same item can't be sold twice. */diff --git a/packages/admin-sdk/src/types/params/SupplierCreateParams.ts b/packages/admin-sdk/src/types/params/SupplierCreateParams.tsindex 8f9998dfe3..c81c2fe1db 100644--- a/packages/admin-sdk/src/types/params/SupplierCreateParams.ts+++ b/packages/admin-sdk/src/types/params/SupplierCreateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type SupplierCreateParams = {name: stringcontact_name?: string | null@@ -11,7 +13,7 @@ export type SupplierCreateParams = {city?: string | nullstate_name?: string | nullstate_code?: string | null- country_code?: string | null+ country_code?: CountryCode | nullpostal_code?: string | nullmetadata?: Record<string, unknown> | null}diff --git a/packages/admin-sdk/src/types/params/SupplierUpdateParams.ts b/packages/admin-sdk/src/types/params/SupplierUpdateParams.tsindex 05602e5a72..4b0985e08f 100644--- a/packages/admin-sdk/src/types/params/SupplierUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/SupplierUpdateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type SupplierUpdateParams = {name?: stringcontact_name?: string | null@@ -11,7 +13,7 @@ export type SupplierUpdateParams = {city?: string | nullstate_name?: string | nullstate_code?: string | null- country_code?: string | null+ country_code?: CountryCode | nullpostal_code?: string | nullmetadata?: Record<string, unknown> | null}diff --git a/packages/admin-sdk/src/types/params/TaxExemptionCertificateParams.ts b/packages/admin-sdk/src/types/params/TaxExemptionCertificateParams.tsindex 9787145e40..8efbd617e7 100644--- a/packages/admin-sdk/src/types/params/TaxExemptionCertificateParams.ts+++ b/packages/admin-sdk/src/types/params/TaxExemptionCertificateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type TaxExemptionCertificateParams = {/** Required when creating. */certificate_number?: string@@ -8,9 +10,8 @@ export type TaxExemptionCertificateParams = {issuing_authority?: string | nullissued_at?: string | nullexpires_at?: string | null- /** Where the certificate holds. Omit both for one valid everywhere. */- country_code?: string | null- /** Where the certificate holds. Omit both for one valid everywhere. */+ /** Where the certificate holds. Omit it and `state_code` for one valid everywhere. */+ country_code?: CountryCode | nullstate_code?: string | null/** A `signed_id` from `files.upload()` with `visibility: 'private'`. */document_signed_id?: stringdiff --git a/packages/admin-sdk/src/types/params/TaxRateParams.ts b/packages/admin-sdk/src/types/params/TaxRateParams.tsindex c2623b6827..37ae0728f0 100644--- a/packages/admin-sdk/src/types/params/TaxRateParams.ts+++ b/packages/admin-sdk/src/types/params/TaxRateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type TaxRateParams = {/** Customer-facing rate name. */name?: string@@ -11,7 +13,7 @@ export type TaxRateParams = {show_rate_in_label?: booleantax_category_id?: string/** ISO country code. A rate naming no country taxes everywhere. */- country_code?: string | null+ country_code?: CountryCode | null/** State abbreviation within that country. */state_code?: string | nullmetadata?: Record<string, unknown>diff --git a/packages/admin-sdk/src/types/params/VariantCreateParams.ts b/packages/admin-sdk/src/types/params/VariantCreateParams.tsindex d547f64421..6566852e06 100644--- a/packages/admin-sdk/src/types/params/VariantCreateParams.ts+++ b/packages/admin-sdk/src/types/params/VariantCreateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+import type { CurrencyCode } from '../generated'import type { PriceParams } from './PriceParams'import type { StockLevelParams } from './StockLevelParams'import type { VariantOptionParams } from './VariantOptionParams'@@ -15,7 +17,7 @@ export type VariantCreateParams = {sku?: stringbarcode?: stringcost_price?: string | null- cost_currency?: string+ cost_currency?: CurrencyCodeweight?: number | nullheight?: number | nullwidth?: number | null@@ -23,8 +25,8 @@ export type VariantCreateParams = {weight_unit?: 'g' | 'kg' | 'lb' | 'oz'dimensions_unit?: 'mm' | 'cm' | 'in' | 'ft'hs_code?: string- country_of_origin?: stringcustoms_description?: string+ country_of_origin?: CountryCodeminimum_order_quantity?: number | nullorder_multiple?: number | nullpurchase_unit?: stringdiff --git a/packages/admin-sdk/src/types/params/VariantUpdateParams.ts b/packages/admin-sdk/src/types/params/VariantUpdateParams.tsindex ab39c23541..2d1c9d4ea5 100644--- a/packages/admin-sdk/src/types/params/VariantUpdateParams.ts+++ b/packages/admin-sdk/src/types/params/VariantUpdateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+import type { CurrencyCode } from '../generated'import type { PriceParams } from './PriceParams'import type { StockLevelParams } from './StockLevelParams'import type { VariantOptionParams } from './VariantOptionParams'@@ -15,7 +17,7 @@ export type VariantUpdateParams = {sku?: stringbarcode?: stringcost_price?: string | null- cost_currency?: string+ cost_currency?: CurrencyCodeweight?: number | nullheight?: number | nullwidth?: number | null@@ -23,8 +25,8 @@ export type VariantUpdateParams = {weight_unit?: 'g' | 'kg' | 'lb' | 'oz'dimensions_unit?: 'mm' | 'cm' | 'in' | 'ft'hs_code?: string- country_of_origin?: stringcustoms_description?: string+ country_of_origin?: CountryCodeminimum_order_quantity?: number | nullorder_multiple?: number | nullpurchase_unit?: stringdiff --git a/packages/admin-sdk/src/zod/generated/Address.ts b/packages/admin-sdk/src/zod/generated/Address.tsindex c871d68211..471a9fad1d 100644--- a/packages/admin-sdk/src/zod/generated/Address.ts+++ b/packages/admin-sdk/src/zod/generated/Address.ts@@ -20,8 +20,6 @@ export const AddressSchema = z.object({quick_checkout: z.boolean(),is_default_billing: z.boolean(),is_default_shipping: z.boolean(),- state_abbr: z.string().nullable(),- country_iso: z.string(),state_name: z.string().nullable(),metadata: z.record(z.string(), z.unknown()),created_at: z.string(),diff --git a/packages/admin-sdk/src/zod/generated/Cart.ts b/packages/admin-sdk/src/zod/generated/Cart.tsindex 7cd02c0b38..a37eb50865 100644--- a/packages/admin-sdk/src/zod/generated/Cart.ts+++ b/packages/admin-sdk/src/zod/generated/Cart.ts@@ -16,7 +16,6 @@ export const CartSchema = z.object({po_number_required: z.boolean(),po_document_filename: z.string().nullable(),po_document_byte_size: z.number().nullable(),- number: z.string(),token: z.string(),email: z.string().nullable(),customer_note: z.string().nullable(),diff --git a/packages/admin-sdk/src/zod/generated/Import.ts b/packages/admin-sdk/src/zod/generated/Import.tsindex 4e2505d9c8..b0a287cfba 100644--- a/packages/admin-sdk/src/zod/generated/Import.ts+++ b/packages/admin-sdk/src/zod/generated/Import.ts@@ -12,8 +12,6 @@ export const ImportSchema = z.object({status: z.string(),store_id: z.string().nullable(),seller_id: z.string().nullable(),- owner_type: z.string().nullable(),- owner_id: z.string().nullable(),user_id: z.string().nullable(),processing_errors: z.string().nullable(),delimiter: z.string(),diff --git a/packages/admin-sdk/src/zod/generated/Market.ts b/packages/admin-sdk/src/zod/generated/Market.tsindex c7392fd692..e3d606c55c 100644--- a/packages/admin-sdk/src/zod/generated/Market.ts+++ b/packages/admin-sdk/src/zod/generated/Market.ts@@ -10,7 +10,6 @@ export const MarketSchema = z.object({tax_inclusive: z.boolean(),default: z.boolean(),country_codes: z.array(z.string()),- country_isos: z.array(z.string()),supported_locales: z.array(z.string()),get countries() { return z.array(CountrySchema).optional(); },created_at: z.string(),diff --git a/packages/admin-sdk/src/zod/generated/PaymentMethod.ts b/packages/admin-sdk/src/zod/generated/PaymentMethod.tsindex 419db9e39c..fffd9b1c06 100644--- a/packages/admin-sdk/src/zod/generated/PaymentMethod.ts+++ b/packages/admin-sdk/src/zod/generated/PaymentMethod.ts@@ -10,7 +10,6 @@ export const PaymentMethodSchema = z.object({source_required: z.boolean(),metadata: z.record(z.string(), z.unknown()),active: z.boolean(),- auto_capture: z.boolean().nullable(),capture_method: z.string().nullable(),resolved_capture_method: z.string(),storefront_visible: z.boolean(),diff --git a/packages/admin-sdk/tests/params-types.test.ts b/packages/admin-sdk/tests/params-types.test.tsindex f57b4e8394..13658559eb 100644--- a/packages/admin-sdk/tests/params-types.test.ts+++ b/packages/admin-sdk/tests/params-types.test.ts@@ -21,6 +21,7 @@ describe('renderParamsTypes', () => {status: { type: 'string', enum: ['draft', "it's"] },weight: { type: 'number', nullable: true },kind: { anyOf: [{ type: 'string', enum: ['tax', 'duty'] }, { type: 'string' }] },+ country_code: { $ref: '#/components/schemas/CountryCode' },country_iso: {type: 'string',deprecated: true,@@ -57,6 +58,8 @@ describe('renderParamsTypes', () => {it('imports the request types a type references', () => {expect(source).toContain("import type { PriceParams } from './PriceParams'\n")+ expect(source).toContain("import type { CountryCode } from '../generated'\n")+ expect(source).toContain(' country_code?: CountryCode\n')})it('maps each kind of value', () => {diff --git a/packages/cli/src/generated/admin-spec.json b/packages/cli/src/generated/admin-spec.jsonindex 3ebd4ecb24..0634825932 100644--- a/packages/cli/src/generated/admin-spec.json+++ b/packages/cli/src/generated/admin-spec.json@@ -1 +1 @@-{"info":{"title":"Admin API","contact":{"name":"Spree Commerce","url":"https://spreecommerce.org","email":"[email protected]"},"description":"Spree Admin API v3 - Administrative API for managing products, orders, and store settings.\n\n## Authentication\n\nThe Admin API requires a secret API key passed in the `x-spree-api-key` header.\nSecret API keys can be generated in the Spree admin dashboard.\n\n## Response Format\n\nAll responses are JSON. List endpoints return paginated responses with `data` and `meta` keys.\nSingle resource endpoints return a flat JSON object.\n\n## Resource IDs\n\nEvery resource is identified by an opaque string ID (e.g. `prod_86Rf07xd4z`,\n`variant_k5nR8xLq`, `or_UkLWZg9DAJ`). Use these IDs everywhere — URL paths,\nrequest bodies, and Ransack filters all accept them directly.\n\n## Error Handling\n\nErrors return a consistent format:\n```json\n{\n \"error\": {\n \"code\": \"validation_error\",\n \"message\": \"Validation failed\",\n \"details\": { \"name\": [\"can't be blank\"] }\n }\n}\n```\n","version":"v3"},"paths":{"/api/v3/admin/auth/login":{"post":{"summary":"Login","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Authenticates an admin user and returns a short-lived JWT access token.\nThe rotatable refresh token is set in an HttpOnly cookie — it is not\nincluded in the response body.\n\nThe `provider` field selects the authentication method. When omitted it\ndefaults to `email`, the built-in email/password login.\n\nTo authenticate against a third-party identity provider (Okta, Azure AD,\nGoogle Workspace SSO, a custom JWT issuer, SAML, etc.), send\n`{ \"provider\": \"<your_key>\", ... }` with the fields that provider\nrequires. The endpoint returns the same JWT regardless of which provider\nauthenticated the request. See\n[Custom API Authentication](https://spreecommerce.org/docs/developer/how-to/custom-api-authentication)\nfor the list of configured providers and their required fields.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"login successful","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthResponse"}}}},"401":{"description":"invalid credentials","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"oneOf":[{"title":"EmailPasswordLogin","description":"Built-in email/password authentication (default when `provider` is omitted).","type":"object","properties":{"provider":{"type":"string","enum":["email"],"default":"email"},"email":{"type":"string","format":"email"},"password":{"type":"string"}},"required":["email","password"]},{"title":"ProviderLogin","description":"Provider-dispatched login. The `provider` key selects a configured\nauthentication provider; the remaining fields are forwarded to it.\nRequired fields depend on the provider — see\n[Custom API Authentication](https://spreecommerce.org/docs/developer/how-to/custom-api-authentication).\n","type":"object","properties":{"provider":{"type":"string","description":"Registered provider key (anything other than `email`).","not":{"enum":["email"]}}},"required":["provider"],"additionalProperties":true}]}}}}}},"/api/v3/admin/auth/refresh":{"post":{"summary":"Refresh token","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Exchanges the HttpOnly refresh-token cookie for a new access JWT and a\nrotated refresh token cookie. No request body or Authorization header\nis required — the cookie alone authenticates the call.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"refresh successful","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthResponse"}}}},"401":{"description":"missing or invalid refresh-token cookie","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/auth/logout":{"post":{"summary":"Logout","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Revokes the refresh-token cookie, effectively logging the admin out.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"logout successful"}}}},"/api/v3/admin/auth/invitations/{id}/accept":{"parameters":[{"name":"id","in":"path","description":"Invitation ID from the emailed link","required":true,"schema":{"type":"string"}}],"post":{"summary":"Accept an invitation","tags":["Authentication"],"description":"Accepts a staff invitation and returns a signed-in admin session, so the\nnew member lands in the dashboard rather than on a login form.\n\nUnauthenticated — the ID and token in the emailed link are the\ncredential. The email is never taken from the request; it always comes\nfrom the invitation.\n\n`password` is required when no account exists for the invited address,\nin which case it sets one. When an account already exists, the same\nfield is how the person proves the account is theirs.\n","parameters":[{"name":"token","in":"query","required":true,"description":"The token from the emailed link","schema":{"type":"string"}}],"responses":{"200":{"description":"invitation accepted, session issued","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthResponse"}}}},"404":{"description":"wrong token, or an invitation that can no longer be accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationAcceptParams"}}},"required":true}}},"/api/v3/admin/me":{"get":{"summary":"Get current admin user and permissions","tags":["Authentication"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the current admin user profile and a serialized list of permissions (CanCanCan rules). The SPA uses these to drive UI permission checks.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"current admin user and permissions","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeResponse"}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update the current admin profile","tags":["Authentication"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Self-service update of the signed-in admin's own profile, such as their admin UI display language (`selected_locale`).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"profile updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeUpdateParams"}}},"required":true}}},"/api/v3/admin/auth/password_resets":{"post":{"summary":"Request password reset","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Requests a password reset email for an admin user. Always returns `202`\nwhether or not the email matches an account, to prevent enumeration.\n\n`redirect_url` is where the emailed link should point (the reset token\nis appended as a `token` query param). It is honoured only on the\ndashboard's origin and for an account that is staff of the store —\notherwise it is silently ignored and the link opens the dashboard's\nreset page. The email is delivered by Spree itself via the\n`admin_user.password_reset_requested` event; this event is never\nforwarded to webhook endpoints.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"202":{"description":"reset requested","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordResetRequestParams"}}},"required":true}}},"/api/v3/admin/auth/password_resets/{id}":{"patch":{"summary":"Reset password","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Consumes a password reset token (the `token` query param from the\nemailed link), sets the new password, and signs the admin in: the\nresponse carries a JWT access token and the rotatable refresh token is\nset in an HttpOnly cookie. The token is single-use — it invalidates as\nsoon as the password changes.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","description":"The reset token from the emailed link","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"password reset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthResponse"}}}},"422":{"description":"invalid or expired token","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordResetParams"}}},"required":true}}},"/api/v3/admin/auth/setup":{"get":{"summary":"Check first-run setup availability","tags":["Authentication"],"description":"Reports whether first-run setup is still available — true only while\nthe installation has no admin user. Unauthenticated; the dashboard\nlogin page uses it to offer the setup screen.\n","responses":{"200":{"description":"setup status","content":{"application/json":{}}}}},"post":{"summary":"Complete first-run setup","tags":["Authentication"],"description":"Creates the first admin account and adopts the seeded store, authorized\nby the one-time setup token printed at install time (rotate it with\n`bin/rails spree:setup:token`). Issues a JWT access token and a\nrefresh-token cookie exactly like login. Returns 404 once any admin\nuser exists — the flow is closed permanently after setup.\n","parameters":[],"responses":{"200":{"description":"setup completed","content":{"application/json":{}}},"404":{"description":"setup not available","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetupParams"}}},"required":true}}},"/api/v3/admin/auth/setup/countries":{"get":{"summary":"List countries for first-run setup","tags":["Authentication"],"description":"Countries the store can be set up in, each with the currency and\nofficial languages derived from it. Unauthenticated, because the setup\nscreen runs before any credential exists. Returns 404 once any admin\nuser exists.\n","responses":{"200":{"description":"countries","content":{"application/json":{}}}}}},"/api/v3/admin/allowed_origins":{"get":{"summary":"List allowed origins","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the CORS allowlist for the current store. Each entry is a\nbare `scheme://host[:port]` permitted to call the admin API from a\nbrowser. Backs the `Rack::Cors` allowlist and the CSRF boundary of\nthe admin cookie session (see\n`docs/plans/5.5-admin-auth-cookie-refresh.md`).\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of origin (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[origin_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `origin` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `origin`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"AllowedOrigin","sortable":["created_at","id","origin","updated_at"]},"responses":{"200":{"description":"allowed origins found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/AllowedOrigin"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create an allowed origin","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds an origin to the admin CORS allowlist. The value must be a bare\n`scheme://host[:port]` (no path, query, or fragment) and use `http` or\n`https`.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"allowed origin created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOrigin"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOriginCreateParams"}}},"required":true}}},"/api/v3/admin/allowed_origins/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Allowed origin ID","schema":{"type":"string"}}],"get":{"summary":"Get an allowed origin","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single allowed origin by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"allowed origin found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOrigin"}}}},"404":{"description":"allowed origin not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update an allowed origin","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an existing allowed origin.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"allowed origin updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOrigin"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOriginUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an allowed origin","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes an origin from the admin CORS allowlist. After deletion the\nadmin SPA running at that origin will no longer be able to call the\nadmin API from a browser.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"allowed origin deleted"}}}},"/api/v3/admin/api_keys":{"get":{"summary":"List API keys","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns publishable and secret API keys for the current store. Secret keys are listed by `token_prefix` only — the plaintext token is delivered exactly once on create.\n\n**Required scope:** `read_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ApiKey","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"API keys found","content":{"application/json":{}}}}},"post":{"summary":"Create an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a publishable or secret API key. The plaintext token is included in the response **once** for secret keys; publishable keys expose their token on every read since they are intended for client-side use.\n\n**Required scope:** `write_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"secret key created — plaintext token returned once","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyCreateParams"}}},"required":true}}},"/api/v3/admin/api_keys/{id}":{"get":{"summary":"Show an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"API key found","content":{"application/json":{}}}}},"patch":{"summary":"Update an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a key. `key_type` and `scopes` are fixed at creation — to change a key's authority, create a new key and revoke the old one.\n\n**Required scope:** `write_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"API key renamed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"API key deleted"}}}},"/api/v3/admin/api_keys/current":{"get":{"summary":"Describe the current API key","tags":["API Keys"],"security":[{"api_key":[]}],"description":"Returns the secret key that authenticated this request, including its live scopes. Useful to confirm a key's real, current authority. Only secret-key principals have a single key to describe.\n\n**Required scope:** none — any key can describe itself (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"current API key","content":{"application/json":{}}}}}},"/api/v3/admin/api_keys/{id}/revoke":{"patch":{"summary":"Revoke an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Marks the key revoked. Future requests using its token will fail; the row is preserved for audit.\n\n**Required scope:** `write_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"API key revoked","content":{"application/json":{}}}}}},"/api/v3/admin/categories":{"get":{"summary":"List categories","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of the store's categories (manual hierarchical taxons; rule-based collections are excluded).\n\n**Required scope:** `read_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name and pretty name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., children, parent, ancestors).","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `automatic` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `children_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `depth` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `parent_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `permalink` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `pretty_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `products_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[parent_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Category","sortable":["automatic","children_count","created_at","depth","id","name","parent_id","permalink","position","pretty_name","products_count","updated_at"]},"responses":{"200":{"description":"categories found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a category. Nests under the parent when parent_id is given, otherwise creates a top-level category.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"category created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryCreateParams"}}},"required":true}}},"/api/v3/admin/categories/{id}":{"get":{"summary":"Get a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single category by ID.\n\n**Required scope:** `read_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., children, parent, ancestors).","schema":{"type":"string"}}],"responses":{"200":{"description":"category found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}},"404":{"description":"category not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a category.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"200":{"description":"category updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a category and its descendants.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"204":{"description":"category deleted"}}}},"/api/v3/admin/categories/{id}/reposition":{"patch":{"summary":"Reposition a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Moves a category to a new parent and/or index within the tree.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"200":{"description":"category repositioned","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryRepositionParams"}}},"required":true}}},"/api/v3/admin/categories/{category_id}/products":{"get":{"summary":"List category products","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Products classified under the category, ordered by their classification position.\n\n**Required scope:** `read_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","created_at","description","discontinue_on","id","name","price","seller_id","slug","status","updated_at"]},"responses":{"200":{"description":"products found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Add products to a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Classifies products under the category in bulk (appended to the end). Already-classified products are skipped; the count reports what was added.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"201":{"description":"products added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}},"delete":{"summary":"Remove products from a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes products from the category's manual classification in bulk. Ids that are not classified are ignored; the count reports what was removed.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"200":{"description":"products removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}}},"/api/v3/admin/categories/{category_id}/products/{id}/reposition":{"patch":{"summary":"Reposition a category product","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Moves a product to a new index among the category's products.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"204":{"description":"product repositioned"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipRepositionParams"}}},"required":true}}},"/api/v3/admin/categories/{category_id}/custom_fields":{"get":{"summary":"List category custom fields","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the category's custom field values.\n\n**Required scope:** `read_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/channels":{"get":{"summary":"List channels","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the channels configured for the current store.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `default` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `store_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Channel","sortable":["active","code","created_at","default","id","name","store_id","updated_at"]},"responses":{"200":{"description":"channels found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Channel"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new channel on the current store. `code` is normalized to a\nURL-safe slug (`Point of Sale` → `point-of-sale`); when omitted it's\nderived from `name`.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"channel created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelCreateParams"}}},"required":true}}},"/api/v3/admin/channels/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"channel found","content":{"application/json":{}}}}},"patch":{"summary":"Update a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"channel updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"channel deleted"}}}},"/api/v3/admin/channels/{id}/add_products":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"post":{"summary":"Publish products on a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Publishes the listed products on this channel. Idempotent — re-publishing\nan already-published product updates its publication window. Products from\nsibling stores are silently dropped.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products published","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelAddProductsParams"}}},"required":true}}},"/api/v3/admin/channels/{id}/remove_products":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"post":{"summary":"Unpublish products from a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Unpublishes the listed products from this channel.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products unpublished","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelRemoveProductsParams"}}},"required":true}}},"/api/v3/admin/channels/{channel_id}/order_routing_rules":{"parameters":[{"name":"channel_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List order routing rules for a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the channel's routing rules in priority order. The rules engine walks them top-down; see the Order Routing guide.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[active_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `channel_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `store_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `channel_id`, `created_at`, `id`, `position`, `store_id`, `type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"OrderRoutingRule","sortable":["active","channel_id","created_at","id","position","store_id","type","updated_at"]},"responses":{"200":{"description":"rules found","content":{"application/json":{}}}}},"post":{"summary":"Create an order routing rule on a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a rule to the channel's routing list. The `type` is the wire shorthand from `GET /order_routing_rules/types` (e.g. `preferred_location`). Omitting `position` appends the rule at the end of the list. Each rule kind can appear at most once per channel — a duplicate `type` is rejected with a validation error.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"rule created","content":{"application/json":{}}},"422":{"description":"unknown rule type","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderRoutingRuleCreateParams"}}},"required":true}}},"/api/v3/admin/channels/{channel_id}/order_routing_rules/{id}":{"parameters":[{"name":"channel_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update an order routing rule","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a rule's `active` flag, `position` (the list reorders around it), or `preferences`. The rule kind cannot be changed — delete and re-create instead.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rule updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderRoutingRuleUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an order routing rule","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"rule deleted"}}}},"/api/v3/admin/order_routing_rules/types":{"get":{"summary":"List available order routing rule types","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Enumerates the registered rule kinds with their labels, descriptions and preference schemas — drives the \"Add rule\" picker in the admin dashboard. Plugins extend the list by registering `Spree::OrderRoutingRule` subclasses via `Spree.order_routing.rules`.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"types found","content":{"application/json":{}}}}}},"/api/v3/admin/custom_field_definitions":{"get":{"summary":"List custom field definitions","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all defined custom fields. Filter by `?q[resource_type_eq]=product` to narrow to one parent type.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of namespace, key, and label (partial, case-insensitive)."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,label,field_type). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[key_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `field_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `key` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `label` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `namespace` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `resource_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `searchable` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `sortable` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `storefront_visible` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `field_type`, `id`, `key`, `label`, `namespace`, `resource_type`, `searchable`, `sortable`, `storefront_visible`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomFieldDefinition","sortable":["created_at","field_type","id","key","label","namespace","resource_type","searchable","sortable","storefront_visible","updated_at"]},"responses":{"200":{"description":"definitions returned","content":{"application/json":{}}}}},"post":{"summary":"Create a custom field definition","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"definition created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomFieldDefinitionCreateParams"}}},"required":true}}},"/api/v3/admin/custom_field_definitions/{id}":{"get":{"summary":"Show a custom field definition","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,label,field_type). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"definition found","content":{"application/json":{}}}}},"patch":{"summary":"Update a custom field definition","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"definition updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomFieldDefinitionUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a custom field definition","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes the definition and cascades to all custom field values referencing it.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"definition deleted"}}}},"/api/v3/admin/customer_groups":{"get":{"summary":"List customer groups","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer groups configured for the current store. Groups\nsegment customers for targeted promotions (see the `customer_group`\npromotion rule) and reporting. The list endpoint never embeds the\nmember list — fetch a single group with `?expand=customers` if you\nneed them inline, or query `/admin/customers?customer_group_id_in=…`\nfor paginated membership.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomerGroup","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"customer groups found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomerGroup"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a customer group","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a customer group in the current store. `customer_ids` is\noptional; when present, customers are attached at create time.\nPass prefixed IDs (e.g. `cus_…`) — the server decodes them\nautomatically.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"customer group created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroup"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroupCreateParams"}}},"required":true}}},"/api/v3/admin/customer_groups/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Customer group prefixed ID","schema":{"type":"string"}}],"get":{"summary":"Get a customer group","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single customer group. Pass `?expand=customers` to embed\nthe full member list inline (recommended only for single-record\nreads — embed cost scales with membership size).\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed. Supported: `customers`.","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"customer group with embedded customers","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroup"}}}},"404":{"description":"customer group not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a customer group","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates name, description, or membership. `customer_ids` is a\nfull-set replacement — the server reconciles the membership to\nmatch the array, adding new IDs and removing ones not present.\nSend `customer_ids: []` to clear all members.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customer group updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroup"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroupUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a customer group","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the group. Member users are not deleted; their `customer_group_users` rows are dropped.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"customer group deleted"}}}},"/api/v3/admin/customers/{customer_id}/custom_fields":{"get":{"summary":"List customer custom fields","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer's custom field values.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/customers/{id}/export":{"get":{"summary":"Export a customer's personal data","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns everything the store holds about this customer, for answering a\nGDPR right-of-access request (Art. 15) that reached the merchant\ndirectly.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customer data","content":{"application/json":{"schema":{"type":"object","properties":{"account":{"type":"object"},"marketing_consent":{"type":"object"},"consent_records":{"type":"array","items":{"type":"object"}},"addresses":{"type":"array","items":{"type":"object"}},"orders":{"type":"array","items":{"type":"object"}},"exported_at":{"type":"string"}}}}}},"404":{"description":"not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/customers/{id}/anonymize":{"post":{"summary":"Erase a customer's personal data","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Carries out a GDPR right-to-erasure request (Art. 17). Personal data is\nreplaced across the account, its addresses, the address snapshots on\npast orders, saved cards, connected identities and live sessions.\n\nOrders, payments and tax records are kept — they carry their own\nretention obligation — with the personal details removed. The country,\nstate and a truncated postal code survive on order addresses so the tax\njurisdiction of a past sale stays provable.\n\nIrreversible.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customer anonymized","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"anonymized":{"type":"boolean"},"anonymized_at":{"type":"string","nullable":true}}}}}}}}},"/api/v3/admin/consent_records":{"get":{"summary":"List consent records","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the consents customers gave or withdrew, newest first, as evidence of what each one agreed to and when.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[email_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `accepted` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `purpose` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `recorded_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `source` | One of `checkout`, `registration`, `account`, `admin`, `newsletter`, `anonymization`, `unknown`, `import`, `storefront` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `accepted`, `created_at`, `email`, `id`, `purpose`, `recorded_at`, `source`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ConsentRecord","sortable":["accepted","created_at","email","id","purpose","recorded_at","source","updated_at"]},"responses":{"200":{"description":"consent records found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ConsentRecord"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/data_requests":{"get":{"summary":"List data requests","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the requests customers made to export or erase their personal data, newest first.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[access]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `access`."},{"name":"q[erasure]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `erasure`."},{"name":"q[in_progress]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_progress`."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `completed_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `access`, `erasure` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `requested_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `status` | One of `pending`, `processing`, `completed`, `failed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `completed_at`, `created_at`, `email`, `id`, `kind`, `number`, `requested_at`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DataRequest","sortable":["completed_at","created_at","email","id","kind","number","requested_at","status","updated_at"]},"responses":{"200":{"description":"data requests found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DataRequest"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Record a data request","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records a request a customer made to the merchant directly, to export\nor erase their personal data, and starts answering it. A request of the\nsame kind already in progress for the customer is returned instead of a\nsecond one.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"202":{"description":"data request recorded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DataRequest"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DataRequestCreateParams"}}},"required":true}}},"/api/v3/admin/customers/{customer_id}/addresses":{"get":{"summary":"List customer addresses","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer's saved addresses.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., country, state). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., first_name,last_name,address1,city). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[address1_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `address1` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `address2` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `city` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `company` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `first_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `last_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `phone` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `postal_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Address","sortable":["address1","address2","city","company","country_code","created_at","first_name","id","last_name","phone","postal_code","state_code","updated_at"]},"responses":{"200":{"description":"addresses found","content":{"application/json":{}}}}},"post":{"summary":"Create a customer address","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a new address to the customer's address book. Pass `is_default_billing: true` or `is_default_shipping: true` to set as the default — the previous default loses its flag in the same transaction.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"address created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerAddressParams"}}},"required":true}}},"/api/v3/admin/customers/{customer_id}/addresses/{id}":{"patch":{"summary":"Update a customer address","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a customer address.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"address updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerAddressParams"}}},"required":true}},"delete":{"summary":"Delete a customer address","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes the address. If it was a default, the customer loses that default (no auto-promotion).\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"address deleted"}}}},"/api/v3/admin/customers/{customer_id}/credit_cards":{"get":{"summary":"List customer credit cards","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer's saved credit cards. Useful for off-session admin charges via `POST /admin/orders/:id/payments { source_id }`.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment_method). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., brand,last4,month,year). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CreditCard","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"credit cards found","content":{"application/json":{}}}}}},"/api/v3/admin/customers/{customer_id}/credit_cards/{id}":{"get":{"summary":"Show a customer credit card","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a saved credit card by ID.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment_method). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., brand,last4,month,year). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"credit card found","content":{"application/json":{}}}}},"delete":{"summary":"Delete a customer credit card","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a saved credit card.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"credit card deleted"}}}},"/api/v3/admin/customers/{customer_id}/store_credits":{"get":{"summary":"List customer store credits","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns store credits issued to the customer.\n\n**Required scope:** `read_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of memo (partial, case-insensitive)."},{"name":"q[from_gift_card]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `from_gift_card`."},{"name":"q[outstanding]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `outstanding`."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., store, created_by). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., amount,amount_used,memo,currency). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `customer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `memo` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[created_by_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `created_by_` | `created_at`, `email`, `first_name`, `id`, `last_name`, `updated_at` |\n| `created_by_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customer_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `customer_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `created_by_id`, `currency`, `customer_id`, `id`, `memo`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StoreCredit","sortable":["amount","created_at","created_by_id","currency","customer_id","id","memo","updated_at"]},"responses":{"200":{"description":"store credits found","content":{"application/json":{}}}}},"post":{"summary":"Issue a store credit to a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"`created_by` is set automatically from the authenticated admin.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"store credit created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerStoreCreditCreateParams"}}},"required":true}}},"/api/v3/admin/customers/{customer_id}/store_credits/{id}":{"patch":{"summary":"Update a store credit","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Update memo / amount. The amount can only be changed if `amount_used == 0`.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"store credit updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerStoreCreditUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a store credit","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes an unused store credit (amount_used == 0). Returns 422 otherwise.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"store credit deleted"}}}},"/api/v3/admin/customers/{customer_id}/tax_identifiers":{"get":{"summary":"List customer tax registrations","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer's own tax registrations, one per kind.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxIdentifier","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"registrations found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TaxIdentifier"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/customers":{"get":{"summary":"List customers","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of customers. Supports Ransack search/filters.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches email, first name, last name or full name (partial, case-insensitive)."},{"name":"q[anonymized]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `anonymized`."},{"name":"q[with_min_total_spent]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `with_min_total_spent` to the given value."},{"name":"q[with_standing_for_company][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_standing_for_company` to the given value."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., addresses, store_credits). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., email,first_name,last_name). id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[email_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `accepts_email_marketing` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `first_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `last_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `phone` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[addresses_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `orders_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `orders_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `orders_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `orders_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `orders_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `orders_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Customer","sortable":["accepts_email_marketing","created_at","email","first_name","id","last_name","phone","updated_at"]},"responses":{"200":{"description":"customers found","content":{"application/json":{}}}}},"post":{"summary":"Create a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a customer. No welcome email is sent automatically.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"customer created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerCreateParams"}}},"required":true}}},"/api/v3/admin/customers/{id}":{"get":{"summary":"Show a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns full customer details including computed order stats (orders_count, total_spent, last_order_completed_at).\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Customer ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations: addresses, orders, store_credits, default_billing_address, default_shipping_address","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., email,first_name,last_name). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"customer found","content":{"application/json":{}}}}},"patch":{"summary":"Update a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates customer attributes. `tags` replaces the full set.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customer updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a customer. Returns 422 if the customer has any orders.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"customer deleted"}}}},"/api/v3/admin/customers/bulk_add_to_groups":{"post":{"summary":"Bulk-add customers to groups","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Attaches each customer in `ids` to every group in `customer_group_ids`.\nIdempotent — customers already in a group are skipped server-side.\nGroups from sibling stores are silently ignored. Returns counts of\ncustomers and groups that were processed (post store-scoping).\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customers added to groups","content":{"application/json":{"schema":{"type":"object","properties":{"customer_count":{"type":"integer"},"customer_group_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerBulkGroupsParams"}}},"required":true}}},"/api/v3/admin/customers/bulk_remove_from_groups":{"post":{"summary":"Bulk-remove customers from groups","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Detaches each customer in `ids` from every group in `customer_group_ids`.\nNo-op for non-members. Groups from sibling stores are silently ignored.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customers removed from groups","content":{"application/json":{"schema":{"type":"object","properties":{"customer_count":{"type":"integer"},"customer_group_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerBulkGroupsParams"}}},"required":true}}},"/api/v3/admin/customers/bulk_add_tags":{"post":{"summary":"Bulk-add tags to customers","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds each tag name in `tags` to every customer in `ids`. Tags are\nupserted by name; re-adding an existing tag is a no-op.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"tags added","content":{"application/json":{"schema":{"type":"object","properties":{"customer_count":{"type":"integer"},"tag_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTagsParams"}}},"required":true}}},"/api/v3/admin/customers/bulk_remove_tags":{"post":{"summary":"Bulk-remove tags from customers","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes each tag name in `tags` from every customer in `ids`. No-op\nfor customers that don't carry the tag.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"tags removed","content":{"application/json":{"schema":{"type":"object","properties":{"customer_count":{"type":"integer"},"tag_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTagsParams"}}},"required":true}}},"/api/v3/admin/email_templates":{"get":{"summary":"List email templates","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every email template merchants may edit: the emails customers\nreceive, the email layout and the shared partials. Each shows what\ncustomers receive now (the store's published version, else Spree's\ndefault) and any draft in progress. Staff emails are not editable.\n\n\n**Required scope:** `read_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default) for the version every language uses","schema":{"type":"string"}}],"responses":{"200":{"description":"email templates found","content":{"application/json":{}}}}}},"/api/v3/admin/email_templates/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"The template key with dots, e.g. `spree.order_mailer.confirm_email`","schema":{"type":"string"}}],"get":{"summary":"Get an email template","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the template for one language: what customers receive now,\nSpree's default, and the draft with its `lock_version`. When Spree's\ndefault changed since the store's version started from it,\n`default_changed` is true and `base_body` holds the default it\nstarted from, to compare with `default_body`.\n\n\n**Required scope:** `read_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default)","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (`draft.updated_by`)","schema":{"type":"string"}}],"responses":{"200":{"description":"email template found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}},"404":{"description":"not an editable template","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"delete":{"summary":"Revert an email template to Spree's default","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Goes back to Spree's default for one language and discards the draft.\nThe store's published versions are kept, so one can still be restored.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default)","schema":{"type":"string"}},{"name":"lock_version","in":"query","required":false,"description":"The draft's `lock_version` as last seen; a draft saved since is refused with 409","schema":{"type":"integer"}}],"responses":{"200":{"description":"email template reverted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}}}}},"/api/v3/admin/email_templates/{email_template_id}/draft":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"put":{"summary":"Save an email template draft","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Saves the draft, in any state; customers keep receiving the published\nversion until it is published. Send the `lock_version` the draft was\nloaded with: a save made from an older copy is refused with 409,\nnaming who saved last. The first save starts from what is published,\nelse Spree's default.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"draft saved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}},"409":{"description":"saved by someone else since it was loaded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateDraftParams"}}},"required":true}},"delete":{"summary":"Discard an email template draft","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default)","schema":{"type":"string"}},{"name":"lock_version","in":"query","required":false,"description":"The draft's `lock_version` as last seen; a draft saved since is refused with 409","schema":{"type":"integer"}}],"responses":{"200":{"description":"draft discarded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}}}}},"/api/v3/admin/email_templates/{email_template_id}/publication":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"post":{"summary":"Publish an email template draft","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Makes the draft what customers receive. The draft is first rendered\nwith sample data; one that does not render (for the layout or a\npartial: in any email using it) is refused with 422, listing each\nproblem with its email and line.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"draft published","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}},"422":{"description":"the draft does not render","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateVersionParams"}}}}}},"/api/v3/admin/email_templates/{email_template_id}/preview":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"post":{"summary":"Preview an email template","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renders the template with sample data built from the store's latest\nmatching record, or the one `record_id` names, and returns the email\nwith the variables it was rendered with. An unsaved `subject` and\n`body` take the place of the current version. The layout and partials\nrender inside an email, `email_key` or the first one. `branding`\npreviews colors and a font before they are saved to the store.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"email template rendered","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplatePreview"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplatePreviewParams"}}},"required":true}}},"/api/v3/admin/email_templates/{email_template_id}/test_email":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"post":{"summary":"Send a test email","tags":["Email Templates"],"security":[{"bearer_auth":[]}],"description":"Sends the template, rendered as the preview renders it, to the\nsigned-in admin, and never to another address: the sample data comes\nfrom a real customer's records. Takes the same body as the preview.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"202":{"description":"test email queued","content":{"application/json":{"schema":{"type":"object","properties":{"sent_to":{"type":"string"}},"required":["sent_to"]}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplatePreviewParams"}}},"required":true}}},"/api/v3/admin/email_templates/{email_template_id}/sample_records":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"get":{"summary":"List records to preview an email template with","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The store's five latest records the template can be previewed with,\nnewest first, to pass as `record_id` to the preview. For the layout\nand partials, those of the email `email_key` names. Empty for an\nemail that needs no record.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"email_key","in":"query","required":false,"description":"For the layout or a partial, the email to show it in","schema":{"type":"string"}}],"responses":{"200":{"description":"records found","content":{"application/json":{}}}}}},"/api/v3/admin/email_templates/{email_template_id}/revisions":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"get":{"summary":"List email template revisions","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every version of the template published in one language, newest\nfirst. Reverting to Spree's default keeps them.\n\n\n**Required scope:** `read_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default)","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (`published_by`)","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"EmailTemplateRevision","sortable":["created_at","id"]},"responses":{"200":{"description":"revisions found","content":{"application/json":{}}}}}},"/api/v3/admin/email_templates/{email_template_id}/revisions/{revision_id}/restoration":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}},{"name":"revision_id","in":"path","required":true,"schema":{"type":"string"}}],"post":{"summary":"Restore an email template revision","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Copies the revision into the draft, to be published like any change.\nSend the draft's `lock_version` when one is open, as when saving it.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"revision copied into the draft","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateRestoreParams"}}}}}},"/api/v3/admin/exports":{"get":{"summary":"List exports","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns CSV exports queued or completed for the current store. Polled by the admin SPA to detect when an export finishes (`done: true`).\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `format` | One of `csv` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `format`, `id`, `number`, `seller_id`, `type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Export","sortable":["created_at","format","id","number","seller_id","type","updated_at"]},"responses":{"200":{"description":"exports found","content":{"application/json":{}}}}},"post":{"summary":"Create an export","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Queues a CSV export. The `type` selects the dataset; `search_params` is an\noptional Ransack query (same shape used by the `q[...]` params on list endpoints)\nthat filters which records are exported. Pass `record_selection: \"all\"` to\nclear the filter server-side and export everything in scope.\n\nGeneration is asynchronous. Poll `GET /admin/exports/{id}` until `done` is `true`,\nthen redirect the browser to `download_url` to fetch the file.\n\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"export queued","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExportCreateParams"}}},"required":true}}},"/api/v3/admin/exports/{id}":{"get":{"summary":"Show an export","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns export status. While `done` is `false`, the SPA continues polling.\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"export found","content":{"application/json":{}}}}},"delete":{"summary":"Delete an export","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes the export and purges its attachment.\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"export deleted"}}}},"/api/v3/admin/exports/{id}/download":{"get":{"summary":"Download an export","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Streams the exported CSV with `Content-Disposition: attachment`. Returns 422 with `code: export_not_ready` while `done` is still `false`. The endpoint is JWT/API-key protected, so SPA clients must fetch it (with `Authorization` header) and trigger the browser download via a Blob URL — a top-level navigation cannot carry the JWT.\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"CSV file","content":{"application/json":{},"text/csv":{"schema":{"type":"string","format":"binary"}}}}}}},"/api/v3/admin/files":{"post":{"summary":"Upload a file","tags":["Files"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Accepts a file and returns a `signed_id` to send to the endpoint that\nuses it — `signed_id` on product media, `avatar_signed_id` on a\ncustomer, `attachment_signed_id` on an import, and so on.\n\nTwo ways to send the bytes, one response:\n\n- **Presigned** (JSON): send the file's metadata, then `PUT` the bytes\n to `upload.url` with exactly `upload.headers`. Use this for anything\n large — the bytes go straight to storage.\n- **Multipart**: send the bytes in a `file` part. The file is stored\n before the response, so `upload` is null. Limited to 10 MB by default.\n\n`signed_id` is opaque: pass it back unchanged and never parse it. It\nstops being attachable at `expires_at`, one day after the upload.\n\n`visibility` picks the storage: `public` (the default) for images and\nvideos customers see, `private` for documents, imports and digital\nproducts. Public uploads accept web images, videos and CSV; private\nuploads accept any type. `checksum` is the file's MD5 digest,\nbase64-encoded — the storage service verifies the bytes against it.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"presigned upload target created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FileUpload"}}}},"422":{"description":"content type not allowed for a public upload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FileUploadCreateParams"}},"multipart/form-data":{"schema":{"$ref":"#/components/schemas/FileUploadCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments":{"get":{"summary":"List fulfillments","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all shipments for an order.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., inventory_units, stock_location, shipping_rates). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., number,status,tracking,cost). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Fulfillment","sortable":["created_at","id","number","updated_at"]},"responses":{"200":{"description":"fulfillments found","content":{"application/json":{}}}}},"post":{"summary":"Create a fulfillment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Manually creates a fulfillment on a completed order, bypassing order routing — for example to mirror a shipment handled by an external carrier or 3PL. Moves the requested line item quantities out of their current fulfillments; when `items` is omitted, every not-yet-shipped unit is moved. Exchange and claim replacements are moved only out of a named `source_fulfillment_id`, which is how a canceled replacement is sent again. Pass `status: 'shipped'` to register an already-shipped fulfillment (fires shipped webhooks and freezes cost/carrier). When `delivery_method_id` is omitted, the fulfillment inherits the delivery method and cost of the source fulfillment(s) it fully drains — keeping the order total unchanged; partially drained splits get no carrier when shipped, and pending fulfillments are otherwise (re)priced by the standard rate engine, which selects the lowest-cost available rate. Pass `cost` to set an explicit shipping cost instead (e.g. the 3PL price) — note this changes the order total and payment state, and is guaranteed to persist only with `status: 'shipped'` (pending fulfillments are re-priced by the rate engine).\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"fulfillment created","content":{"application/json":{}}},"422":{"description":"order not completed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}":{"get":{"summary":"Show a shipment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns details of a specific shipment.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., inventory_units, stock_location, shipping_rates). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., number,status,tracking,cost). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"shipment found","content":{"application/json":{}}}}},"patch":{"summary":"Update a shipment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a fulfillment (tracking, delivery rate).\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"shipment updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}/fulfill":{"patch":{"summary":"Fulfill a fulfillment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Marks a fulfillment as fulfilled.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fulfillment fulfilled","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentFulfillParams"}}}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}/mark_delivered":{"patch":{"summary":"Mark a fulfillment delivered","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records that the customer received the goods. Only a fulfilled shipment can be marked delivered.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fulfillment delivered","content":{"application/json":{}}},"422":{"description":"fulfillment has not shipped","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentMarkDeliveredParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}/cancel":{"patch":{"summary":"Cancel a fulfillment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Cancels a fulfillment.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fulfillment canceled","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}/split":{"patch":{"summary":"Split a fulfillment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Transfers items from this shipment to a new shipment at a different stock location.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fulfillment split","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentSplitParams"}}},"required":true}}},"/api/v3/admin/gift_card_batches":{"get":{"summary":"List gift card batches","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the gift card batches issued by the current store. Each batch\ngroups the cards generated together for a campaign or bulk-issuance\n— the cards themselves live under `/admin/gift_cards` and reference\nthe batch via `gift_card_batch_id`.\n\n\n**Required scope:** `read_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[prefix_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `prefix` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `prefix`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"GiftCardBatch","sortable":["created_at","id","prefix","updated_at"]},"responses":{"200":{"description":"gift card batches found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/GiftCardBatch"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a gift card batch","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Issues a batch of gift cards in a single call. The server generates\n`codes_count` cards inline for small batches (configurable via\n`Spree.config.gift_card_batch_web_limit`, default 500) or enqueues\na background job for larger ones. Each card's code is the batch\n`prefix` followed by random hex.\n\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"gift card batch created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardBatch"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardBatchCreateParams"}}},"required":true}}},"/api/v3/admin/gift_card_batches/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Gift card batch prefixed ID","schema":{"type":"string"}}],"get":{"summary":"Get a gift card batch","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single batch.\n\n**Required scope:** `read_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"gift card batch found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardBatch"}}}},"404":{"description":"gift card batch not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/gift_cards":{"get":{"summary":"List gift cards","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the gift cards issued by the current store. Filter by\n`q[code_cont]` for code search, `q[customer_id_eq]` for cards issued\nto a specific customer, or `q[status_eq]` for status filtering.\n\n\n**Required scope:** `read_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of code (partial, case-insensitive)."},{"name":"q[active]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `active`."},{"name":"q[expired]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `expired`."},{"name":"q[partially_redeemed]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `partially_redeemed`."},{"name":"q[redeemed]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `redeemed`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[code_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `customer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `expires_at` | Date | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `gift_card_batch_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `state` | One of `active`, `partially_redeemed`, `redeemed`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `active`, `partially_redeemed`, `redeemed`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[batch_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `batch_` | `created_at`, `id`, `prefix`, `updated_at` |\n| `customers_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customers_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customers_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customers_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customers_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `customers_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customers_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customers_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `orders_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `orders_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `orders_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `orders_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `orders_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `orders_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `orders_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `users_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `users_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `users_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `users_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `users_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `users_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `users_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `users_tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `code`, `created_at`, `created_by_id`, `currency`, `customer_id`, `expires_at`, `gift_card_batch_id`, `id`, `state`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"GiftCard","sortable":["code","created_at","created_by_id","currency","customer_id","expires_at","gift_card_batch_id","id","state","status","updated_at"]},"responses":{"200":{"description":"gift cards found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/GiftCard"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a gift card","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Issues a gift card scoped to the current store. The code is\nauto-generated when omitted. `currency` defaults to the store's\nconfigured currency. Pass `customer_id` (prefixed ID) to attach the\ncard to a specific customer.\n\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"gift card created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCard"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardCreateParams"}}},"required":true}}},"/api/v3/admin/gift_cards/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Gift card prefixed ID","schema":{"type":"string"}}],"get":{"summary":"Get a gift card","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single gift card.\n\n**Required scope:** `read_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"gift card found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCard"}}}},"404":{"description":"gift card not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a gift card","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an active gift card's editable attributes. Redeemed or\npartially-redeemed cards cannot be edited.\n\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"gift card updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCard"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a gift card","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes an unused gift card. Cards that have been redeemed or\npartially redeemed cannot be deleted and return 422.\n\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"gift card deleted"},"422":{"description":"redeemed gift card cannot be deleted","content":{"application/json":{}}}}}},"/api/v3/admin/imports":{"get":{"summary":"List imports","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns CSV imports queued or completed for the current store.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `pending`, `mapping`, `completed_mapping`, `processing`, `completed`, `failed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `seller_id`, `status`, `type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Import","sortable":["created_at","id","number","seller_id","status","type","updated_at"]},"responses":{"200":{"description":"imports found","content":{"application/json":{}}}}},"post":{"summary":"Create an import","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Queues a CSV import. Upload the file first via `POST /api/v3/admin/files`\nand pass the returned `signed_id` as `attachment_signed_id`. On success the import is in the\n`mapping` state and the response carries the mapping payload: `schema_fields`\n(the canonical columns for the type), `csv_headers`, a `sample_row`, and the\nauto-assigned `mappings`.\n\nAdjust mappings if needed, then call `PATCH /admin/imports/{id}/complete_mapping`\nto start processing. Poll `GET /admin/imports/{id}` while `status` is\n`completed_mapping`/`processing`; terminal statuses are `completed` and `failed`.\n\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"import created in mapping state","content":{"application/json":{}}},"422":{"description":"unknown import type","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportCreateParams"}}},"required":true}}},"/api/v3/admin/imports/template":{"get":{"summary":"Download an import template","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a CSV header row for the given import type, including the custom field columns available for the model.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"type","in":"query","required":true,"description":"Registered import type, e.g. products.","schema":{"type":"string"}}],"responses":{"200":{"description":"CSV template","content":{"application/json":{},"text/csv":{"schema":{"type":"string","format":"binary"}}}}}}},"/api/v3/admin/imports/example":{"get":{"summary":"Download an example import file","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Redirects to a populated example CSV for the given import type — the same sample data `rake spree:load_sample_data` uses, pinned to the installed Spree version. Returns 404 for a type that ships no example file.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"type","in":"query","required":true,"description":"Registered import type, e.g. products.","schema":{"type":"string"}}],"responses":{"302":{"description":"Redirect to the example CSV"}}}},"/api/v3/admin/imports/{id}":{"get":{"summary":"Show an import","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns import status and row counters. The admin dashboard polls this endpoint while `status` is `completed_mapping` or `processing`; `rows_count`, `completed_rows_count` and `failed_rows_count` drive the progress bar. The mapping payload (`csv_headers`, `sample_row`) is only present while `status` is `mapping`.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"import found","content":{"application/json":{}}}}},"delete":{"summary":"Delete an import","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes the import, its rows and the uploaded file. Returns 422 while the import is being processed.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"import deleted"}}}},"/api/v3/admin/imports/{id}/download":{"get":{"summary":"Download the originally uploaded file","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Streams the CSV exactly as it was uploaded — the audit trail for what was imported. JWT/API-key protected; SPA clients fetch it with the Authorization header and trigger the browser download via a Blob URL.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"CSV file","content":{"application/json":{},"text/csv":{"schema":{"type":"string","format":"binary"}}}}}}},"/api/v3/admin/imports/{id}/complete_mapping":{"patch":{"summary":"Complete mapping and start processing","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Applies the submitted column mappings, then starts row processing. Omit `mappings`\nto accept the auto-assigned ones from the create response. Returns 422 when a\nrequired schema field is left unmapped (`details.missing_required_fields`) or a\nfile column is assigned twice.\n\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"mapping completed, processing queued","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportCompleteMappingParams"}}}}}},"/api/v3/admin/imports/{id}/retry_failed_rows":{"patch":{"summary":"Retry failed rows","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Re-processes the rows that failed. The import re-enters `processing`; poll `GET /admin/imports/{id}` until it completes again. Returns 422 when the import is not `completed` or has no failed rows.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"retry queued","content":{"application/json":{}}}}}},"/api/v3/admin/imports/{import_id}/rows":{"get":{"summary":"List import rows","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Paginated rows of an import — the failure report. Filter with `q[status_eq]=failed` to list only rows that could not be imported; each row carries the raw CSV `data` and its `validation_errors`.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"import_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `row_number` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `status` | One of `pending`, `processing`, `completed`, `failed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `row_number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ImportRow","sortable":["created_at","id","row_number","status","updated_at"]},"responses":{"200":{"description":"rows found","content":{"application/json":{}}}}}},"/api/v3/admin/markets":{"get":{"summary":"List markets","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the markets configured for the current store. Markets are\nstore-scoped and ordered by `position` (an `acts_as_list` column —\nupdate the order via `PATCH /markets/{id}` with `position`).\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed. Supported: `countries`.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `default_locale` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `currency`, `default_locale`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Market","sortable":["created_at","currency","default_locale","id","name","position","updated_at"]},"responses":{"200":{"description":"markets found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Market"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a market","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new market for the current store.\n\n- `country_codes` accepts 2-letter ISO country codes (e.g. `[\"DE\", \"FR\"]`);\n the market must contain at least one country. Unknown codes are\n silently dropped.\n- `supported_locales` accepts an array of locale codes; the\n `default_locale` is always implicitly included.\n- Setting `default: true` automatically demotes the previous default\n market in the store.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"market created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Market"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketCreateParams"}}},"required":true}}},"/api/v3/admin/markets/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a market","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"market found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Market"}}}},"404":{"description":"market not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a market","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an existing market. Pass `country_codes` to replace the\nmarket's country list (full-set update), `supported_locales` to\nreplace the supported locales, or `position` to reorder the market\nwithin the store.\n\nSetting `default: true` automatically demotes the previous default.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"market updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Market"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a market","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the market (sets `deleted_at`). The default market and\nthe last remaining market in a store cannot be deleted — both return\n422 with a `validation_error`.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"market deleted"},"422":{"description":"cannot delete default or last market","content":{"application/json":{}}}}}},"/api/v3/admin/option_types/{option_type_id}/custom_fields":{"get":{"summary":"List option type custom fields","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the option type's custom field values.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"option_type_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/option_types":{"get":{"summary":"List option types","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of option types.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name and label (partial, case-insensitive)."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., option_values). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,label,position). id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `dropdown`, `color_swatch`, `buttons` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `label` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"OptionType","sortable":["created_at","id","kind","label","name","position","updated_at"]},"responses":{"200":{"description":"option types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/OptionType"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create an option type","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new option type. Supports nested option values.\n\nOption values can be provided inline and will be created or updated by name.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"option type created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionType"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionTypeCreateParams"}}},"required":true}}},"/api/v3/admin/option_types/{id}":{"get":{"summary":"Get an option type","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single option type by ID, including its option values.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Option type ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., option_values). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,label,position). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"option type found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionType"}}}},"404":{"description":"option type not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update an option type","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an option type. Supports updating nested option values.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Option type ID","schema":{"type":"string"}}],"responses":{"200":{"description":"option type updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionType"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionTypeUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an option type","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes an option type.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Option type ID","schema":{"type":"string"}}],"responses":{"204":{"description":"option type deleted"}}}},"/api/v3/admin/claims":{"get":{"summary":"List claims","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every damage or missing-item claim in the store, across all orders.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `open`, `approved`, `resolved`, `denied`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Claim","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"claims listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Claim"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/claims":{"get":{"summary":"List order claims","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The damage or missing-item claims opened on one order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `open`, `approved`, `resolved`, `denied`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Claim","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"claims listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Claim"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Opens a damage or missing-item claim on a completed order. Each item says how it should be made right: money back, a replacement, or both.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"claim opened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/claims/{id}":{"patch":{"summary":"Update a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the reason, memo or metadata of a claim. Its status moves only through the approve, resolve, deny and cancel actions.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Claim prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"claim updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/claims/{id}/resolve":{"patch":{"summary":"Resolve a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Settles an approved claim with money back, a replacement shipment, or both.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Claim prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"claim resolved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}},"422":{"description":"unknown resolution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimResolveParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/claims/{id}/deny":{"patch":{"summary":"Deny a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Turns down an open claim, recording why for the customer.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Claim prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"claim denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimDenyParams"}}}}}},"/api/v3/admin/orders/{order_id}/claims/{id}/cancel":{"patch":{"summary":"Cancel a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Withdraws a claim that has not been resolved.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Claim prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"claim canceled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimCancelParams"}}}}}},"/api/v3/admin/orders/{order_id}/custom_fields":{"get":{"summary":"List order custom fields","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the order's custom field values.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/digital_links":{"get":{"summary":"List digital links","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the download links issued for digital products bought in this store, newest first.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DigitalLink","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"digital links found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DigitalLink"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/exchanges":{"get":{"summary":"List exchanges","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every exchange in the store, across all orders.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `requested`, `approved`, `received`, `fulfilled`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Exchange","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"exchanges listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Exchange"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/exchanges":{"get":{"summary":"List order exchanges","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The exchanges opened on one order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `requested`, `approved`, `received`, `fulfilled`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Exchange","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"exchanges listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Exchange"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Opens an exchange on a completed order: items coming back, and the variant that goes out in place of each.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"exchange opened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/exchanges/{id}":{"patch":{"summary":"Update an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the warehouse, reason, memo or metadata of an exchange. Its status moves only through the approve, receive, fulfill and cancel actions.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Exchange prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"exchange updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/exchanges/{id}/receive":{"patch":{"summary":"Receive an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records the goods that came back on an approved exchange. Omit `items` to receive everything as requested and resellable.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Exchange prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"exchange received","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeReceiveParams"}}}}}},"/api/v3/admin/orders/{order_id}/exchanges/{id}/fulfill":{"patch":{"summary":"Fulfill an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Ships the replacements for a received exchange and settles any price difference.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Exchange prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"exchange fulfilled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeFulfillParams"}}}}}},"/api/v3/admin/orders/{order_id}/exchanges/{id}/cancel":{"patch":{"summary":"Cancel an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Withdraws an exchange whose goods have not been received.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Exchange prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"exchange canceled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeCancelParams"}}}}}},"/api/v3/admin/orders/{order_id}/tax_lines":{"get":{"summary":"List tax lines","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Typed tax rows on the order. Read-only — written exclusively by the tax provider.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[country_code_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `included` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `provider_id` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `taxability_reason` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `country_code`, `created_at`, `id`, `included`, `provider_id`, `state_code`, `taxability_reason`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxLine","sortable":["country_code","created_at","id","included","provider_id","state_code","taxability_reason","updated_at"]},"responses":{"200":{"description":"tax lines found","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{order_id}/discounts":{"get":{"summary":"List discounts","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Typed discount rows (promotion-sourced and manual) on the order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Discount","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"discounts found","content":{"application/json":{}}}}},"post":{"summary":"Create manual discount","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a manual discount. With line_item_id a single row is created; without it the amount is distributed across line items (largest remainder). This is the sanctioned post-placement discount path and works on completed orders.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"discount created","content":{"application/json":{}}},"422":{"description":"invalid discount","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscountCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/discounts/{id}":{"patch":{"summary":"Update manual discount","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the label or amount of a manual discount and re-sums the order totals. Promotion-sourced rows are owned by recalculation and respond 422.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Discount prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"discount updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscountUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fees":{"get":{"summary":"List fees","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the order's fees, such as surcharges, handling and gift wrap, on the whole order or on one item or delivery.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Fee","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"fees found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Fee"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create fee","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a fee (surcharge, handling, gift wrap, COD, payment fee). Order-level when no target is given. Works on completed orders.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"fee created","content":{"application/json":{}}},"422":{"description":"invalid fee","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeeCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fees/{id}":{"patch":{"summary":"Update fee","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the label, amount or kind of a fee and re-sums the order totals. Works on completed orders.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fee prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fee updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Fee"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeeUpdateParams"}}},"required":true}}},"/api/v3/admin/order_groups":{"get":{"summary":"List order groups","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns checkouts split into one order per seller, grouping the orders placed together.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[customer_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customer_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `customer_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `orders_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `orders_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `orders_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `orders_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `orders_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `orders_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `currency`, `email`, `id`, `number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"OrderGroup","sortable":["created_at","currency","email","id","number","updated_at"]},"responses":{"200":{"description":"order groups found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/OrderGroup"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/discount_codes":{"post":{"summary":"Apply a discount code","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Applies a discount code to a draft order and returns the order. A real code the order does not yet qualify for is kept and applies once it does. Completed orders refuse codes; change their discounts through manual discounts instead.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"discount code applied","content":{"application/json":{}}},"422":{"description":"unknown discount code","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscountCodeApplyParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/gift_cards":{"post":{"summary":"Apply a gift card to an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Applies a gift card by code to the order. Returns the gift card.\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"gift card applied","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardApplyParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/gift_cards/{id}":{"delete":{"summary":"Remove a gift card from an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes the gift card from the order.\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Gift card ID","schema":{"type":"string"}}],"responses":{"204":{"description":"gift card removed"}}}},"/api/v3/admin/orders/{order_id}/items":{"get":{"summary":"List order items","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all line items for an order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., variant, variant.product). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., quantity,price,total). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[additional_tax_total_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `additional_tax_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `adjustment_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cost_price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `discount_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `included_tax_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `non_taxable_adjustment_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `pre_tax_amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `tax_category_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `taxable_adjustment_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `variant_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variant_product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"LineItem","sortable":["additional_tax_total","adjustment_total","cost_price","created_at","discount_total","id","included_tax_total","non_taxable_adjustment_total","order_id","pre_tax_amount","price","quantity","tax_category_id","taxable_adjustment_total","updated_at","variant_id"]},"responses":{"200":{"description":"items found","content":{"application/json":{}}}}},"post":{"summary":"Add an item","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a new line item to the order.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"item added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LineItemCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/items/{id}":{"get":{"summary":"Show an item","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns details of a specific line item.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Item ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., variant, variant.product). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., quantity,price,total). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"item found","content":{"application/json":{}}}}},"patch":{"summary":"Update an item","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an order item quantity or metadata.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Item ID","schema":{"type":"string"}}],"responses":{"200":{"description":"item updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LineItemUpdateParams"}}},"required":true}},"delete":{"summary":"Remove an item","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes an item from the order.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Item ID","schema":{"type":"string"}}],"responses":{"204":{"description":"line item removed"}}}},"/api/v3/admin/orders/{order_id}/store_credits":{"post":{"summary":"Apply customer's store credit to an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Applies the order customer's available store credit. When `amount` is omitted, applies up to the order outstanding balance.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"store credit applied","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoreCreditApplyParams"}}},"required":true}},"delete":{"summary":"Remove store credit from an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes any applied store credit from the order.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"204":{"description":"store credit removed"}}}},"/api/v3/admin/orders":{"get":{"summary":"List orders","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of orders for the current store.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches order number or purchase order number (partial), the billing first or last name, or the exact email."},{"name":"q[complete]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `complete`."},{"name":"q[incomplete]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `incomplete`."},{"name":"q[partially_refunded]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `partially_refunded`."},{"name":"q[refunded]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `refunded`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"sort","in":"query","required":false,"description":"Sort field (e.g., created_at, -created_at, completed_at)","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., items, fulfillments, payments, customer, discounts, billing_address, shipping_address). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., number,total,status,completed_at). id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `channel_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `completed_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `considered_risky` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `coupon_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `customer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `delivery_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `fulfillment_status` | One of `backorder`, `canceled`, `partial`, `unfulfilled`, `fulfilled`, `delivered`, `pending`, `ready`, `shipped` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `item_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `order_group_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `payment_status` | One of `none`, `authorized`, `partially_paid`, `paid`, `partially_refunded`, `refunded`, `overcharged`, `voided`, `balance_due`, `credit_owed`, `failed`, `void` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `po_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `draft`, `placed`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `total_quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[bill_address_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customer_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `line_items_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `line_items_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_group_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `promotions_coupon_codes_` | `code`, `created_at`, `id`, `promotion_id`, `state`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Order","sortable":["channel_id","completed_at","considered_risky","coupon_code","created_at","currency","customer_id","delivery_total","email","fulfillment_status","id","item_total","number","order_group_id","payment_state","payment_status","po_number","seller_id","shipment_state","status","total","total_quantity","updated_at"]},"responses":{"200":{"description":"orders found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a draft order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new draft order in one shot. Customer, items, addresses, currency,\nmarket, channel, locale, notes, metadata, and a coupon code can all be\nprovided inline.\n\nSetting `preferred_stock_location_id` pins the order's preferred fulfillment\nlocation — Order Routing's built-in `PreferredLocation` rule consumes it\nwhen picking which stock location ships each shipment.\n\nInvalid coupon codes are non-fatal — the order is created and the failure\nis reported on the service result (not in the API response body for now).\n\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"order created with preferred_stock_location_id","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{id}":{"get":{"summary":"Show an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns full order details including admin-only fields.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID (e.g., or_xxx)","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., items, fulfillments, payments, customer, discounts, billing_address, shipping_address). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., number,total,status,completed_at). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"order found","content":{"application/json":{}}},"404":{"description":"order not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an order. Supports updating email, addresses, special instructions, and line items.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"order updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a draft order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a draft order. Completed orders cannot be deleted.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"204":{"description":"order deleted"}}}},"/api/v3/admin/orders/{id}/complete":{"patch":{"summary":"Complete an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Completes an order in the `confirm` state, marking it as placed.\n\nSet `notify_customer: true` to send the order confirmation email.\n\nOn a marketplace, an order holding several sellers' goods becomes one\norder per seller, and the response is the order group they belong to\nwith those orders nested inside it.\n\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"order completed","content":{"application/json":{}}},"422":{"description":"order cannot be completed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCompleteParams"}}},"required":true}}},"/api/v3/admin/orders/{id}/cancel":{"patch":{"summary":"Cancel an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Cancels a completed order.\n\n`cancel_reason_id` records why, from the store's own cancellation-reason\nvocabulary (`/admin/order_cancellation_reasons`), and `cancel_note` is a\nstaff-facing note; both are shown on the order afterwards.\n\nStock is always released — the goods are not going out either way — and\nevery payment is settled at the gateway, which releases an\nauthorization it never drew on and refunds a charge it cannot release.\n\n`refund_payments` and `refund_amount` govern the shared payment of a\nsplit checkout, where one payment covers several orders: they decide\nwhether this order's share comes back, and how much of it. A\n`refund_amount` on an ordinary order is refused with a 422.\n\nSet `notify_customer: true` to send the order cancellation email.\n\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"order canceled","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCancelParams"}}},"required":true}}},"/api/v3/admin/orders/{id}/approve":{"patch":{"summary":"Approve an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Approves an order (e.g., for fraud review).\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"order approved","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{id}/resend_confirmation":{"post":{"summary":"Resend confirmation email","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Publishes the order.completed event to trigger confirmation email delivery.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"confirmation resent","content":{"application/json":{}}}}}},"/api/v3/admin/returns":{"get":{"summary":"List returns","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every return in the store, across all orders.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `requested`, `approved`, `received`, `refunded`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Return","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"returns listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Return"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/returns":{"get":{"summary":"List order returns","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The returns opened on one order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `requested`, `approved`, `received`, `refunded`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Return","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"returns listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Return"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Opens a return on a completed order for fulfilled units the customer is sending back.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"return opened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}},"422":{"description":"more returned than was fulfilled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/returns/{id}":{"patch":{"summary":"Update a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the warehouse, reason, memo or metadata of a return. Its status moves only through the approve, receive, refund and cancel actions.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"return updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/returns/{id}/receive":{"patch":{"summary":"Receive a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records what arrived on an approved return. Omit `items` to receive everything as requested and resellable; send rows for a partial or damaged receipt.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"return received","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnReceiveParams"}}}}}},"/api/v3/admin/orders/{order_id}/returns/{id}/refund":{"patch":{"summary":"Refund a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Pays the customer back for a received return, to store credit or through the original payment.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"return refunded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnRefundParams"}}}}}},"/api/v3/admin/orders/{order_id}/returns/{id}/cancel":{"patch":{"summary":"Cancel a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Withdraws a return whose goods have not been received.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"return canceled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnCancelParams"}}}}}},"/api/v3/admin/orders/{order_id}/returns/{return_id}/labels":{"get":{"summary":"List return labels","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The shipping labels issued for sending one return back to the store.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"return_id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[carrier_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carrier` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `source` | One of `purchased`, `uploaded` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `purchased`, `refund_requested`, `refunded` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `tracking_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `carrier`, `created_at`, `id`, `source`, `status`, `tracking_number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ShippingLabel","sortable":["carrier","created_at","id","source","status","tracking_number","updated_at"]},"responses":{"200":{"description":"labels listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ShippingLabel"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/payment_methods":{"get":{"summary":"List payment methods","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's configured payment methods. Use `source_required: true` to know which methods need a saved source.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,type,active). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `storefront_visible` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `position`, `storefront_visible`, `type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PaymentMethod","sortable":["active","created_at","id","name","position","storefront_visible","type","updated_at"]},"responses":{"200":{"description":"payment methods found","content":{"application/json":{}}}}},"post":{"summary":"Create a payment method","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a payment method to the store. `type` is a shorthand from the\npayment method types endpoint, and `preferences` takes the values its\npreference schema declares (gateway credentials among them).\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"payment method created","content":{"application/json":{}}},"422":{"description":"unknown payment method type","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentMethodCreateParams"}}},"required":true}}},"/api/v3/admin/payment_methods/types":{"get":{"summary":"List available payment provider types","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every registered payment provider with the JSON Schema of its `preferences`. `installed` marks a provider the store already has, which a \"Provider\" picker leaves out.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"provider types found","content":{"application/json":{}}}}}},"/api/v3/admin/payment_methods/{id}":{"get":{"summary":"Show a payment method","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a payment method by ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,type,active). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"payment method found","content":{"application/json":{}}}}},"patch":{"summary":"Update a payment method","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a payment method. Its `type` is fixed once created.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"payment method updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentMethodUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/payments":{"get":{"summary":"List payments","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all payments for an order.\n\n**Required scope:** `read_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment_method, source). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., amount,status,number,response_code). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[avs_response_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `avs_response` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cvv_response_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `cvv_response_message` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `response_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state` | One of `checkout`, `processing`, `pending`, `completed`, `failed`, `void`, `invalid` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `checkout`, `processing`, `pending`, `completed`, `failed`, `void`, `invalid` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `payment_method_` | `active`, `created_at`, `id`, `name`, `position`, `storefront_visible`, `type`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `avs_response`, `created_at`, `cvv_response_code`, `cvv_response_message`, `id`, `response_code`, `state`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Payment","sortable":["amount","avs_response","created_at","cvv_response_code","cvv_response_message","id","response_code","state","status","updated_at"]},"responses":{"200":{"description":"payments found","content":{"application/json":{}}}}},"post":{"summary":"Create a payment","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new payment for the order.\n\n**Required scope:** `write_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"payment created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/payments/{id}":{"get":{"summary":"Show a payment","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns details of a specific payment.\n\n**Required scope:** `read_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Payment ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment_method, source). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., amount,status,number,response_code). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"payment found","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{order_id}/payments/{id}/capture":{"patch":{"summary":"Capture a payment","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Captures a pending payment, in full or for part of the authorized amount.\n\n**Required scope:** `write_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Payment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"payment captured","content":{"application/json":{}}},"422":{"description":"capture failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentCaptureParams"}}}}}},"/api/v3/admin/orders/{order_id}/payments/{id}/void":{"patch":{"summary":"Void a payment","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Voids a payment.\n\n**Required scope:** `write_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Payment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"payment voided","content":{"application/json":{}}}}}},"/api/v3/admin/price_lists":{"get":{"summary":"List price lists","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the price lists configured for the current store.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed. Supported: `price_rules`.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `catalog_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `ends_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `match_policy` | One of `all`, `any` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `starts_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `status` | One of `draft`, `active`, `inactive`, `scheduled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `catalog_id`, `created_at`, `ends_at`, `id`, `match_policy`, `name`, `position`, `starts_at`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PriceList","sortable":["catalog_id","created_at","ends_at","id","match_policy","name","position","starts_at","status","updated_at"]},"responses":{"200":{"description":"price lists found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PriceList"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new draft price list.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"price list created (server-to-server — rules + prices)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceListCreateParams"}}},"required":true}}},"/api/v3/admin/price_lists/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"price list found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}},"404":{"description":"price list not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a price list. The optional `rules:` array reconciles nested\nSTI-typed price rules in a single round-trip — existing rules update\nby `id`, new rules build, missing rules destroy. Mirrors the\npromotion editor's \"save the whole thing on Save\" pattern.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price list updated with nested rules","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceListUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the price list. Associated prices are removed asynchronously.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"price list deleted"}}}},"/api/v3/admin/price_lists/{id}/activate":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Activate a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Transitions a draft / inactive list to `active`. If `starts_at` is\nin the future the list is marked `scheduled` instead, matching the\nlegacy admin behaviour.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price list activated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}}}}},"/api/v3/admin/price_lists/{id}/deactivate":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Deactivate a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price list deactivated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}}}}},"/api/v3/admin/prices":{"get":{"summary":"List prices","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Generic prices endpoint covering both base prices and price-list\noverrides. Filter with Ransack: `q[price_list_id_eq]=…`,\n`q[currency_eq]=USD`, `q[price_list_id_null]=true` (base prices only).\n\nThe admin spreadsheet uses this with server-side pagination so it\nscales past the metadata-PATCH path on `/price_lists/:id`.\n\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches the variant's SKU, option value or product name, as variant search does."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Comma-separated sort keys. Supports e.g. `variant_product_name,variant_id`.","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed. Supported: `variant`.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `compare_at_amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `min_quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `price_list_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `variant_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[price_list_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `price_list_` | `catalog_id`, `created_at`, `ends_at`, `id`, `match_policy`, `name`, `position`, `starts_at`, `status`, `updated_at` |\n| `variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variant_product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Price","sortable":["amount","compare_at_amount","created_at","currency","id","min_quantity","price_list_id","updated_at","variant_id"]},"responses":{"200":{"description":"prices found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Price"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a price","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a single price. Omit `price_list_id` to create a base price.\nFor more than a handful of rows, prefer `POST /admin/prices/bulk_upsert`.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"price created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Price"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceCreateParams"}}},"required":true}}},"/api/v3/admin/prices/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a price","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Price"}}}},"404":{"description":"price not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a price","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Price"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a price","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the price (acts_as_paranoid).\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"price deleted"}}}},"/api/v3/admin/prices/bulk_upsert":{"post":{"summary":"Bulk-upsert prices","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Upserts a batch of prices in a single SQL round trip.\n\nEach row either:\n* targets an existing price by `id`, OR\n* matches on the unique key `(variant_id, currency, price_list_id)` —\n updating the existing row if one exists, creating one otherwise.\n\nModel callbacks (e.g. PriceHistory) are bypassed; this is a\nbulk-write fast path for the admin spreadsheet. The response\ncarries `price_count` — the number of rows touched.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"prices upserted","content":{"application/json":{"schema":{"type":"object","properties":{"price_count":{"type":"integer"}}}}}},"422":{"description":"missing prices key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceBulkUpsertParams"}}},"required":true}}},"/api/v3/admin/prices/bulk_destroy":{"delete":{"summary":"Bulk-delete prices","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes each price in `ids`. Returns the count actually destroyed.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"prices deleted","content":{"application/json":{"schema":{"type":"object","properties":{"price_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceBulkDestroyParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/custom_fields":{"get":{"summary":"List product custom fields","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the product's custom field values.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{}}}}},"post":{"summary":"Create a product custom field","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sets a custom field value on the product. Requires an existing CustomFieldDefinition; pass its prefixed `cfdef_…` id.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"custom field created","content":{"application/json":{}}},"422":{"description":"duplicate definition for the same product","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomFieldCreateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/custom_fields/{id}":{"get":{"summary":"Show a product custom field","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"custom field found","content":{"application/json":{}}}}},"patch":{"summary":"Update a product custom field","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates the custom field's `value`. The linked definition cannot be changed — delete and recreate to switch.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"custom field updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomFieldUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a product custom field","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"custom field deleted"}}}},"/api/v3/admin/products/{product_id}/digital_assets":{"parameters":[{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"get":{"summary":"List product digital assets","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the downloadable files attached to the product's variants, oldest first.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DigitalAsset","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"digital assets found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DigitalAsset"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a product digital asset","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Attaches a downloadable file to one of the product's variants (the\ndefault variant when `variant_id` is omitted). Upload the file first\nthrough `POST /api/v3/admin/files` with `visibility: 'private'`, then\nsend its `signed_id` here. A provider-backed asset sends\n`provider_type` and `provider_settings` instead of a file.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"digital asset created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigitalAsset"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigitalAssetCreateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/digital_assets/{id}":{"parameters":[{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Digital asset ID","schema":{"type":"string"}}],"patch":{"summary":"Update a product digital asset","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes an asset's download limits, or replaces its file with a new\nprivate `signed_id`. Links customers already received keep working and\nserve the new file.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"digital asset updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigitalAsset"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigitalAssetUpdateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/translations":{"get":{"summary":"List product translations","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the full translation matrix for the product: the source value and content type per translatable field, plus the translated value for every supported locale.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"translations found","content":{"application/json":{}}}}}},"/api/v3/admin/products":{"get":{"summary":"List products","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of products for the current store.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"sort","in":"query","required":false,"description":"Sort field (e.g., name, -name, price, -price, best_selling)","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., variants, media, option_types, categories). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,slug,price,status). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\nAlso filters and sorts on the store's searchable custom fields, as `q[cf_<namespace>_<key>_<predicate>]` and `sort=cf_<namespace>_<key>`.\n\n**Sort by:** `available_on`, `best_selling`, `created_at`, `description`, `discontinue_on`, `id`, `manual`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","best_selling","created_at","description","discontinue_on","id","manual","name","price","seller_id","slug","status","updated_at"],"custom_fields":true},"responses":{"200":{"description":"products found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new product. Supports nested variants with prices and option types.\n\nOption types and values are auto-created if they don't exist.\nPrices are upserted by currency. Stock items are upserted by stock location.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"product created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Product"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductCreateParams"}}},"required":true}}},"/api/v3/admin/products/{id}":{"get":{"summary":"Get a product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single product by ID.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID (e.g., prod_xxx)","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., variants, media, option_types, categories). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,slug,price,status). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"product found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Product"}}}},"404":{"description":"product not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a product. Only provided fields are updated.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"200":{"description":"product updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Product"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes a product.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"204":{"description":"product deleted"},"422":{"description":"deletion refused by a store rule","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/products/bulk_status_update":{"post":{"summary":"Bulk-update product status","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sets `status` on each product in `ids`. Reindexes the affected products\nfor search. Cross-store IDs are silently dropped. Returns counts.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"cross-store products silently dropped","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"status":{"type":"string"}}}}}},"422":{"description":"invalid status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkStatusParams"}}},"required":true}}},"/api/v3/admin/products/bulk_add_to_categories":{"post":{"summary":"Bulk-add products to categories","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Attaches each product in `ids` to every category (category) in `category_ids`.\nCategories from sibling stores are silently ignored.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products added to categories","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"category_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkCategoriesParams"}}},"required":true}}},"/api/v3/admin/products/bulk_remove_from_categories":{"post":{"summary":"Bulk-remove products from categories","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Detaches each product in `ids` from every category in `category_ids`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products removed from categories","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkCategoriesParams"}}},"required":true}}},"/api/v3/admin/products/bulk_add_to_collections":{"post":{"summary":"Bulk-add products to collections","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Attaches each product in `ids` to every manual collection in `collection_ids`.\nAutomatic (rule-based) and sibling-store collections are silently ignored.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products added to collections","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"collection_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkCollectionsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_remove_from_collections":{"post":{"summary":"Bulk-remove products from collections","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Detaches each product in `ids` from every collection in `collection_ids`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products removed from collections","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkCollectionsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_add_to_channels":{"post":{"summary":"Bulk-add products to channels","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Publishes each product in `ids` on every channel in `channel_ids`. Idempotent —\nre-publishing on an existing channel is a no-op. Channels from sibling stores\nare silently ignored.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products published on channels","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"channel_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkChannelsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_remove_from_channels":{"post":{"summary":"Bulk-remove products from channels","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Unpublishes each product in `ids` from every channel in `channel_ids`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products unpublished from channels","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"channel_count":{"type":"integer"},"removed":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkChannelsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_add_tags":{"post":{"summary":"Bulk-add tags to products","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds each tag name in `tags` to every product in `ids`. Tags are upserted by name.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"tags added","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"tag_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTagsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_remove_tags":{"post":{"summary":"Bulk-remove tags from products","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes each tag in `tags` from every product in `ids`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"tags removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTagsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_destroy":{"delete":{"summary":"Bulk-delete products","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes each product in `ids`. Returns the count actually destroyed.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products deleted","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkDestroyParams"}}},"required":true}}},"/api/v3/admin/products/{id}/reject":{"parameters":[{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"patch":{"summary":"Reject a submitted product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Turns down a product a seller submitted for review. The `reason` is\nsent back to the seller, who can fix the product and submit it again.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"product rejected","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Product"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductRejectParams"}}},"required":true}}},"/api/v3/admin/translations":{"get":{"summary":"Translation coverage for a resource type","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Reports how much of each record is translated into each of the store's non-default locales, plus per-locale totals. A record counts as covered for a locale only when every one of its translatable fields is filled in.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"resource_type","in":"query","required":true,"description":"A translatable resource type, e.g. `product`, `category`, `option_type`.","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"search","in":"query","required":false,"description":"Free-text term, applied through whichever predicate the resource type whitelists (reported back as `search_field`).","schema":{"type":"string"}}],"responses":{"200":{"description":"coverage found","content":{"application/json":{}}},"404":{"description":"resource type is not translatable","content":{"application/json":{}}}}}},"/api/v3/admin/policies":{"get":{"summary":"List policies","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's policy documents — terms of service, privacy\npolicy, returns policy, shipping policy, and any others the merchant\nhas written. Every store is created with the four standard policies,\nnamed but empty.\n\nA marketplace seller's own policies are managed by the seller and are\nnot listed here.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `owner_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `owner_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `owner_id`, `owner_type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Policy","sortable":["created_at","id","name","owner_id","owner_type","updated_at"]},"responses":{"200":{"description":"policies listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Policy"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a policy","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a policy. `body` accepts HTML and is sanitized before it is\nstored; the stored markup is returned as `body_html`, and `body` reads\nback as plain text.\n\nThe slug is derived from the name when one is not given, and is what\nthe storefront addresses the policy by.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"policy created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Policy"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PolicyCreateParams"}}},"required":true}}},"/api/v3/admin/policies/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Policy prefixed ID or slug","schema":{"type":"string"}}],"get":{"summary":"Get a policy","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single policy, addressed by prefixed ID or by slug.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"policy found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Policy"}}}},"404":{"description":"policy not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a policy","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a policy. `body` accepts HTML and is sanitized before it is stored.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"policy updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Policy"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PolicyUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a policy","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a policy. The four policies a store is created with can be\ndeleted like any other — they are conventions, not fixtures.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"policy deleted"}}}},"/api/v3/admin/claim_reasons":{"get":{"summary":"List claim reasons","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Why a customer raised a claim — what the merchant got wrong, rather than a change of mind.\n\nThe vocabulary is the merchant's own — seeded with a starting set and\nedited from the dashboard. Inactive rows stay for the records that\nalready reference them, but are not offered on new ones.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ClaimReason","sortable":["active","created_at","id","name","updated_at"]},"responses":{"200":{"description":"claim reasons found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a claim reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a claim reason to this store. Names are unique per store, ignoring case.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"claim reason created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonCreateParams"}}},"required":true}}},"/api/v3/admin/claim_reasons/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Claim reason ID","schema":{"type":"string"}}],"get":{"summary":"Get a claim reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single claim reason by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"claim reason found","content":{"application/json":{}}},"404":{"description":"claim reason not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a claim reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a claim reason or retires it. Deactivating keeps it on the records\nthat already carry it while removing it from the pickers.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"claim reason updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a claim reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a claim reason the store no longer uses. A reason already recorded\non a document is refused — deactivate it instead, so the history it\nexplains stays readable.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"claim reason deleted"}}}},"/api/v3/admin/order_cancellation_reasons":{"get":{"summary":"List order cancellation reasons","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Why an order was called off before it shipped. Staff pick one when canceling.\n\nThe vocabulary is the merchant's own — seeded with a starting set and\nedited from the dashboard. Inactive rows stay for the records that\nalready reference them, but are not offered on new ones.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"OrderCancellationReason","sortable":["active","created_at","id","name","updated_at"]},"responses":{"200":{"description":"order cancellation reasons found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a order cancellation reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a order cancellation reason to this store. Names are unique per store, ignoring case.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"order cancellation reason created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonCreateParams"}}},"required":true}}},"/api/v3/admin/order_cancellation_reasons/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Order cancellation reason ID","schema":{"type":"string"}}],"get":{"summary":"Get a order cancellation reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single order cancellation reason by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"order cancellation reason found","content":{"application/json":{}}},"404":{"description":"order cancellation reason not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a order cancellation reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a order cancellation reason or retires it. Deactivating keeps it on the records\nthat already carry it while removing it from the pickers.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"order cancellation reason updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a order cancellation reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a order cancellation reason the store no longer uses. A reason already recorded\non a document is refused — deactivate it instead, so the history it\nexplains stays readable.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"order cancellation reason deleted"}}}},"/api/v3/admin/refund_reasons":{"get":{"summary":"List refund reasons","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Why money went back. Some rows are seeded and looked up by name, so they refuse renaming and deletion.\n\nThe vocabulary is the merchant's own — seeded with a starting set and\nedited from the dashboard. Inactive rows stay for the records that\nalready reference them, but are not offered on new ones.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"RefundReason","sortable":["active","created_at","id","name","updated_at"]},"responses":{"200":{"description":"refund reasons found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a refund reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a refund reason to this store. Names are unique per store, ignoring case.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"refund reason created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonCreateParams"}}},"required":true}}},"/api/v3/admin/refund_reasons/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Refund reason ID","schema":{"type":"string"}}],"get":{"summary":"Get a refund reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single refund reason by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"refund reason found","content":{"application/json":{}}},"404":{"description":"refund reason not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a refund reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a refund reason or retires it. Deactivating keeps it on the records\nthat already carry it while removing it from the pickers.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"refund reason updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a refund reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a refund reason the store no longer uses. A reason already recorded\non a document is refused — deactivate it instead, so the history it\nexplains stays readable.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"refund reason deleted"}}}},"/api/v3/admin/return_reasons":{"get":{"summary":"List return reasons","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Why a customer is sending items back. Shared by returns and exchanges.\n\nThe vocabulary is the merchant's own — seeded with a starting set and\nedited from the dashboard. Inactive rows stay for the records that\nalready reference them, but are not offered on new ones.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ReturnReason","sortable":["active","created_at","id","name","updated_at"]},"responses":{"200":{"description":"return reasons found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a return reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a return reason to this store. Names are unique per store, ignoring case.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"return reason created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonCreateParams"}}},"required":true}}},"/api/v3/admin/return_reasons/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Return reason ID","schema":{"type":"string"}}],"get":{"summary":"Get a return reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single return reason by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"return reason found","content":{"application/json":{}}},"404":{"description":"return reason not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a return reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a return reason or retires it. Deactivating keeps it on the records\nthat already carry it while removing it from the pickers.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"return reason updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a return reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a return reason the store no longer uses. A reason already recorded\non a document is refused — deactivate it instead, so the history it\nexplains stays readable.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"return reason deleted"}}}},"/api/v3/admin/promotions/{promotion_id}/coupon_codes":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List coupon codes for a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the auto-generated coupon codes for a multi-code promotion. Single-code promotions store the code on the promotion itself; this endpoint returns an empty list for them.\n\n**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[code_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `promotion_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `state` | One of `unused`, `used` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[promotion_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `promotion_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `code`, `created_at`, `id`, `promotion_id`, `state`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CouponCode","sortable":["code","created_at","id","promotion_id","state","updated_at"]},"responses":{"200":{"description":"coupon codes found","content":{"application/json":{}}}}}},"/api/v3/admin/promotions/{promotion_id}/promotion_actions":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List actions for a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PromotionAction","sortable":["created_at","id","position","updated_at"]},"responses":{"200":{"description":"actions found","content":{"application/json":{}}}}},"post":{"summary":"Create an action on a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a new action to a promotion. The `type` is the wire shorthand from `GET /promotion_actions/types` (e.g. `free_shipping`, `create_item_adjustments`).\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"action created","content":{"application/json":{}}},"422":{"description":"unknown action type","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionActionCreateParams"}}},"required":true}}},"/api/v3/admin/promotions/{promotion_id}/promotion_actions/{id}":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update an action on a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes an action's settings. For adjustment actions, `calculator`\nsets the calculator and its preferences; sending a different\ncalculator `type` swaps it. The action's own `type` is fixed once\ncreated.\n\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"action updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionActionUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an action from a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"action deleted"}}}},"/api/v3/admin/promotions/{promotion_id}/promotion_rules":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List rules for a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PromotionRule","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"rules found","content":{"application/json":{}}}}},"post":{"summary":"Create a rule on a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a new rule to a promotion. The `type` is the wire shorthand from `GET /promotion_rules/types` (e.g. `currency`, `item_total`, `product`).\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"rule created with preferences","content":{"application/json":{}}},"422":{"description":"unknown rule type","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionRuleCreateParams"}}},"required":true}}},"/api/v3/admin/promotions/{promotion_id}/promotion_rules/{id}":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a rule's preferences","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rule updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionRuleUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a rule from a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"rule deleted"}}}},"/api/v3/admin/promotions":{"get":{"summary":"List promotions","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's promotions, including manual coupon and automatic promotions.\n\n**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name and code (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `expires_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `coupon_code`, `automatic` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `path` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `promotion_category_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `starts_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[coupon_codes_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `coupon_codes_` | `code`, `created_at`, `id`, `promotion_id`, `state`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Promotion","sortable":["code","created_at","expires_at","id","kind","name","path","promotion_category_id","starts_at","updated_at"]},"responses":{"200":{"description":"promotions found","content":{"application/json":{}}}}},"post":{"summary":"Create a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new promotion. `code` is required for single-code coupon promotions;\npass `multi_codes: true` with `number_of_codes` to auto-generate a batch.\n\nRules and actions can be created in the same request by passing arrays of\n`{ type, preferences, ... }` rows. The server reconciles to the desired set:\nnew rows are built, existing rows (by `id`) are updated, omitted rows are removed.\n\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"promotion created with rules and actions","content":{"application/json":{}}},"422":{"description":"invalid params","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionCreateParams"}}},"required":true}}},"/api/v3/admin/promotions/{id}":{"get":{"summary":"Show a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"promotion found","content":{"application/json":{}}}}},"patch":{"summary":"Update a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a promotion. The `rules` and `actions` arrays are treated as\na *desired set* — rows with `id` update in place, rows without `id` are\nbuilt fresh, and any existing row not present in the array is destroyed.\nPass `rules: []` or `actions: []` to clear them.\n\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rules and actions cleared with empty arrays","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"promotion deleted"}}}},"/api/v3/admin/promotion_actions/types":{"get":{"summary":"List available promotion action types","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the registered Spree::PromotionAction subclasses with their preference schemas. Used by admin UIs to populate the \"Add action\" picker and render generic preference forms.\n\n**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"action types found","content":{"application/json":{}}}}}},"/api/v3/admin/promotion_rules/types":{"get":{"summary":"List available promotion rule types","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the registered Spree::PromotionRule subclasses with their preference schemas.\n\n**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rule types found","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{order_id}/refunds":{"get":{"summary":"List refunds","tags":["Refunds"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all refunds for an order.\n\n**Required scope:** `read_refunds` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment, refund_reason). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., amount,reason,transaction_id). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Refund","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"refunds found","content":{"application/json":{}}}}},"post":{"summary":"Create a refund","tags":["Refunds"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a refund for a payment on the order. The refund is automatically processed via the payment gateway.\n\n**Required scope:** `write_refunds` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"refund created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefundCreateParams"}}},"required":true}}},"/api/v3/admin/locales":{"get":{"summary":"List supported locales","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the locales a merchant can translate content into for the current store, with the default and right-to-left flags.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"locales found","content":{"application/json":{}}}}}},"/api/v3/admin/store":{"get":{"summary":"Get the current store","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the current store configuration. The store is resolved from the request context (host or admin selection); there is no `id` parameter.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"current store","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Store"}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update the current store","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates the current store configuration.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"store updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Store"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoreUpdateParams"}}},"required":true}}},"/api/v3/admin/tags":{"get":{"summary":"List tags","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns tag names for a given taggable type. Used for autocomplete in tag inputs on products, orders, and customers.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"taggable_type","in":"query","required":true,"description":"Shorthand of the tagged resource: `product`, `order` or `customer`","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"description":"Optional case-insensitive substring filter","schema":{"type":"string"}}],"responses":{"200":{"description":"tags found","content":{"application/json":{}}},"422":{"description":"invalid taggable type","content":{"application/json":{}}}}}},"/api/v3/admin/tax_categories":{"get":{"summary":"List tax categories","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the tax categories products and delivery methods can be assigned to, which tax rates then apply to.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `is_default` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `tax_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxCategory","sortable":["created_at","id","is_default","name","tax_code","updated_at"]},"responses":{"200":{"description":"tax categories found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TaxCategory"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a tax category","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a tax category. `tax_code` is the code a tax provider uses to classify the goods in it.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"tax category created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxCategory"}}}},"422":{"description":"validation failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxCategoryCreateParams"}}},"required":true}}},"/api/v3/admin/tax_categories/{id}":{"parameters":[{"name":"id","in":"path","description":"Tax category ID","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a tax category","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"tax category updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxCategory"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxCategoryUpdateParams"}}},"required":true}}},"/api/v3/admin/tax_rates":{"get":{"summary":"List tax rates","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's tax rates. Rates are the entire configuration of\nthe built-in tax provider: each pairs a tax category with a jurisdiction\n(a country, optionally narrowed to one state) and a percentage, and\ndecides whether the tax is already included in the product price\n(VAT-style) or added on top (US-style).\n\nMarkets using an external tax provider ignore these rows — that\nprovider carries its own jurisdiction data.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `included_in_price` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `tax_category_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `amount`, `country_code`, `created_at`, `id`, `included_in_price`, `name`, `state_code`, `tax_category_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxRate","sortable":["amount","country_code","created_at","id","included_in_price","name","rate","state_code","tax_category_id","updated_at"]},"responses":{"200":{"description":"tax rates found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TaxRate"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a tax rate","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a tax rate for the current store. Give either `rate` as a\ndecimal string (`\"0.19\"`) or `rate_percent` as a percentage string (`\"19\"`).\n\nName the jurisdiction with `country_code` (and `state_code` for a\nstate-level rate). Omitting the country makes the rate apply everywhere.\n\nSet `included_in_price` for VAT-style pricing, where the rate is backed\nout of the displayed price rather than added to it.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"tax rate created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRate"}}}},"422":{"description":"validation failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRateParams"}}},"required":true}}},"/api/v3/admin/tax_rates/{id}":{"parameters":[{"name":"id","in":"path","description":"Tax rate ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a tax rate","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"tax rate found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRate"}}}}}},"patch":{"summary":"Update a tax rate","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"tax rate updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRate"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRateParams"}}},"required":true}},"delete":{"summary":"Delete a tax rate","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the rate. Tax lines it already produced keep their own rate snapshot.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"tax rate deleted"}}}},"/api/v3/admin/translatable_resources":{"get":{"summary":"List translatable resources","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every translatable resource type and its translatable fields (key + content type), so clients can render translation editors generically.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"translatable resources found","content":{"application/json":{}}}}}},"/api/v3/admin/translations/batch":{"post":{"summary":"Batch upsert translations","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Atomically upserts translations across many records of (possibly) different translatable resource types in one request — e.g. an option type and all its option values in one save. A flat list of independent registry writes; all entries succeed or none do.\n\n**Required scope:** `write_<resource>` for every resource type in the batch (for API-key authentication) (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"translations upserted","content":{"application/json":{}}},"422":{"description":"unsupported locale rolls back the whole batch","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslationBatchParams"}}},"required":true}}},"/api/v3/admin/admin_users":{"get":{"summary":"List staff","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns admin users with at least one role assignment on the current store.\n\n**Required scope:** `read_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[email_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `first_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `last_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[spree_roles_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `email`, `first_name`, `id`, `last_name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"AdminUser","sortable":["created_at","email","first_name","id","last_name","updated_at"]},"responses":{"200":{"description":"staff found","content":{"application/json":{}}}}}},"/api/v3/admin/admin_users/{id}":{"get":{"summary":"Show a staff member","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"staff member found","content":{"application/json":{}}}}},"patch":{"summary":"Update a staff member","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates name fields and reassigns roles for the current store. `role_ids` is a complete replacement — roles not in the array are removed for this store.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"staff member updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUserUpdateParams"}}},"required":true}},"delete":{"summary":"Remove a staff member from this store","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes the user's role assignments on the current store. The account is preserved — the user keeps access to any other stores. Removing a role needs the same rights as granting it, and the store always keeps at least one admin.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"staff removed from store"}}}},"/api/v3/admin/invitations":{"get":{"summary":"List invitations","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns invitations for the current store, including pending and accepted.\n\n**Required scope:** `read_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Invitation","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"invitations found","content":{"application/json":{}}}}},"post":{"summary":"Create an invitation","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Invites a teammate by email. The invitation is scoped to the current store and carries the chosen role; on accept, a `RoleUser` is created via the invitation's `after_accept` callback.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"invitation created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationCreateParams"}}},"required":true}}},"/api/v3/admin/invitations/{id}":{"delete":{"summary":"Revoke an invitation","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"invitation revoked"}}}},"/api/v3/admin/invitations/{invitation_id}/acceptance_link":{"get":{"summary":"Get an invitation acceptance link","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the link the invitee opens to accept a pending invitation. The link carries the invitation token, so it needs write access to staff and the right to grant the invitation's role; invitation listings never include it.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"invitation_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"acceptance link found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationAcceptanceLink"}}}}}}},"/api/v3/admin/invitations/{id}/resend":{"patch":{"summary":"Resend an invitation","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Issues a fresh token and dispatches the invitation email again.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"invitation resent","content":{"application/json":{}}}}}},"/api/v3/admin/permissions":{"get":{"summary":"List the permission catalog","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the permission catalog — the grant vocabulary shared by staff role permissions and secret API key scopes. Entries are grouped for permission pickers; labels and descriptions are localized. Readable by any authenticated admin credential.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"catalog returned","content":{"application/json":{}}}}}},"/api/v3/admin/roles":{"get":{"summary":"List roles","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns staff roles with their catalog permissions. Roles are global, not per-store; `mutable: false` marks the protected admin role and host-locked rows.\n\n**Required scope:** `read_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Role","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"roles found","content":{"application/json":{}}}}},"post":{"summary":"Create a role","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a staff role. `permissions` holds catalog keys (see GET /admin/permissions); a caller may only grant keys they effectively hold.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"role created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleCreateParams"}}},"required":true}}},"/api/v3/admin/roles/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a role","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a role name, description or permissions. The admin role and host-locked roles (`mutable: false`) reject changes.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"role updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a role","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a role. Fails with 422 while the role is protected or still referenced by staff members or pending invitations.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"role deleted"},"422":{"description":"role cannot be deleted","content":{"application/json":{}}}}}},"/api/v3/admin/stock_locations":{"get":{"summary":"List stock locations","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the configured stock locations. Stock locations are global\n(shared across stores). Filter with Ransack predicates such as\n`q[active_eq]`, `q[kind_eq]`, `q[pickup_enabled_eq]`, or\n`q[name_cont]`.\n\nPickup-related attributes (`kind`, `pickup_enabled`,\n`pickup_stock_policy`, `pickup_ready_in_minutes`,\n`pickup_instructions`) drive merchant pickup support at checkout —\ncustomers can collect orders from any active location with\n`pickup_enabled: true`.\n\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `default` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `pickup_enabled` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `returns_enabled` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockLocation","sortable":["active","country_code","created_at","default","id","kind","name","pickup_enabled","returns_enabled","seller_id","state_code","updated_at"]},"responses":{"200":{"description":"stock locations found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockLocation"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a stock location","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new stock location.\n\nSetting `default: true` automatically demotes the previous default\nlocation.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"stock location created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocation"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocationCreateParams"}}},"required":true}}},"/api/v3/admin/stock_locations/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock location ID","schema":{"type":"string"}}],"get":{"summary":"Get a stock location","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single stock location by prefixed ID.\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"stock location found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocation"}}}},"404":{"description":"stock location not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a stock location","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an existing stock location. Same address-field conventions as\nthe create endpoint.\n\nSetting `default: true` automatically demotes the previous default.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"stock location updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocation"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocationUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a stock location","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the stock location (sets `deleted_at`). Existing\nfulfillments that referenced it keep the historical record via\n`Spree::StockLocation.with_deleted`.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"stock location deleted"}}}},"/api/v3/admin/store_credits":{"get":{"summary":"List store credits","tags":["Store Credits"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every store credit in the current store, across all customers.\nRead-only: issuing, editing and deleting a credit stays nested under\nthe customer that holds it.\n\n`meta.totals` carries the outstanding balance as one row per currency,\nsummed over the same filter this request used — so filtering by a\ncustomer answers that customer's balance and no filter answers the\nstore's liability.\n\n\n**Required scope:** `read_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of memo (partial, case-insensitive)."},{"name":"q[from_gift_card]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `from_gift_card`."},{"name":"q[outstanding]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `outstanding`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (customer, created_by).","schema":{"type":"string"}},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `customer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `memo` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[created_by_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `created_by_` | `created_at`, `email`, `first_name`, `id`, `last_name`, `updated_at` |\n| `created_by_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customer_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `customer_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `created_by_id`, `currency`, `customer_id`, `id`, `memo`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StoreCredit","sortable":["amount","created_at","created_by_id","currency","customer_id","id","memo","updated_at"]},"responses":{"200":{"description":"store credits found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StoreCredit"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/store_credits/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Retrieve a store credit","tags":["Store Credits"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (customer, created_by).","schema":{"type":"string"}}],"responses":{"200":{"description":"store credit found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoreCredit"}}}},"404":{"description":"not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/store_credits/{store_credit_id}/events":{"parameters":[{"name":"store_credit_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List a store credit's ledger","tags":["Store Credits"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every movement of the credit's balance, newest first: allocated when\nissued, authorized when a checkout starts against it, captured when\nthat order is paid, and voided or credited back if it is cancelled.\n\n\n**Required scope:** `read_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StoreCreditEvent","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"events found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StoreCreditEvent"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/variants/{variant_id}/custom_fields":{"get":{"summary":"List variant custom fields","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the variant's custom field values.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"variant_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/products/{product_id}/variants":{"get":{"summary":"List product variants","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of variants for a product, including the default variant.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches SKU, option value or product name (partial, case-insensitive; at least three characters)."},{"name":"q[available_at_stock_location]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `available_at_stock_location` to the given value."},{"name":"q[product_name_or_sku_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `product_name_or_sku_cont` to the given value."},{"name":"q[search_by_product_name_or_sku]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_product_name_or_sku` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., images, prices, stock_levels, option_values). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., sku,price,stock). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[cost_currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carton_package_type_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `carton_weight` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cartons_per_pallet` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cost_currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `cost_price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `country_of_origin` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `deleted_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `depth` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `height` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `hs_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `minimum_order_quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `order_multiple` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `product_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `purchase_unit` | One of `unit`, `carton` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `sku` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `track_inventory` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `units_per_carton` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `weight` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `width` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[option_values_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `prices_price_list_` | `catalog_id`, `created_at`, `ends_at`, `id`, `match_policy`, `name`, `position`, `starts_at`, `status`, `updated_at` |\n| `product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `product_categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `product_channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `product_collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `product_labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `product_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Variant","sortable":["carton_package_type_id","carton_weight","cartons_per_pallet","cost_currency","cost_price","country_of_origin","created_at","deleted_at","depth","discontinue_on","height","hs_code","id","minimum_order_quantity","order_multiple","position","product_id","purchase_unit","sku","track_inventory","units_per_carton","updated_at","weight","width"]},"responses":{"200":{"description":"variants found","content":{"application/json":{}}}}},"post":{"summary":"Create a variant","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new variant for a product. Supports nested prices and stock items.\n\nOption types and values are auto-created if they don't exist.\nPrices are upserted by currency. Stock items are upserted by stock location.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"201":{"description":"variant created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariantCreateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/variants/{id}":{"get":{"summary":"Get a variant","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single variant by ID.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Variant ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., images, prices, stock_levels, option_values). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., sku,price,stock). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"variant found","content":{"application/json":{}}},"404":{"description":"variant not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a variant","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a variant. Only provided fields are updated.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Variant ID","schema":{"type":"string"}}],"responses":{"200":{"description":"variant updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariantUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a variant","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes a variant.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Variant ID","schema":{"type":"string"}}],"responses":{"204":{"description":"variant deleted"}}}},"/api/v3/admin/variants":{"get":{"summary":"List variants","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every variant in the store across all products, for pickers and stock views that are not tied to one product.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches SKU, option value or product name (partial, case-insensitive; at least three characters)."},{"name":"q[available_at_stock_location]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `available_at_stock_location` to the given value."},{"name":"q[product_name_or_sku_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `product_name_or_sku_cont` to the given value."},{"name":"q[search_by_product_name_or_sku]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_product_name_or_sku` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[cost_currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carton_package_type_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `carton_weight` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cartons_per_pallet` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cost_currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `cost_price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `country_of_origin` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `deleted_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `depth` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `height` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `hs_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `minimum_order_quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `order_multiple` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `product_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `purchase_unit` | One of `unit`, `carton` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `sku` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `track_inventory` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `units_per_carton` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `weight` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `width` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[option_values_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `prices_price_list_` | `catalog_id`, `created_at`, `ends_at`, `id`, `match_policy`, `name`, `position`, `starts_at`, `status`, `updated_at` |\n| `product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `product_categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `product_channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `product_collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `product_labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `product_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Variant","sortable":["carton_package_type_id","carton_weight","cartons_per_pallet","cost_currency","cost_price","country_of_origin","created_at","deleted_at","depth","discontinue_on","height","hs_code","id","minimum_order_quantity","order_multiple","position","product_id","purchase_unit","sku","track_inventory","units_per_carton","updated_at","weight","width"]},"responses":{"200":{"description":"variants found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Variant"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/webhook_endpoints/{webhook_endpoint_id}/deliveries":{"parameters":[{"name":"webhook_endpoint_id","in":"path","required":true,"description":"Parent webhook endpoint ID","schema":{"type":"string"}}],"get":{"summary":"List webhook deliveries","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns delivery attempts for the given endpoint, most recent first.\nEach row carries the original request payload, the response code\n(when the receiver replied), the execution time, and any transport\nerror — everything needed to audit failures and decide whether to\nredeliver.\n\n\n**Required scope:** `read_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of event name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-delivered_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[event_name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `delivered_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `event_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `execution_time` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `response_code` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `success` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `delivered_at`, `event_name`, `execution_time`, `id`, `response_code`, `success`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"WebhookDelivery","sortable":["created_at","delivered_at","event_name","execution_time","id","response_code","success","updated_at"]},"responses":{"200":{"description":"deliveries found","content":{"application/json":{}}},"404":{"description":"parent webhook endpoint not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/webhook_endpoints/{webhook_endpoint_id}/deliveries/{id}":{"parameters":[{"name":"webhook_endpoint_id","in":"path","required":true,"description":"Parent webhook endpoint ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook delivery ID","schema":{"type":"string"}}],"get":{"summary":"Get a webhook delivery","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single delivery attempt with the full request payload and\nthe response body the receiver returned. Use this for ad-hoc debug\nof failed deliveries.\n\n\n**Required scope:** `read_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"delivery found","content":{"application/json":{}}},"404":{"description":"delivery not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/webhook_endpoints/{webhook_endpoint_id}/deliveries/{id}/redeliver":{"parameters":[{"name":"webhook_endpoint_id","in":"path","required":true,"description":"Parent webhook endpoint ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook delivery ID to redeliver","schema":{"type":"string"}}],"post":{"summary":"Redeliver a webhook delivery","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new delivery row with the same payload + event_name and\nqueues it. The original row is preserved for audit history.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"redelivery queued","content":{"application/json":{}}}}}},"/api/v3/admin/webhook_endpoints":{"get":{"summary":"List webhook endpoints","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns outbound webhook subscriptions for the current store. Each\nendpoint receives a signed POST when any subscribed event fires.\n`secret_key` is `null` on list reads — the plaintext is delivered\nexactly once on create.\n\n\n**Required scope:** `read_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of url (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `url` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`, `url`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"WebhookEndpoint","sortable":["active","created_at","id","name","updated_at","url"]},"responses":{"200":{"description":"webhook endpoints found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new outbound webhook subscription. The plaintext\n`secret_key` is returned **once** in this response — persist it\nimmediately to verify incoming webhook signatures. Subsequent reads\nreturn `null` for the secret. Pass an empty `subscriptions` array or\nomit it to receive every event.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"webhook endpoint created — secret_key returned once","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointCreateParams"}}},"required":true}}},"/api/v3/admin/webhook_endpoints/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Webhook endpoint ID","schema":{"type":"string"}}],"get":{"summary":"Get a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single webhook endpoint by prefixed ID.\n\n**Required scope:** `read_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"webhook endpoint found","content":{"application/json":{}}},"404":{"description":"webhook endpoint not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates name, URL, active flag, or the event subscription list.\nToggling `active` here is equivalent to calling `disable`/`enable`\nwithout an audit reason.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"webhook endpoint updated","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the endpoint and stops future deliveries.\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"webhook endpoint deleted"}}}},"/api/v3/admin/webhook_endpoints/{id}/send_test":{"parameters":[{"name":"id","in":"path","required":true,"description":"Webhook endpoint ID","schema":{"type":"string"}}],"post":{"summary":"Send a test delivery","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a `webhook.test` delivery record and queues it. Use this to\nverify the endpoint is reachable and your signature verification\naccepts Spree's payloads.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"test delivery queued","content":{"application/json":{}}}}}},"/api/v3/admin/webhook_endpoints/{id}/enable":{"parameters":[{"name":"id","in":"path","required":true,"description":"Webhook endpoint ID","schema":{"type":"string"}}],"patch":{"summary":"Re-enable a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Re-enables an endpoint that was manually or automatically disabled.\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"webhook endpoint enabled","content":{"application/json":{}}}}}},"/api/v3/admin/webhook_endpoints/{id}/disable":{"parameters":[{"name":"id","in":"path","required":true,"description":"Webhook endpoint ID","schema":{"type":"string"}}],"patch":{"summary":"Disable a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Manually pauses an endpoint. Unlike auto-disable (triggered after\nrepeated delivery failures), no notification email is sent.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"webhook endpoint disabled","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointDisableParams"}}},"required":true}}},"/api/v3/admin/webhook_events":{"get":{"summary":"List webhook events","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every event a webhook endpoint can subscribe to, including those installed extensions declare. Credential events reach only endpoints that name them, and subscribing to one needs the permission listed; deprecated events name their replacement.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"events returned","content":{"application/json":{}}}}}},"/api/v3/admin/catalogs":{"get":{"summary":"List catalogs","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store catalogs — product assortments with an optional price list, shown to audiences through assignments.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Catalog","sortable":["active","created_at","id","name","position","updated_at"]},"responses":{"200":{"description":"catalogs found","content":{"application/json":{}}}}},"post":{"summary":"Create a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a catalog. Add products and assign audiences (customer group, or company subtree) afterwards.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"catalog created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogParams"}}},"required":true}}},"/api/v3/admin/catalogs/{id}/assign":{"post":{"summary":"Assign a catalog to an audience","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Shows the catalog to an audience. A company assignment covers the node and its whole subtree.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"catalog assigned","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogAssignParams"}}},"required":true}}},"/api/v3/admin/catalogs/{catalog_id}/products":{"get":{"summary":"List catalog products","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The catalog's curated assortment, listed by product name — membership\ncarries no order.\n\n`expand=catalog_price` adds what a buyer on this agreement pays for\neach row and where the amount comes from: `explicit` (an amount\nentered on the catalog's own price list), `automatic` (that list's\npercentage applied to the shop price) or `base` (the shop price\nitself — this agreement does not price the product).\n\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"expand","in":"query","required":false,"description":"Comma-separated. `catalog_price` adds the resolved price to every row.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","created_at","description","discontinue_on","id","name","price","seller_id","slug","status","updated_at"]},"responses":{"200":{"description":"products found, with what the agreement charges","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CatalogProduct"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Add products to a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Curates products into the assortment in bulk. Already-present products are skipped; the count reports what was added.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"products added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}},"delete":{"summary":"Remove products from a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes products from the assortment in bulk. Ids that are not members are ignored; the count reports what was removed.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}}},"/api/v3/admin/catalogs/{catalog_id}/order_minimums":{"get":{"summary":"List catalog order minimums","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The least a whole order must come to under this agreement. One row per currency — Spree holds no exchange rates, so a threshold is never stated once and converted.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CatalogOrderMinimum","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"order minimums found","content":{"application/json":{}}}}},"post":{"summary":"Create a catalog order minimum","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Requires orders in one currency to reach an amount. The buyer sees the shortfall on the cart while they can still act on it; completion is refused below it.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"order minimum created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogOrderMinimumParams"}}},"required":true}}},"/api/v3/admin/catalogs/{catalog_id}/order_minimums/{id}":{"patch":{"summary":"Update a catalog order minimum","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Restates one currency's threshold.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"order minimum updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogOrderMinimumParams"}}},"required":true}},"delete":{"summary":"Delete a catalog order minimum","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Lifts the threshold for one currency, so orders in it may come to any total.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"order minimum deleted"}}}},"/api/v3/admin/catalogs/{catalog_id}/quantity_rules":{"put":{"summary":"Set catalog quantity rules","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Writes the given products' quantity terms in one request, keyed by prefixed product id. The stated pair is written to every variant of the product, which is the grain the database keeps them at. Both fields null clears that product's terms; a product not yet in the assortment is added, since a term with nothing to apply to is not a reachable state. Products absent from the payload are left alone — an agreement may name terms for thousands of SKUs. Read them back on the assortment rows: `GET /catalogs/{id}/products?expand=quantity_rule`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"quantity rules set"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogProductTermsParams"}}},"required":true}}},"/api/v3/admin/catalogs/{id}/activate":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Activate a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Puts the agreement into effect: its audience starts seeing its\nassortment and paying its prices. Refused for a catalog nobody is\nassigned to, since activating it would reach no buyer — a channel's\ndefault catalog is reached through the channel instead, so it needs\nno assignment.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"catalog activated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Catalog"}}}}}}},"/api/v3/admin/catalogs/{id}/deactivate":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Deactivate a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Takes the agreement out of effect. Everything it holds — assignments,\ncommercial terms, its price list — survives, so activating again\nresumes exactly what was there.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"catalog deactivated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Catalog"}}}}}}},"/api/v3/admin/collections":{"get":{"summary":"List collections","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of the store's collections.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., rules, custom_fields, translations).","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `automatic` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `permalink` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `products_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `sort_order` | One of `manual`, `best_selling`, `price asc`, `price desc`, `available_on desc`, `available_on asc`, `name asc`, `name desc` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Collection","sortable":["automatic","created_at","id","name","permalink","position","products_count","sort_order","updated_at"]},"responses":{"200":{"description":"collections found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Collection"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a manual or automatic (rule-based) collection. For automatic collections, send the full desired rule set under `rules`.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"collection created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Collection"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionCreateParams"}}},"required":true}}},"/api/v3/admin/collections/{id}":{"get":{"summary":"Get a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single collection by ID, including its rules.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., rules, custom_fields, translations).","schema":{"type":"string"}}],"responses":{"200":{"description":"collection found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Collection"}}}},"404":{"description":"collection not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a collection. Send `position` to reorder it within the flat list; send the full `rules` set to sync automatic rules.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}}],"responses":{"200":{"description":"collection updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Collection"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a collection.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}}],"responses":{"204":{"description":"collection deleted"}}}},"/api/v3/admin/collections/{collection_id}/products":{"get":{"summary":"List collection products","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Products curated in the collection, ordered by their membership position.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","created_at","description","discontinue_on","id","name","price","seller_id","slug","status","updated_at"]},"responses":{"200":{"description":"products found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Add products to a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Curates products into the collection in bulk (appended to the end). Already-curated products are skipped; the count reports what was added.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}}],"responses":{"201":{"description":"products added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}},"delete":{"summary":"Remove products from a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes products from the collection's manual curation in bulk. Ids that are not curated are ignored; the count reports what was removed.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}}],"responses":{"200":{"description":"products removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}}},"/api/v3/admin/collections/{collection_id}/products/{id}/reposition":{"patch":{"summary":"Reposition a collection product","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Moves a product to a new index among the collection's products.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"204":{"description":"product repositioned"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipRepositionParams"}}},"required":true}}},"/api/v3/admin/collection_rules/types":{"get":{"summary":"List available collection rule types","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Enumerates the registered rule kinds with their labels and descriptions — drives the rule picker on an automatic collection. Plugins extend the list by registering `Spree::CollectionRule` subclasses via `config.spree.collection_rules`. The `type` returned here is the wire shorthand accepted when writing a collection's `rules`.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"types found","content":{"application/json":{}}}}}},"/api/v3/admin/commission_lines":{"get":{"summary":"List commission lines","tags":["Commission Lines"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"What each sale actually earned the marketplace, frozen when the order\nwas placed. A later change to a commission rate never reaches these.\n\n`amount` is the fee charged to the seller and `tax_amount` is the VAT on\nthat fee — the marketplace's own service to the seller, a supply\nseparate from the sale itself, which is why the two are not folded\ntogether. `total` is their sum.\n\nOne line per commissioned item, plus one per delivery when the rate that\napplied charges shipping too — read `line_item_id` and `fulfillment_id`\nto tell them apart.\n\nRead-only: correcting a charge is a reversal, not an edit.\n\n\n**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed (e.g., `commission_rate`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `percentage`, `fixed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `rate` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `tax_amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[commission_rate_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `commission_rate_` | `code`, `created_at`, `enabled`, `id`, `include_shipping`, `kind`, `name`, `position`, `tax_inclusive`, `updated_at`, `value` |\n| `commission_rate_commission_rules_` | `created_at`, `id`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `currency`, `id`, `kind`, `order_id`, `rate`, `tax_amount`, `total`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CommissionLine","sortable":["amount","created_at","currency","id","kind","order_id","rate","tax_amount","total","updated_at"]},"responses":{"200":{"description":"commission lines found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CommissionLine"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/commission_lines/{id}":{"parameters":[{"name":"id","in":"path","description":"Commission line ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a commission line","tags":["Commission Lines"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"commission line found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionLine"}}}},"404":{"description":"commission line not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/commission_rates":{"get":{"summary":"List commission rates","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"What the marketplace charges its sellers.\n\nRates are returned in resolution order: the list is walked top-down and\nthe first rate whose targeting matches the sale wins, so the order you\nsee is the precedence. Move a rate with `position` on update.\n\nA rate carrying no rules matches every sale — `global` says so — which\nis how a marketplace expresses a single default. Because resolution\nstops at the first match, a global rate makes everything below it\nunreachable, so it belongs at the bottom.\n\n\n**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-position`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `enabled` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `include_shipping` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `kind` | One of `percentage`, `fixed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `tax_inclusive` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `value` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[commission_rules_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `commission_rules_` | `created_at`, `id`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `code`, `created_at`, `enabled`, `id`, `include_shipping`, `kind`, `name`, `position`, `tax_inclusive`, `updated_at`, `value`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CommissionRate","sortable":["code","created_at","enabled","id","include_shipping","kind","name","position","tax_inclusive","updated_at","value"]},"responses":{"200":{"description":"commission rates found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CommissionRate"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a commission rate","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sets what the marketplace charges, and which sales it applies to.\n\n`rules` is the rate's whole targeting, sent inline. Every rule has to\nhold, and a rule naming several records means any of them — so\n\"(Cameras OR Audio) AND that seller\" is a category rule holding two ids\nbeside a seller rule holding one. Send no rules to charge every sale.\n\nRule kinds come from `GET /commission_rates/rule_types`, which also\ndescribes the configuration each one takes. A marketplace that adds its\nown kind sees it there without this endpoint changing.\n\n`commission_tax_rate` is VAT on the commission itself — the\nmarketplace's own service to the seller, a separate supply from the\nsale. Leave it null to let the store's tax engine answer for wherever\nthe seller's business sits.\n\n\n**Required scope:** `write_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"commission rate created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRate"}}}},"422":{"description":"validation failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRateCreateParams"}}},"required":true}}},"/api/v3/admin/commission_rates/rule_types":{"get":{"summary":"List the commission rule kinds","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every rule kind a rate can be narrowed by, with the schema describing\nthe configuration it takes — so a client builds its editor from what\nthis marketplace has rather than a list hardcoded to match core's.\n\n`association_fields` names any catalog-scale reference a kind keeps\noutside its preferences, so an editor knows to render a picker for it.\n\n\n**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"subject types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"schema":{"type":"object","description":"JSON Schema of the type's `preferences`"},"association_fields":{"type":"array","items":{"type":"string"}}}}}}}}}}}}},"/api/v3/admin/commission_rates/{id}":{"parameters":[{"name":"id","in":"path","description":"Commission rate ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a commission rate","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"commission rate found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRate"}}}},"404":{"description":"commission rate not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a commission rate","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Editing a rate changes what the next sale is charged, never what a past\none was: commission lines keep their own snapshot of the rate that\napplied.\n\n\n**Required scope:** `write_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"commission rate updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRate"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRateUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a commission rate","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"commission rate deleted"}}}},"/api/v3/admin/companies/{company_id}/addresses":{"get":{"summary":"List company addresses","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the business's addresses: its sites, billing address and delivery points.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[address1_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `address1` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `address2` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `city` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `company` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `first_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `last_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `phone` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `postal_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Address","sortable":["address1","address2","city","company","country_code","created_at","first_name","id","last_name","phone","postal_code","state_code","updated_at"]},"responses":{"200":{"description":"addresses found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Address"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a company address","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds an address to the business. Pass `default_billing: true` or `default_shipping: true` to make it the default of that kind.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"address created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Address"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyAddressParams"}}},"required":true}}},"/api/v3/admin/companies/{company_id}/invitations":{"get":{"summary":"List company invitations","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the invitations into this business that are still waiting to be accepted.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[email_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `email`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CompanyInvitation","sortable":["created_at","email","id","updated_at"]},"responses":{"200":{"description":"invitations found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CompanyInvitation"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/companies/{company_id}/memberships":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List company members","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the people with standing over this node. Standing covers the node and everything below it in the tree.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CompanyMembership","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"members found","content":{"application/json":{}}}}},"post":{"summary":"Add a member by email","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a person to the node by email. An email matching an existing customer becomes a\nmembership immediately (a `cmem_…` id); an unknown email becomes an invitation\n(a `cinv_…` id) and the invite email goes out.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[],"responses":{"201":{"description":"member added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyMembershipCreateParams"}}},"required":true}}},"/api/v3/admin/companies/{company_id}/tax_exemption_certificates":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List tax exemption certificates","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a business's exemption evidence. `active` is the field that decides whether a certificate\nexempts a sale: a verified certificate stops counting once its expiry date passes, so the status\nalone does not answer it.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[certificate_number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `certificate_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `expires_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `reason_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `pending`, `verified`, `expired`, `revoked` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `certificate_number`, `created_at`, `expires_at`, `id`, `reason_code`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxExemptionCertificate","sortable":["certificate_number","created_at","expires_at","id","reason_code","status","updated_at"]},"responses":{"200":{"description":"certificates found","content":{"application/json":{}}}}},"post":{"summary":"Create a tax exemption certificate","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records exemption evidence against a business. Certificates start `pending` and exempt nothing\nuntil verified.\n\n`country_code` and `state_code` say where the certificate holds — omit both for one valid\neverywhere, give only the country for one valid throughout it. `document_signed_id` takes the\n`signed_id` returned by `POST /api/v3/admin/files`.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[],"responses":{"201":{"description":"certificate created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxExemptionCertificateParams"}}},"required":true}}},"/api/v3/admin/companies/{company_id}/tax_exemption_certificates/{id}/verify":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Verify a tax exemption certificate","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Accepts the certificate as evidence, which is what makes it exempt sales. Only a pending\ncertificate can be accepted — re-accepting a revoked one would restore evidence that was\ndeliberately withdrawn. An installation that checks numbers against a registry, or requires a\nsecond approval, can refuse here, and the refusal is returned as a validation error.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","responses":{"200":{"description":"certificate verified","content":{"application/json":{}}}}}},"/api/v3/admin/companies/{company_id}/tax_exemption_certificates/{id}/revoke":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Revoke a tax exemption certificate","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Withdraws accepted evidence. A verified certificate cannot be deleted — how a sale was taxed has to remain explainable — so revoking is the way out.\n\n**Required scope:** `write_customers` (for API-key authentication).","responses":{"200":{"description":"certificate revoked","content":{"application/json":{}}}}}},"/api/v3/admin/companies/{company_id}/tax_exemption_certificates/{id}/download":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Download a certificate document","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Streams the uploaded document. Deliberately not a storage link: the bytes come through the API so\nthe same credentials apply to every read of a confidential document. Requires only read access.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","responses":{"200":{"description":"document streamed","content":{"application/json":{}}},"422":{"description":"no document attached","content":{"application/json":{}}}}}},"/api/v3/admin/companies/{company_id}/tax_identifiers":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List company tax registrations","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the business's tax registrations, one per kind. A business registration takes precedence\nover the buyer's own when a sale is for that business, because the invoice is addressed to the\nentity rather than the person who placed the order.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxIdentifier","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"registrations found","content":{"application/json":{}}}}},"post":{"summary":"Create a company tax registration","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Registers a tax number against the business. Verification against the relevant registry runs in\nthe background where a validator is installed for the kind; a stock installation registers none,\nleaving the status unattempted.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[],"responses":{"201":{"description":"registration created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxIdentifierParams"}}},"required":true}}},"/api/v3/admin/companies/{company_id}/tax_identifiers/{id}/validate":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"post":{"summary":"Re-check a company tax registration","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Asks the registry again. Manual because a registry answers only \"valid now\" — a number verified\nlast year may have been deregistered since — and because a check that came back unavailable\ncannot otherwise be retried without editing the number.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","responses":{"422":{"description":"no validator installed for this kind","content":{"application/json":{}}}}}},"/api/v3/admin/companies":{"get":{"summary":"List companies","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the business customers of the current store.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `company`, `division` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `parent_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `po_number_required` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[children_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `children_` | `created_at`, `id`, `kind`, `name`, `parent_id`, `po_number_required`, `updated_at` |\n| `children_external_references_` | `created_at`, `external_id`, `id`, `resource_type`, `system`, `updated_at` |\n| `children_memberships_` | `created_at`, `id`, `updated_at` |\n| `external_references_` | `created_at`, `external_id`, `id`, `resource_type`, `system`, `updated_at` |\n| `memberships_` | `created_at`, `id`, `updated_at` |\n| `parent_` | `created_at`, `id`, `kind`, `name`, `parent_id`, `po_number_required`, `updated_at` |\n| `parent_external_references_` | `created_at`, `external_id`, `id`, `resource_type`, `system`, `updated_at` |\n| `parent_memberships_` | `created_at`, `id`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `kind`, `name`, `parent_id`, `po_number_required`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Company","sortable":["created_at","id","kind","name","parent_id","po_number_required","updated_at"]},"responses":{"200":{"description":"companies found","content":{"application/json":{}}}}},"post":{"summary":"Create a company","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a company node. A root node is a legal entity; pass parent_id and kind to build the organization tree. Exemption certificates and tax registrations hang off legal-entity nodes.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"company created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyParams"}}},"required":true}}},"/api/v3/admin/custom_field_definitions/resource_types":{"get":{"summary":"List what custom fields can be attached to","tags":["Custom Field Definitions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The resources a definition can describe, from the server's own\nregistry (`Spree.custom_fields.enabled_resources`).\n\nRead this rather than carrying a list: a resource an extension\nregisters appears here without a client release, and a `resource_type`\nthat is not listed is refused on create.\n\n`resource_type` is the value to send; `name` is what a merchant calls\nit — send the value back verbatim rather than deriving it from the name.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"resource types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"resource_type":{"type":"string"},"name":{"type":"string"}}}}}}}}}}}},"/api/v3/admin/collections/{collection_id}/custom_fields":{"get":{"summary":"List collection custom fields","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the collection's custom field values.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/sellers/{seller_id}/custom_fields":{"get":{"summary":"List seller custom fields","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the seller's custom field values.\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"seller_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/delivery_profiles":{"get":{"summary":"List delivery profiles","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Fulfillment profiles group products with the stock locations, delivery zones and delivery methods that fulfill them. Every store has exactly one default profile.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryProfile","sortable":["created_at","id","name","position","updated_at"]},"responses":{"200":{"description":"delivery profiles found","content":{"application/json":{}}}}},"post":{"summary":"Create a delivery profile","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a delivery profile. `kind` selects the registered profile kind (shipping, digital, extension kinds); `stock_location_ids` limits fulfillment to those locations — empty means every store location.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"delivery profile created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryProfileParams"}}},"required":true}}},"/api/v3/admin/delivery_profiles/{delivery_profile_id}/origin_groups":{"parameters":[{"name":"delivery_profile_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List origin groups","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the profile's origin groups: the sets of warehouses that each quote their own delivery rates.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryOriginGroup","sortable":["created_at","id","name","position","updated_at"]},"responses":{"200":{"description":"origin groups found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryOriginGroup"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create an origin group","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Origin groups partition a profile's fulfillment origins: zones and methods belong to a group, so the same products can quote different rate tables per warehouse. `stock_location_ids` replaces the full membership; empty means every store location.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"origin group created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryOriginGroupParams"}}},"required":true}}},"/api/v3/admin/delivery_profiles/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a delivery profile","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"delivery profile updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryProfileParams"}}},"required":true}},"delete":{"summary":"Delete a delivery profile","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The default profile and profiles still referenced by products cannot be deleted.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"delivery profile deleted"}}}},"/api/v3/admin/delivery_methods":{"get":{"summary":"List delivery methods","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all delivery methods with calculator and zone configuration.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_to_sellers` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `storefront_visible` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_to_sellers`, `created_at`, `id`, `name`, `seller_id`, `storefront_visible`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryMethod","sortable":["available_to_sellers","created_at","id","name","seller_id","storefront_visible","updated_at"]},"responses":{"200":{"description":"delivery methods found","content":{"application/json":{}}}}},"post":{"summary":"Create delivery method","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a delivery method inside a delivery profile (defaults to the store default profile). Delivery behavior comes from the fulfillment provider.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"delivery method created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodParams"}}},"required":true}}},"/api/v3/admin/delivery_methods/calculators":{"get":{"summary":"List delivery calculators","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Registered delivery calculator classes with preference schemas for building configuration forms.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"calculators found","content":{"application/json":{}}}}}},"/api/v3/admin/delivery_zones":{"get":{"summary":"List delivery zones","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the areas delivery methods ship to, each made of countries, states or postal code ranges.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `delivery_profile_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `delivery_profile_id`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryZone","sortable":["created_at","delivery_profile_id","id","name","updated_at"]},"responses":{"200":{"description":"delivery zones found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryZone"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create delivery zone","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a delivery zone with typed members: country, state, or postal_code (prefix or from/to range).\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed, e.g. `members`","schema":{"type":"string"}}],"responses":{"201":{"description":"delivery zone created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryZoneParams"}}},"required":true}}},"/api/v3/admin/delivery_methods/{delivery_method_id}/rules":{"get":{"summary":"List delivery method rules","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the conditions a delivery method must meet to be offered at checkout, such as an order total or weight range.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"delivery_method_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryMethodRule","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"rules found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryMethodRule"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a delivery method rule","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a condition to a delivery method. `type` is a rule kind from the\ndelivery method rule types endpoint, and `preferences` takes the\nvalues its schema declares.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"delivery_method_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"rule created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodRule"}}}},"422":{"description":"unknown rule type","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodRuleCreateParams"}}},"required":true}}},"/api/v3/admin/delivery_methods/{delivery_method_id}/rules/{id}":{"patch":{"summary":"Update a delivery method rule","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes a rule's settings or turns it off. Its `type` is fixed once created.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"delivery_method_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rule updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodRule"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodRuleUpdateParams"}}},"required":true}}},"/api/v3/admin/integrations":{"get":{"summary":"List integrations","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the integrations connected to the current store. Secret preference values are masked.\n\n**Required scope:** `read_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Integration","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"integrations found","content":{"application/json":{}}}}},"post":{"summary":"Connect integration","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Connects an integration type to the current store. Setting active: true verifies the connection and fails with 422 when it cannot connect. Submitting a masked secret value back keeps the stored secret.\n\n**Required scope:** `write_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"integration connected","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationCreateParams"}}},"required":true}}},"/api/v3/admin/integrations/types":{"get":{"summary":"List integration types","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every registered integration type with its gallery metadata and configuration schema. Pure registry discovery — read live connection state from GET /integrations.\n\n**Required scope:** `read_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"integration types found","content":{"application/json":{}}}}}},"/api/v3/admin/integrations/{id}":{"patch":{"summary":"Update integration","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes an integration's credentials or turns it on or off. Setting active: true verifies the connection and fails with 422 when it cannot connect. Submitting a masked secret value back keeps the stored secret.\n\n**Required scope:** `write_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"integration updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationUpdateParams"}}},"required":true}}},"/api/v3/admin/integrations/{id}/test":{"post":{"summary":"Test integration connection","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Runs a live connection check against the provider. Nothing is persisted; a failed check reports the seller error message.\n\n**Required scope:** `write_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"connection checked","content":{"application/json":{}}}}}},"/api/v3/admin/media":{"get":{"summary":"List media","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every file in the store's media library, whether or not it has\nbeen placed on a product. Filter with `q[unattached]=true` for files not\nyet in use, `q[media_type_eq]` for images or video, and\n`q[filename_cont]` to search by file name.\n\n\n**Required scope:** `read_media` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[attached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `attached`."},{"name":"q[filename_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `filename_cont` to the given value."},{"name":"q[unattached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `unattached`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[alt_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `alt` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `media_type` | One of `image`, `video`, `external_video` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `alt`, `created_at`, `id`, `media_type`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Media","sortable":["alt","created_at","id","media_type","position","updated_at"]},"responses":{"200":{"description":"media found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Upload a file to the library","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a file to the library without placing it on anything. Upload the\nfile first through `POST /api/v3/admin/files`, then send the signed id\nhere. Put the file on a product by posting to that product's media with\nthis record's id as `source_media_id`.\n\n\n**Required scope:** `write_media` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"file added","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Media"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaLibraryCreateParams"}}},"required":true}}},"/api/v3/admin/media/{id}":{"parameters":[{"name":"id","in":"path","description":"Media ID","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a library file","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits a file in the library, such as its alt text.\n\n**Required scope:** `write_media` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"file updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Media"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaLibraryUpdateParams"}}},"required":true}}},"/api/v3/admin/media/{id}/usage":{"parameters":[{"name":"id","in":"path","description":"Media ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Where a file is used","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Lists everywhere this file appears: products it is placed on, image\nfields that picked it, and descriptions embedding it. Reusing a file\nshares it rather than copying it, so deleting one placement can leave\nothers pointing at the same file — check this first.\n\nDescription matches are best-effort: an embedded image is a plain URL\nwith nothing recording it, so treat an empty result as \"nothing found\",\nnot proof the file is unused.\n\n\n**Required scope:** `read_media` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"usage found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["media","attachment","rich_text"]},"name":{"type":"string","nullable":true},"owner_type":{"type":"string"},"owner_id":{"type":"string","nullable":true},"field":{"type":"string","nullable":true}}}}}}}}}}}},"/api/v3/admin/products/{product_id}/media":{"parameters":[{"name":"product_id","in":"path","description":"Product ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"List product media","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the files placed on a product, in their display order.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[attached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `attached`."},{"name":"q[filename_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `filename_cont` to the given value."},{"name":"q[unattached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `unattached`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[alt_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `alt` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `media_type` | One of `image`, `video`, `external_video` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `alt`, `created_at`, `id`, `media_type`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Media","sortable":["alt","created_at","id","media_type","position","updated_at"]},"responses":{"200":{"description":"media found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Place a library file on a product","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Puts a file that is already in the library onto this product. The new\nrecord shares the source's file rather than copying it, so nothing is\nuploaded and no image is reprocessed; it carries its own alt text,\nposition and variant links from here on.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"file placed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Media"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaCreateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/media/{id}":{"parameters":[{"name":"product_id","in":"path","description":"Product ID","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","description":"Media ID","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update product media","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits a file placed on a product: its alt text, position and focal\npoint, and which of the product's variants it shows for\n(`variant_ids`).\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"media updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Media"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaUpdateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/variants/{variant_id}/media":{"parameters":[{"name":"product_id","in":"path","description":"Product ID","required":true,"schema":{"type":"string"}},{"name":"variant_id","in":"path","description":"Variant ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"List variant media","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the files placed on one of a product's variants, in their display order.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[attached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `attached`."},{"name":"q[filename_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `filename_cont` to the given value."},{"name":"q[unattached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `unattached`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[alt_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `alt` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `media_type` | One of `image`, `video`, `external_video` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `alt`, `created_at`, `id`, `media_type`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Media","sortable":["alt","created_at","id","media_type","position","updated_at"]},"responses":{"200":{"description":"media found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/deliveries":{"get":{"summary":"List deliveries","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The consignments of a parcel — one per tracking number, each with the carrier status last reported.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[carrier_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carrier` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `pending`, `pre_transit`, `in_transit`, `out_for_delivery`, `available_for_pickup`, `delivered`, `return_to_sender`, `failure`, `unknown` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `tracking_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `carrier`, `created_at`, `id`, `status`, `tracking_number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Delivery","sortable":["carrier","created_at","id","status","tracking_number","updated_at"]},"responses":{"200":{"description":"deliveries found","content":{"application/json":{}}}}},"post":{"summary":"Record a delivery","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a tracked consignment to a parcel — a second box, or a freight PRO number covering several pallets. The carrier is free text.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"201":{"description":"delivery recorded","content":{"application/json":{}}},"422":{"description":"tracking number already recorded on this parcel","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/deliveries/{id}":{"patch":{"summary":"Correct a delivery","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Corrects the tracking number, carrier or link. A corrected number starts the carrier journey over.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Delivery ID","schema":{"type":"string"}}],"responses":{"200":{"description":"delivery updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a delivery","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a hand-entered consignment. One a label minted is refused — refund the label instead.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Delivery ID","schema":{"type":"string"}}],"responses":{"204":{"description":"delivery deleted"}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/deliveries/{id}/mark_delivered":{"patch":{"summary":"Mark a delivery delivered","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Staff confirming one consignment arrived. The parcel becomes delivered once every one of its consignments has.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Delivery ID","schema":{"type":"string"}}],"responses":{"200":{"description":"delivery marked delivered","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMarkDeliveredParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/labels":{"get":{"summary":"List shipping labels","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every label bought or uploaded for a parcel, refunded ones included.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[carrier_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carrier` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `source` | One of `purchased`, `uploaded` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `purchased`, `refund_requested`, `refunded` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `tracking_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `carrier`, `created_at`, `id`, `source`, `status`, `tracking_number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ShippingLabel","sortable":["carrier","created_at","id","source","status","tracking_number","updated_at"]},"responses":{"200":{"description":"labels found","content":{"application/json":{}}}}},"post":{"summary":"Buy or record a shipping label","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"With no body, buys the label through the parcel's carrier account. With a `file`, records a label bought elsewhere. Either way the tracking number becomes a delivery on the parcel.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"201":{"description":"label purchased","content":{"application/json":{}}},"422":{"description":"provider does not produce labels","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingLabelCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/labels/{id}":{"get":{"summary":"Get a shipping label","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"One label, with what it cost and where to print it from.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Shipping label ID","schema":{"type":"string"}}],"responses":{"200":{"description":"label found","content":{"application/json":{}}}}},"delete":{"summary":"Delete an uploaded label","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes an uploaded label. A purchased label is refunded instead, so the postage history stays honest.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Shipping label ID","schema":{"type":"string"}}],"responses":{"204":{"description":"label deleted"}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/labels/{id}/refund":{"patch":{"summary":"Refund a shipping label","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Asks the carrier to refund a purchased label. The consignment it minted is removed when the parcel never shipped.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Shipping label ID","schema":{"type":"string"}}],"responses":{"200":{"description":"refund filed","content":{"application/json":{}}},"422":{"description":"uploaded labels cannot be refunded","content":{"application/json":{}}}}}},"/api/v3/admin/package_types":{"get":{"summary":"List package types","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's packaging vocabulary: the box it ships parcels in\nand the cartons, pallets and containers a wholesale order leaves on.\n\n`volume` is the cubic meters the package occupies, converted from\nwhatever unit its dimensions were recorded in — the figure freight\nvolume rules compare against. It is null until all three sides are\nmeasured.\n\n\n**Required scope:** `read_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `default` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `box`, `envelope`, `carton`, `pallet`, `container` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `default`, `id`, `kind`, `name`, `seller_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PackageType","sortable":["created_at","default","id","kind","name","seller_id","updated_at"]},"responses":{"200":{"description":"package types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PackageType"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a package type","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a kind of packaging to the store.\n\n`weight` is the empty package's own weight, added to content weight on\nevery quote; `max_weight` is what it can hold. Setting `default` makes\nthis the box every parcel quote is built on, and demotes whichever row\nheld that before.\n\nA variant references a `carton`-kind row to say what it is packed\ninto; other kinds are the merchant's own vocabulary.\n\n\n**Required scope:** `write_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"package type created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageType"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageTypeCreateParams"}}},"required":true}}},"/api/v3/admin/package_types/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Package type ID","schema":{"type":"string"}}],"get":{"summary":"Get a package type","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single package type by prefixed ID.\n\n**Required scope:** `read_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"package type found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageType"}}}},"404":{"description":"package type not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a package type","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a package type. Every product packed in it follows the new geometry.\n\n**Required scope:** `write_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"package type updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageType"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageTypeUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a package type","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a kind of packaging. Refused while any variant is packed into\nit — repack those products first.\n\n\n**Required scope:** `write_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"package type deleted"}}}},"/api/v3/admin/price_lists/{price_list_id}/products":{"get":{"summary":"List price list products","tags":["Price Lists"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The products the list prices, listed by name — membership is derived from the price rows.\n`expand=price_list_price` adds what the list charges for each variant, with its quantity\nbreaks as tiers, the same reading a catalog's products carry.\n\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"price_list_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"expand","in":"query","required":false,"description":"Comma-separated. `price_list_price` adds the resolved price to every row.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","created_at","description","discontinue_on","id","name","price","seller_id","slug","status","updated_at"]},"responses":{"200":{"description":"products found, with what the list charges","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PriceListProduct"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Add products to a price list","tags":["Price Lists"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds products to the list in bulk, materializing a placeholder price per variant and store currency. Already-present products are skipped.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"price_list_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"products added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}},"delete":{"summary":"Remove products from a price list","tags":["Price Lists"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes products from the list in bulk, hard-deleting their price rows. Ids that are not members are ignored.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"price_list_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}}},"/api/v3/admin/product_types":{"get":{"summary":"List product types","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of product types.\n\nA product type is a back-office template: it seeds option types and\ncategories onto products created with it, and defines which custom\nfields those products' forms show. It is not exposed on the Store API.\n\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[option_types_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ProductType","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"product types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ProductType"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a product type","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a product type.\n\n`option_type_ids` and `category_ids` seed products created with this\ntype. `custom_field_definitions` is a replace-set of the definitions the\nproduct form renders, in `sort_order`. `required` is advisory — the\ndashboard marks the field, but a blank value is never rejected.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"product type created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductType"}}}},"422":{"description":"unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductTypeCreateParams"}}},"required":true}}},"/api/v3/admin/product_types/{id}":{"parameters":[{"name":"id","in":"path","description":"Product type ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Retrieve a product type","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single product type with its option types, categories and custom fields.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"product type found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductType"}}}},"404":{"description":"product type not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a product type","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a product type.\n\nChanges never modify products that already carry the type — use\n`apply_to_products` to backfill those.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"product type updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductType"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductTypeUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a product type","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a product type. Types still used by products cannot be deleted.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"product type deleted"}}}},"/api/v3/admin/product_types/{id}/apply_to_products":{"parameters":[{"name":"id","in":"path","description":"Product type ID","required":true,"schema":{"type":"string"}}],"post":{"summary":"Apply a product type to its existing products","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Backfills the type's option types and categories onto the products that\nalready carry it. Additive and idempotent — nothing is removed, and\nre-running is safe.\n\nRuns in the background; the response reports how many products the type\ncurrently has.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"202":{"description":"backfill accepted","content":{"application/json":{"schema":{"type":"object","properties":{"products_count":{"type":"integer"}}}}}}}}},"/api/v3/admin/purchase_orders":{"get":{"summary":"List purchase orders","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Stock bought from suppliers. A purchase order carries what a purchase\nhas and a stock transfer does not: a supplier, a unit cost per line and\nan expected arrival date.\n\nOrdered units never count toward availability. Nothing here changes\n`count_on_hand` until `receive` runs, because a merchant who has\nordered stock does not have it.\n\nStatuses are `draft`, `ordered`, `partially_received`, `received`, `over_received` and\n`canceled`. Each move between them is its own endpoint, not a `PATCH`\nthat writes `status`.\n\nFilter with Ransack predicates such as `q[status_eq]`,\n`q[supplier_id_eq]` or `q[expected_at_lteq]`. Expand `items`,\n`supplier` and `destination_location`.\n\n\n**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number and reference (partial, case-insensitive)."},{"name":"q[closed]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `closed`."},{"name":"q[open]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `open`."},{"name":"q[overdue]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `overdue`."},{"name":"q[past_cancel_by]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `past_cancel_by`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed: items, supplier, destination_location","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `cancel_by` | Date | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `closed_short_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `destination_location_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `expected_at` | Date | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `ordered_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `received_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `ordered`, `partially_received`, `received`, `over_received`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `supplier_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[destination_location_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `destination_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `destination_location_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `items_` | `created_at`, `id`, `quantity_ordered`, `quantity_received`, `quantity_rejected`, `unit_cost`, `updated_at`, `variant_id` |\n| `items_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `supplier_` | `city`, `contact_name`, `country_code`, `created_at`, `email`, `id`, `name`, `phone`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `cancel_by`, `closed_short_at`, `created_at`, `currency`, `destination_location_id`, `expected_at`, `id`, `number`, `ordered_at`, `received_at`, `reference`, `status`, `supplier_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PurchaseOrder","sortable":["cancel_by","closed_short_at","created_at","currency","destination_location_id","expected_at","id","number","ordered_at","received_at","reference","status","supplier_id","updated_at"]},"responses":{"200":{"description":"purchase orders found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PurchaseOrder"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a purchase order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Drafts an order. Nothing is on order and nothing touches availability\nuntil the order is marked as ordered and then received.\n\n`currency` defaults to the store's; set it for a foreign-currency\norder. `expected_at` is a calendar date (`yyyy-mm-dd`) — the day the\nsupplier promised means the same day in every timezone.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"purchase order created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}},"404":{"description":"supplier belongs to another store","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrderCreateParams"}}},"required":true}}},"/api/v3/admin/purchase_orders/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"get":{"summary":"Get a purchase order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed: items, supplier, destination_location","schema":{"type":"string"}}],"responses":{"200":{"description":"purchase order found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}},"404":{"description":"purchase order not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a purchase order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits a draft: its supplier, destination, dates, reference, notes and\nlines. Sending `items` replaces every line the order holds. Status\nmoves through the order's own actions, never through this endpoint.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"purchase order updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrderUpdateParams"}}},"required":true}}},"/api/v3/admin/purchase_orders/{id}/mark_ordered":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"patch":{"summary":"Place the order with the supplier","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Moves a `draft` to `ordered`: the lines are frozen and `ordered_at` is\nstamped. Availability is still untouched — ordered stock is not stock\nthe merchant has.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"purchase order placed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}}}},"/api/v3/admin/purchase_orders/{purchase_order_id}/stock_receipts":{"parameters":[{"name":"purchase_order_id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"get":{"summary":"List the deliveries booked against an order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Each delivery the dock counted in, newest first — with its packing-slip reference and what it accepted and refused.\n\n**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `receivable_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `receivable_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `received_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `received_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `received_by_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `number`, `receivable_id`, `receivable_type`, `received_at`, `received_by_id`, `received_by_type`, `reference`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockReceipt","sortable":["created_at","id","number","receivable_id","receivable_type","received_at","received_by_id","received_by_type","reference","updated_at"]},"responses":{"200":{"description":"deliveries found","content":{"application/json":{}}}}},"post":{"summary":"Book in a delivery","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The moment purchased goods first count toward availability. Records\none delivery as a stock receipt: what this delivery brought, per line,\nnot a running total — a second delivery adds to the first.\n\n`quantity_accepted` reaches the shelf; `quantity_rejected` is refused\nand recorded with a `rejection_reason` (`damaged`, `wrong_item`,\n`expired` or `other`), never stocked. Omit `items` to book in\neverything still outstanding, intact.\n\nEach `received` stock movement carries the line's `unit_cost` and\nnames the receipt, so a delivery can be reconciled against the ledger.\n\nThe order stays `partially_received` while any line is still owed,\nsettles in `received` once every line has what it expected, and in\n`over_received` once any line has more.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"delivery booked in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockReceipt"}}}},"422":{"description":"order has not been placed yet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockReceiptCreateParams"}}},"required":true}}},"/api/v3/admin/purchase_orders/{id}/mark_draft":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"patch":{"summary":"Take an order back to draft","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Reopens a placed order for editing. Only while no delivery has been booked against it; `ordered_at` is cleared.\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"order back in draft","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}}}},"/api/v3/admin/purchase_orders/{id}/close":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"patch":{"summary":"Close an order short","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Ends a partially received order whose balance the supplier will not\ndeliver. Nothing moves: what arrived stays on the shelf, the\noutstanding count stays on each line, and the order settles in\n`received` with `closed_short_at` and the `reason` recorded.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"order closed short","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReceivableCloseParams"}}},"required":true}}},"/api/v3/admin/purchase_orders/{id}/cancel":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"patch":{"summary":"Cancel a purchase order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Closes what is still outstanding. Nothing is unwound: a purchase order\nnever moved stock until units were received, and units already received\nstay on the shelf because the merchant has them.\n\nA `reason` is appended to the order's notes.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"purchase order cancelled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrderCancelParams"}}},"required":true}}},"/api/v3/admin/reporting/saved_reports":{"get":{"summary":"List saved reports","tags":["Reports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's saved reports, each a named query staff can run again.\n\n**Required scope:** `read_reports` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seeded` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `seeded`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SavedReport","sortable":["created_at","id","name","seeded","updated_at"]},"responses":{"200":{"description":"saved reports found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SavedReport"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a saved report","tags":["Reports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Saves a reporting query under a name so staff can run it again. The query is validated against the reporting registry.\n\n**Required scope:** `write_reports` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"saved report created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavedReport"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavedReportCreateParams"}}},"required":true}}},"/api/v3/admin/reporting/saved_reports/{id}":{"parameters":[{"name":"id","in":"path","description":"Saved report ID","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a saved report","tags":["Reports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_reports` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"saved report updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavedReport"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavedReportUpdateParams"}}},"required":true}}},"/api/v3/admin/reporting/query":{"post":{"summary":"Run a reporting query","tags":["Reports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Runs a query against the store's registered metrics and dimensions, in\nthe store's time zone. A metric or dimension the registry does not know\nis refused with the names that are valid, and an API key needs the read\nscope of every resource the query touches.\n\n\n**Required scope:** `read_reports` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"query results","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportingQueryParams"}}},"required":true}}},"/api/v3/admin/seller_requirements":{"get":{"summary":"List seller requirements","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"What this marketplace asks of a seller before it will let them trade,\nin the order sellers work through it.\n\nEach row is one configured requirement. `required` says whether it\nstands between the seller and approval — the others are shown as\nrecommended and counted in their progress, but never block. `active`\nswitches one off without losing how it was worded.\n\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SellerRequirement","sortable":["created_at","id","name","position","updated_at"]},"responses":{"200":{"description":"seller requirements found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerRequirement"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}}}}}}}},"post":{"summary":"Add a seller requirement","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds something the marketplace asks of its sellers.\n\n`type` comes from `GET /seller_requirements/types`, which also\ndescribes the configuration each kind takes. Most kinds answer one\nquestion and can be added once; the open-ended ones — a seller\nconfirmation, a manual check, a document — carry the question in your\nown `name` and `description`, so a store may add as many as it needs.\n\nA kind that reads the seller's own data (their addresses, their\nproducts, whether they accepted the terms) needs nothing from the\nseller beyond doing it. The others wait for the seller to submit\nsomething, and the ones you review wait for you.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"seller requirement created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirement"}}}},"422":{"description":"kind is not registered","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementCreateParams"}}},"required":true}}},"/api/v3/admin/seller_requirements/types":{"get":{"summary":"List seller requirement kinds","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The kinds you can add, and the shape of each one's configuration form.\n\n`configured` says the store already has this kind — meaningful only\nwhere `allow_multiple` is false. `accepts_submissions` says the seller\nrecords having done it rather than it being read from their data, and\n`reviewed_by_operator` says what they send waits for you.\n\nA marketplace that registers its own kind server-side sees it here\nwithout this endpoint changing.\n\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"kinds found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"allow_multiple":{"type":"boolean"},"accepts_submissions":{"type":"boolean"},"reviewed_by_operator":{"type":"boolean"},"configured":{"type":"boolean"},"addable":{"type":"boolean","description":"Whether the operator may add one now. The uniqueness rule is the server's, so clients filter on this rather than deriving it."},"schema":{"type":"object","description":"JSON Schema of the type's `preferences`"}}}}}}}}}}}},"/api/v3/admin/seller_requirements/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a seller requirement","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes how a requirement is worded, what it asks for, where it sits in\nthe checklist, and whether it blocks approval.\n\n`type` is not accepted: a saved row's kind never changes, because\nanything a seller already submitted answered the old one.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller requirement updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirement"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a seller requirement","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Stops asking for this. Anything sellers already submitted against it\ngoes too — to keep the record while pausing the ask, set `active` to\nfalse instead.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"seller requirement deleted"}}}},"/api/v3/admin/sellers":{"get":{"summary":"List sellers","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the sellers on this marketplace. `status` says where each one\nis in its life on the marketplace, and `sellable` answers the question\nthe status alone cannot: an approved seller who is away cannot be\nbought from either.\n\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `contact_email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `pending`, `invited`, `canceled`, `onboarding`, `ready_for_review`, `approved`, `rejected`, `suspended` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Seller","sortable":["contact_email","created_at","id","name","status","updated_at"]},"responses":{"200":{"description":"sellers found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Seller"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Opens a seller record. The seller starts as `pending` and has no team\nyet — invite someone to run it with the `invite` action below.\n\n`status` is deliberately not writable here or on update: every move\nthrough the lifecycle is its own action, because each one does more\nthan set a column.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"seller created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerCreateParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"get":{"summary":"Get a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single seller, including its settlement and tax configuration.\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}},"404":{"description":"seller not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates the seller's profile and the settlement configuration the\noperator owns. A `status` sent here is ignored — use the lifecycle\nactions.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller address written inline","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the seller. Their products are kept and left without a\nseller rather than deleted — what happens to a departed seller's\ncatalog is the operator's decision.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"seller deleted"}}}},"/api/v3/admin/sellers/{id}/invite":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"post":{"summary":"Invite someone to run a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sends an invitation to the seller's own team and moves the seller to\n`invited`. The person becomes a member when they accept, and can then\nsign in to the seller panel.\n\n`role_id` must name a role this seller owns; omit it for the seller's\nown admin role. Re-inviting is allowed — an invitation expires, or the\nfirst one goes to the wrong address.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"invitation sent","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerInviteParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}/approve":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Approve a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Lets the seller sell. This is also the way back for one that was\nsuspended or turned down, and it clears any holiday along with the\nsuspension.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller approved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}},"422":{"description":"seller cannot be approved from its current status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerApproveParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}/reopen_onboarding":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Send a seller back to onboarding","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a seller waiting for review to onboarding, with a `note`\nsaying what they have to fix. Unlike `reject`, this expects them back.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"onboarding reopened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerReopenOnboardingParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}/suspend":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Suspend a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Stops a trading seller from selling. Their catalog and history stay,\nand approving reinstates them. Use this rather than `reject` for a\nseller already on the marketplace — it says something different, and\nit can be undone.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller suspended","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerSuspendParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}/reject":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Reject a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Turns down an applicant who never traded. A seller already selling is\nsuspended instead; rejecting one is refused.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller rejected","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRejectParams"}}},"required":true}}},"/api/v3/admin/sellers/{seller_id}/balances":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"get":{"summary":"List a seller's balances","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Where one seller stands with the marketplace, one row per currency:\nwhat they have earned (completed transfers, refund reversals\nincluded), what has been paid to them, what is still owed, and\nearnings the payout provider has not yet confirmed.\n\nComputed from the ledger rather than stored, so the rows carry no id.\n\n\n**Required scope:** `read_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"balances listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerBalance"}}},"required":["data"]}}}},"404":{"description":"seller not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/sellers/{seller_id}/payouts":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"post":{"summary":"Settle a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sweeps everything this seller is owed into a payout — one per currency,\nsince nothing is ever converted between them.\n\nThis is what the `manual` payout interval means: the scheduled sweep\nruns on each seller's own interval and skips anyone set to `manual`,\nleaving the operator to decide when. It also settles any other seller\nearly.\n\nIt records the settlement rather than sending money: the built-in\nprovider waits to be told the bank transfer went out, which is\n`PATCH /api/v3/admin/seller_payouts/{id}/complete`.\n\nAnswers `422` when there is nothing to settle — no payout account,\nnothing unsettled, or a balance below the seller's minimum.\n\n\n**Required scope:** `write_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"seller settled","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerPayout"}}},"required":["data"]}}}},"422":{"description":"nothing to settle","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/sellers/{seller_id}/requirement_submissions":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"get":{"summary":"List a seller's requirement submissions","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"What this seller submitted against the marketplace requirements, with the review decision on each.\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Records per page (max 100)","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `reviewed_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `status` | One of `pending`, `accepted`, `rejected`, `waived` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[requirement_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `requirement_` | `created_at`, `id`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `reviewed_at`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SellerRequirementSubmission","sortable":["created_at","id","reviewed_at","status","updated_at"]},"responses":{"200":{"description":"submissions listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerRequirementSubmission"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Waive a requirement for a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Excuses this one seller from a requirement the marketplace asks of\neveryone, recorded as a `waived` submission. The operator never\nsubmits on the seller's behalf: this endpoint only waives.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"requirement waived","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementSubmission"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementWaiveParams"}}},"required":true}}},"/api/v3/admin/sellers/{seller_id}/requirement_submissions/{id}/accept":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Requirement submission ID","schema":{"type":"string"}}],"patch":{"summary":"Accept a seller's submission","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Marks what the seller submitted as meeting the requirement.\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"submission accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementSubmission"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementReviewParams"}}}}}},"/api/v3/admin/sellers/{seller_id}/requirement_submissions/{id}/reject":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Requirement submission ID","schema":{"type":"string"}}],"patch":{"summary":"Reject a seller's submission","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Turns down what the seller submitted. `review_note` is the reason sent\nback to the seller, who can then submit again.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"submission rejected","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementSubmission"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementReviewParams"}}}}}},"/api/v3/admin/seller_transfers":{"get":{"summary":"List seller transfers","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The fund ledger: what each seller earned from an order, and any\nreversals. Read-only, since fulfilment and refunds write it.\n\n\n**Required scope:** `read_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of reference (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Records per page (max 100)","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `earning`, `refund_reversal` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `payout_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `provider` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `pending`, `processing`, `completed`, `failed`, `unresolved` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[payout_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `payout_` | `amount`, `created_at`, `currency`, `id`, `period_end`, `period_start`, `provider`, `reference`, `seller_id`, `status`, `updated_at` |\n| `payout_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `refund_` | `created_at`, `id`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `currency`, `id`, `kind`, `order_id`, `payout_id`, `provider`, `reference`, `seller_id`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SellerTransfer","sortable":["amount","created_at","currency","id","kind","order_id","payout_id","provider","reference","seller_id","status","updated_at"]},"responses":{"200":{"description":"transfers listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerTransfer"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/seller_payouts":{"get":{"summary":"List seller payouts","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Settlements to sellers, each batching the transfers that had\naccumulated since the last. `pending` and `processing` payouts are\nstill owed; `completed` ones reached the seller.\n\n\n**Required scope:** `read_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of reference (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Records per page (max 100)","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `period_end` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `period_start` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `provider` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `pending`, `processing`, `completed`, `failed`, `unresolved` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `currency`, `id`, `period_end`, `period_start`, `provider`, `reference`, `seller_id`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SellerPayout","sortable":["amount","created_at","currency","id","period_end","period_start","provider","reference","seller_id","status","updated_at"]},"responses":{"200":{"description":"payouts listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerPayout"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/seller_payouts/{id}/complete":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller payout prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Mark a payout paid","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records that the money reached the seller, which is what debits their\nbalance — a balance is earnings less *completed* settlements.\n\nThis is the step the built-in provider waits for: it files the\nsettlement when the payout is created and expects an operator to say\nthe bank transfer went out. A connected provider marks its own payouts\npaid when its webhook reports the money landed.\n\nSend the provider's own id for the transfer as `reference` when there\nis one. Completing a payout that is already complete answers `200`\nwithout recording it twice, so a redelivered webhook or a double click\nis safe.\n\n\n**Required scope:** `write_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"payout completed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerPayout"}}}},"404":{"description":"payout not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerPayoutCompleteParams"}}},"required":true}}},"/api/v3/admin/stock_levels":{"get":{"summary":"List stock levels","tags":["Stock"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"One row per variant per stock location, carrying every figure the\nInventory page shows: `count_on_hand` (on hand), `allocated_count`\n(committed to placed orders), `reserved_count` (held by checkouts in\nprogress), `available_count` (on hand minus committed) and\n`incoming_count` (on its way on an open purchase order or a transfer\nin transit). The variant and location are named flat on the row\n(`variant_name`, `variant_sku`, `stock_location_name`, `thumbnail_url`)\nso a list needs no expansion.\n\nFilter with `q[stock_location_id_eq]`, `q[variant_id_eq]` or\n`q[variant_sku_or_variant_product_name_cont]`.\n\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of variant sku and variant product name (partial, case-insensitive)."},{"name":"q[with_stock_status][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_stock_status` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[allocated_count_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `allocated_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `count_on_hand` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `incoming_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `reserved_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `stock_location_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `variant_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[stock_location_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `stock_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `stock_location_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variant_product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `allocated_count`, `count_on_hand`, `created_at`, `id`, `incoming_count`, `reserved_count`, `stock_location_id`, `updated_at`, `variant_id`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockLevel","sortable":["allocated_count","count_on_hand","created_at","id","incoming_count","reserved_count","stock_location_id","updated_at","variant_id"]},"responses":{"200":{"description":"stock levels found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockLevel"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/stock_levels/bulk_upsert":{"post":{"summary":"Bulk-upsert stock levels","tags":["Stock"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sets stock levels for many (variant, location) pairs at once — what a\nwarehouse or ERP feed posts on a schedule.\n\nEach row names its variant and stock location by Spree id\n(`variant_id`, `stock_location_id`).\n\nA row carries either `count_on_hand` — the absolute level the external\nsystem reports — or `adjustment`, a relative change for feeds that\nreport movements instead. Every change is written as a stock movement,\nso a merchant can still see why a figure moved.\n\nThe response carries `stock_level_count`: how many rows moved a shelf.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"stock levels updated","content":{"application/json":{}}},"422":{"description":"row is missing a level","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLevelBulkUpsertParams"}}},"required":true}}},"/api/v3/admin/stock_levels/{id}":{"patch":{"summary":"Update a stock level","tags":["Stock"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Corrects one shelf. Send `count_on_hand` for the count the shelf should\nend at, or `adjustment` for a signed change; either is recorded as a\nstock movement labelled with `reason`.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Stock level ID","schema":{"type":"string"}}],"responses":{"200":{"description":"stock level updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLevel"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLevelUpdateParams"}}},"required":true}}},"/api/v3/admin/stock_movements":{"get":{"summary":"List stock movements","tags":["Stock Movements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the stock ledger, newest first. Every row says what happened to\nstock (`kind`) and carries a direct reference to what caused it, so a\nmerchant can answer \"why is this number what it is?\" from the data.\n\nKinds are `received` (goods arrived), `allocated` (stock promised to a\nplaced order), `shipped` (promised stock left), `released` (a promise\nwithdrawn) and `adjusted` (a manual correction, which always carries a\n`reason`).\n\nMovements are immutable — reversing one means writing its counterpart\nthrough the resource that caused it, which is why there is no create,\nupdate or delete here.\n\nFilter with Ransack predicates such as `q[kind_eq]`,\n`q[stock_level_id_eq]`, `q[order_id_eq]`, `q[fulfillment_id_eq]` or\n`q[created_at_gteq]`.\n\n`kind` is null on rows written before Spree 6.0 until\n`spree:migrate_stock_movements_to_typed_rows` has run.\n\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[reason_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `exchange_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `fulfillment_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `received`, `allocated`, `shipped`, `released`, `adjusted` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `purchase_order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `reason` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `return_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `stock_level_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `stock_receipt_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `stock_transfer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `unit_cost` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[stock_level_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `stock_level_` | `allocated_count`, `count_on_hand`, `created_at`, `id`, `incoming_count`, `reserved_count`, `stock_location_id`, `updated_at`, `variant_id` |\n| `stock_level_stock_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `stock_level_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `exchange_id`, `fulfillment_id`, `id`, `kind`, `order_id`, `purchase_order_id`, `quantity`, `reason`, `return_id`, `stock_level_id`, `stock_receipt_id`, `stock_transfer_id`, `unit_cost`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockMovement","sortable":["created_at","exchange_id","fulfillment_id","id","kind","order_id","purchase_order_id","quantity","reason","return_id","stock_item_id","stock_level_id","stock_receipt_id","stock_transfer_id","unit_cost","updated_at"]},"responses":{"200":{"description":"stock movements found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockMovement"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/stock_movements/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock movement ID","schema":{"type":"string"}}],"get":{"summary":"Get a stock movement","tags":["Stock Movements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single stock movement by prefixed ID.\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"stock movement found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockMovement"}}}},"404":{"description":"stock movement not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/stock_reservations":{"get":{"summary":"List stock reservations","tags":["Stock"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the stock held for orders that are being checked out, so it cannot be sold twice before they complete or the hold expires.\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `expires_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `line_item_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `stock_level_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[line_item_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `line_item_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `line_item_order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `line_item_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `line_item_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `stock_level_` | `allocated_count`, `count_on_hand`, `created_at`, `id`, `incoming_count`, `reserved_count`, `stock_location_id`, `updated_at`, `variant_id` |\n| `stock_level_stock_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `stock_level_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `expires_at`, `id`, `line_item_id`, `order_id`, `quantity`, `stock_level_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockReservation","sortable":["created_at","expires_at","id","line_item_id","order_id","quantity","stock_item_id","stock_level_id","updated_at"]},"responses":{"200":{"description":"stock reservations found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockReservation"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/stock_transfers":{"get":{"summary":"List stock transfers","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Stock moving between two of the merchant's own warehouses.\n\nA transfer is a trip, not an instant. Units leave the source when the\ntransfer is marked in transit and land at the destination when somebody\ncounts them in — in between they are in flight, gone from one shelf and\nnot yet on the other.\n\nStatuses are `draft`, `ready_to_ship`, `in_transit`,\n`partially_received`, `received`, `over_received` and `canceled`. Each move between them\nis its own endpoint, not a `PATCH` that writes `status`.\n\nReceiving from a supplier is a purchase order, not a transfer with a\nmissing source.\n\nFilter with Ransack predicates such as `q[status_eq]`,\n`q[source_location_id_eq]` or `q[number_or_reference_cont]`. Expand\n`items`, `source_location` and `destination_location`.\n\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number and reference (partial, case-insensitive)."},{"name":"q[closed]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `closed`."},{"name":"q[open]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `open`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed: items, source_location, destination_location","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `closed_short_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `destination_location_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `received_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `shipped_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `source_location_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `draft`, `ready_to_ship`, `in_transit`, `partially_received`, `received`, `over_received`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[destination_location_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `destination_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `destination_location_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `items_` | `created_at`, `id`, `quantity_received`, `quantity_rejected`, `quantity_shipped`, `updated_at`, `variant_id` |\n| `items_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `source_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `source_location_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `closed_short_at`, `created_at`, `destination_location_id`, `id`, `number`, `received_at`, `reference`, `shipped_at`, `source_location_id`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockTransfer","sortable":["closed_short_at","created_at","destination_location_id","id","number","received_at","reference","shipped_at","source_location_id","status","updated_at"]},"responses":{"200":{"description":"stock transfers found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockTransfer"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Persists a draft — a packing list the merchant can still edit. Nothing\nmoves until the transfer is marked in transit.\n\nA draft may legitimately open empty and gain lines as the merchant\npacks. Both warehouses are required and must belong to the same store.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"stock transfer created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}},"404":{"description":"warehouse belongs to another store","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransferCreateParams"}}},"required":true}}},"/api/v3/admin/stock_transfers/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"get":{"summary":"Get a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed: items, source_location, destination_location","schema":{"type":"string"}}],"responses":{"200":{"description":"stock transfer found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}},"404":{"description":"stock transfer not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits a draft: its reference, notes, either end, and its lines.\nSending `items` replaces every line the draft holds. Status moves\nthrough the transfer's own actions, never through this endpoint.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"stock transfer updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransferUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Drafts only. Past `draft` the transfer describes a box that physically\nexists, so it is cancelled rather than deleted — a 422 says so.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"stock transfer deleted"}}}},"/api/v3/admin/stock_transfers/{id}/mark_ready":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Mark a transfer ready to ship","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Freezes the lines so the warehouse and the merchant are looking at the\nsame list. Nothing leaves the shelf yet.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer is ready to ship","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}}}},"/api/v3/admin/stock_transfers/{id}/mark_in_transit":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Send a transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The moment stock leaves the source warehouse: `shipped` movements are\nwritten against the source's levels and `shipped_at` is stamped. The\ndestination is deliberately untouched — the units are in flight.\n\nRefused with a 422 when the source does not hold enough. Pass\n`force: true` to record the departure anyway: a merchant forcing it has\ndecided the box left whatever the ledger claims.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer is in transit","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransferMarkInTransitParams"}}},"required":true}}},"/api/v3/admin/stock_transfers/{stock_transfer_id}/stock_receipts":{"parameters":[{"name":"stock_transfer_id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"get":{"summary":"List the deliveries counted in against a transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Each delivery the destination counted in, with what it accepted and refused.\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `receivable_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `receivable_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `received_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `received_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `received_by_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `number`, `receivable_id`, `receivable_type`, `received_at`, `received_by_id`, `received_by_type`, `reference`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockReceipt","sortable":["created_at","id","number","receivable_id","receivable_type","received_at","received_by_id","received_by_type","reference","updated_at"]},"responses":{"200":{"description":"deliveries found","content":{"application/json":{}}}}},"post":{"summary":"Count a delivery in","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records one delivery the destination warehouse counted in, as a stock\nreceipt. Partial receipt is the normal case: ten left, eight arrived,\ntwo were crushed in transit. Quantities are this delivery's counts —\na second box adds to the first rather than restating it.\n\n`quantity_accepted` lands on the destination's shelf;\n`quantity_rejected` is refused and recorded with a `rejection_reason`\n(`damaged`, `wrong_item`, `expired` or `other`), never stocked. A\nrefused unit still arrived, so it counts toward the trip being over.\nOmit `items` to count in everything still outstanding, intact.\n\nThe transfer stays `partially_received` while units are still on the\nroad, settles in `received` once everything has arrived, and in\n`over_received` once more arrived than was shipped.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"delivery counted in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockReceipt"}}}},"422":{"description":"transfer has not shipped yet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockReceiptCreateParams"}}},"required":true}}},"/api/v3/admin/stock_transfers/{id}/mark_draft":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Take a transfer back to draft","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Unfreezes a ready-to-ship transfer so its lines can be changed. Nothing has left the source, so nothing is undone.\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer back in draft","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}}}},"/api/v3/admin/stock_transfers/{id}/close":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Close a transfer short","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Ends a partially received transfer whose missing units are not going\nto turn up. Nothing moves — they already left the source — and the\ntransfer settles in `received` with `closed_short_at` and the\n`reason` recorded, the outstanding count left on each line.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer closed short","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReceivableCloseParams"}}},"required":true}}},"/api/v3/admin/stock_transfers/{id}/cancel":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Cancel a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Calls the trip off.\n\nCancelling a draft or a packed transfer costs nothing — no stock has\nmoved. Cancelling one already in transit needs `on_in_transit`, because\nthe units are physically gone from the source: either they come back\n(`restock`, as if the transfer had never shipped) or they are written\noff as lost (`write_off`). There is no default — guessing would either\ninvent stock or destroy it — so an in-flight cancellation without it is\nrefused with a 422.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer cancelled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}},"422":{"description":"in-transit cancellation needs a decision","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransferCancelParams"}}},"required":true}}},"/api/v3/admin/suppliers":{"get":{"summary":"List suppliers","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Who the merchant buys stock from. A supplier is an address-book entry\nwith a purchasing history — not a party that sells on the store, which\nis a seller.\n\nSuppliers belong to one store, and are soft-deleted so the purchase\norders that name them stay readable.\n\nFilter with Ransack predicates such as\n`q[name_or_contact_name_or_email_cont]` or `q[country_code_eq]`.\n\n\n**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name, contact name, and email (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `city` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `contact_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `phone` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `city`, `contact_name`, `country_code`, `created_at`, `email`, `id`, `name`, `phone`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Supplier","sortable":["city","contact_name","country_code","created_at","email","id","name","phone","updated_at"]},"responses":{"200":{"description":"suppliers found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Supplier"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a supplier","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a supplier to this store's address book. The address is inline —\nstreet, city, state and country live on the supplier itself, the same\nshape a stock location uses.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"supplier created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Supplier"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupplierCreateParams"}}},"required":true}}},"/api/v3/admin/suppliers/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Supplier ID","schema":{"type":"string"}}],"get":{"summary":"Get a supplier","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"supplier found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Supplier"}}}},"404":{"description":"supplier not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a supplier","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"supplier updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Supplier"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupplierUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a supplier","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the supplier, so the purchase orders naming it stay\nreadable. Refused with a 422 while a purchase order still points at it.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"supplier deleted"}}}}},"components":{"schemas":{"PaginationMeta":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"count":{"type":"integer","description":"Total number of records"},"pages":{"type":"integer","description":"Total number of pages"},"from":{"type":"integer","description":"Index of first record on this page"},"to":{"type":"integer","description":"Index of last record on this page"},"in":{"type":"integer","description":"Number of records on this page"},"previous":{"type":"integer","nullable":true,"description":"Previous page number"},"next":{"type":"integer","nullable":true,"description":"Next page number"}},"required":["page","limit","count","pages","from","to","in"]},"ErrorResponse":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"details":{"type":"object","description":"Field-specific validation errors","nullable":true}},"required":["code","message"]}},"required":["error"]},"AuthResponse":{"type":"object","properties":{"token":{"type":"string","description":"JWT access token"},"user":{"$ref":"#/components/schemas/AdminUser"}},"required":["token","user"]},"PermissionRule":{"type":"object","description":"A single permission rule (CanCanCan rule). Rules are applied in order, last-matching-wins.","properties":{"allow":{"type":"boolean","description":"true for `can`, false for `cannot`"},"actions":{"type":"array","items":{"type":"string"},"description":"Action names, e.g. [\"read\", \"update\"] or [\"manage\"]"},"subjects":{"type":"array","items":{"type":"string"},"description":"Subject short names, e.g. [\"product\"] or [\"all\"]"},"has_conditions":{"type":"boolean","description":"True if the server-side rule has per-record conditions. The SPA shows the action optimistically and handles 403 from the API."}},"required":["allow","actions","subjects","has_conditions"]},"ImportSchemaField":{"type":"object","description":"A canonical column of an import type, including per-store custom field columns","properties":{"name":{"type":"string","description":"Canonical field name used in mappings"},"label":{"type":"string","description":"Human-readable label"},"required":{"type":"boolean","description":"Whether the field must be mapped before processing"}},"required":["name","label","required"]},"CheckoutRequirement":{"type":"object","properties":{"step":{"type":"string","description":"Checkout step this requirement belongs to"},"field":{"type":"string","description":"Field that needs to be satisfied"},"message":{"type":"string","description":"Human-readable requirement message"}},"required":["step","field","message"]},"CartWarning":{"type":"object","description":"A warning about a cart issue (e.g., item removed due to stock change)","properties":{"code":{"type":"string","description":"Machine-readable warning code"},"message":{"type":"string","description":"Human-readable warning message"},"line_item_id":{"type":"string","nullable":true,"description":"Prefixed line item ID (when applicable)"},"variant_id":{"type":"string","nullable":true,"description":"Prefixed variant ID (when applicable)"},"item_index":{"type":"integer","nullable":true,"description":"Position in the submitted items array, for warnings raised while applying a batch of item changes"}},"required":["code","message"]},"FulfillmentManifestItem":{"type":"object","description":"An item within a fulfillment — which line item and how many units are in this fulfillment","properties":{"item_id":{"type":"string","description":"Line item ID"},"variant_id":{"type":"string","description":"Variant ID"},"quantity":{"type":"integer","description":"Quantity in this fulfillment"}},"required":["item_id","variant_id","quantity"]},"AdminUserRoleAssignment":{"type":"object","description":"A role assignment for the current store on a staff member","properties":{"id":{"type":"string","description":"Prefixed role ID"},"name":{"type":"string","description":"Role name"}},"required":["id","name"]},"AdminUserStore":{"type":"object","description":"A store the staff member can access through a role assignment","properties":{"id":{"type":"string","description":"Prefixed store ID"},"name":{"type":"string","description":"Store name"},"code":{"type":"string","description":"Store code"}},"required":["id","name","code"]},"PreferenceSchema":{"type":"object","description":"The JSON Schema (draft 2020-12) of a type's `preferences`: one property per setting, with `format` (`money`, `currency`, `iso-country`, `prefixed-id`, …), `enum`, `default`, `x-spree-secret` for a secret and `x-spree-prefix` for an id list. Unknown keys are refused.","additionalProperties":true},"PromotionActionLineItem":{"type":"object","description":"One row in a `create_line_items` action — the variant added to the order and how many","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["variant_id","quantity"]},"MeResponse":{"type":"object","description":"Current admin user profile and serialized permissions","properties":{"user":{"$ref":"#/components/schemas/AdminUser"},"permissions":{"type":"array","items":{"$ref":"#/components/schemas/PermissionRule"}}},"required":["user","permissions"]},"Actor":{"type":"object","properties":{"id":{"type":"string"},"type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"label":{"type":"string","nullable":true}},"required":["id","type","label"],"x-typelizer":true},"Address":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string","nullable":true},"first_name":{"type":"string","nullable":true},"last_name":{"type":"string","nullable":true},"full_name":{"type":"string"},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"postal_code":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_name":{"type":"string"},"country_code":{"type":"string"},"state_text":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"quick_checkout":{"type":"boolean"},"is_default_billing":{"type":"boolean"},"is_default_shipping":{"type":"boolean"},"state_abbr":{"type":"string","nullable":true,"deprecated":true},"country_iso":{"type":"string","deprecated":true},"state_name":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"latitude":{"type":"number","nullable":true},"longitude":{"type":"number","nullable":true},"customer_id":{"type":"string","nullable":true},"owner_id":{"type":"string","nullable":true},"owner_type":{"type":"string","nullable":true}},"required":["id","label","first_name","last_name","full_name","address1","address2","postal_code","city","phone","company","country_name","country_code","state_text","state_code","quick_checkout","is_default_billing","is_default_shipping","state_abbr","country_iso","state_name","metadata","created_at","updated_at","latitude","longitude","customer_id","owner_id","owner_type"],"x-typelizer":true},"AdminUser":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"first_name":{"type":"string","nullable":true},"last_name":{"type":"string","nullable":true},"full_name":{"type":"string","nullable":true},"selected_locale":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"avatar_url":{"type":"string","nullable":true},"roles":{"type":"array","items":{"$ref":"#/components/schemas/AdminUserRoleAssignment"}},"stores":{"type":"array","items":{"$ref":"#/components/schemas/AdminUserStore"}}},"required":["id","email","first_name","last_name","full_name","selected_locale","created_at","updated_at","avatar_url","roles","stores"],"x-typelizer":true},"AllowedOrigin":{"type":"object","properties":{"id":{"type":"string"},"origin":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","origin","created_at","updated_at"],"x-typelizer":true},"ApiKey":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"key_type":{"type":"string","enum":["publishable","secret"]},"token_prefix":{"type":"string","nullable":true},"scopes":{"type":"array","items":{"type":"string"}},"created_at":{"type":"string"},"updated_at":{"type":"string"},"revoked_at":{"type":"string","nullable":true},"last_used_at":{"type":"string","nullable":true},"channel_id":{"type":"string","nullable":true},"plaintext_token":{"type":"string","nullable":true},"created_by_email":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by_label":{"type":"string","nullable":true}},"required":["id","name","key_type","token_prefix","scopes","created_at","updated_at","revoked_at","last_used_at","channel_id","plaintext_token","created_by_email","created_by_type","created_by_label"],"x-typelizer":true},"AppliedPromotion":{"type":"object","properties":{"id":{"type":"string"},"promotion_id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"code":{"type":"string","nullable":true},"amount":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","promotion_id","name","description","code","amount","created_at","updated_at"],"x-typelizer":true},"Cart":{"type":"object","properties":{"id":{"type":"string"},"market_id":{"type":"string","nullable":true},"channel_id":{"type":"string","nullable":true},"preferred_stock_location_id":{"type":"string","nullable":true},"company_id":{"type":"string","nullable":true},"company_name":{"type":"string","nullable":true},"po_number_required":{"type":"boolean"},"po_document_filename":{"type":"string","nullable":true},"po_document_byte_size":{"type":"number","nullable":true},"number":{"type":"string","deprecated":true},"token":{"type":"string"},"email":{"type":"string","nullable":true},"customer_note":{"type":"string","nullable":true},"po_number":{"type":"string","nullable":true},"currency":{"type":"string"},"locale":{"type":"string","nullable":true},"total_quantity":{"type":"number"},"warnings":{"type":"array","items":{"$ref":"#/components/schemas/CartWarning"}},"coupon_code":{"type":"string","nullable":true},"item_total":{"type":"string","nullable":true},"adjustment_total":{"type":"string","nullable":true},"discount_total":{"type":"string","nullable":true},"tax_total":{"type":"string","nullable":true},"included_tax_total":{"type":"string","nullable":true},"additional_tax_total":{"type":"string","nullable":true},"total":{"type":"string","nullable":true},"gift_card_total":{"type":"string","nullable":true},"amount_due":{"type":"string","nullable":true},"delivery_total":{"type":"string","nullable":true},"fee_total":{"type":"string","nullable":true},"store_credit_total":{"type":"string","nullable":true},"covered_by_store_credit":{"type":"boolean"},"current_step":{"type":"string"},"completed_steps":{"type":"array","items":{"type":"string"}},"requirements":{"type":"array","items":{"$ref":"#/components/schemas/CheckoutRequirement"}},"order_minimum":{"type":"string","nullable":true},"order_minimum_shortfall":{"type":"string","nullable":true},"below_order_minimum":{"type":"boolean","nullable":true},"freight_summary":{"allOf":[{"$ref":"#/components/schemas/FreightSummary"}],"nullable":true},"shipping_eq_billing_address":{"type":"boolean"},"items":{"type":"array","items":{"$ref":"#/components/schemas/LineItem"}},"billing_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"shipping_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"market":{"allOf":[{"$ref":"#/components/schemas/Market"}],"nullable":true},"completed_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"applied_promotions":{"type":"array","items":{"$ref":"#/components/schemas/AppliedPromotion"}}},"required":["id","market_id","channel_id","preferred_stock_location_id","company_id","company_name","po_number_required","po_document_filename","po_document_byte_size","number","token","email","customer_note","po_number","currency","locale","total_quantity","warnings","coupon_code","item_total","adjustment_total","discount_total","tax_total","included_tax_total","additional_tax_total","total","gift_card_total","amount_due","delivery_total","fee_total","store_credit_total","covered_by_store_credit","current_step","completed_steps","requirements","order_minimum","order_minimum_shortfall","below_order_minimum","freight_summary","shipping_eq_billing_address","items","billing_address","shipping_address","market","completed_at","created_at","updated_at","applied_promotions"],"x-typelizer":true},"CatalogAssignment":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"catalog_id":{"type":"string"},"assignable_type":{"type":"string"},"assignable_id":{"type":"string"},"assignable_name":{"type":"string","nullable":true}},"required":["id","created_at","catalog_id","assignable_type","assignable_id","assignable_name"],"x-typelizer":true},"CatalogOrderMinimum":{"type":"object","properties":{"id":{"type":"string"},"currency":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount":{"type":"string"}},"required":["id","currency","created_at","updated_at","amount"],"x-typelizer":true},"CatalogPrice":{"type":"object","properties":{"id":{"type":"string","nullable":true},"label":{"type":"string","nullable":true},"sku":{"type":"string","nullable":true},"currency":{"type":"string"},"source":{"type":"string","enum":["explicit","automatic","base"]},"break_count":{"type":"number"},"amount":{"type":"string"},"tiers":{"type":"array","items":{"$ref":"#/components/schemas/CatalogPriceTier"}}},"required":["id","label","sku","currency","source","break_count","amount","tiers"],"x-typelizer":true},"CatalogPriceTier":{"type":"object","properties":{"min_quantity":{"type":"number"},"amount":{"type":"string"}},"required":["min_quantity","amount"],"x-typelizer":true},"CatalogProduct":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"thumbnail_url":{"type":"string","nullable":true},"quantity_rule":{"allOf":[{"$ref":"#/components/schemas/CatalogProductTerm"}],"nullable":true},"catalog_variants":{"type":"array","items":{"$ref":"#/components/schemas/CatalogPrice"}}},"required":["id","name","thumbnail_url"],"x-typelizer":true},"CatalogProductTerm":{"type":"object","properties":{"id":{"type":"string"},"product_id":{"type":"string"},"product_name":{"type":"string","nullable":true},"minimum_order_quantity":{"type":"number","nullable":true},"order_multiple":{"type":"number","nullable":true},"mixed":{"type":"boolean"}},"required":["id","product_id","product_name","minimum_order_quantity","order_multiple","mixed"],"x-typelizer":true},"CatalogQuantityRule":{"type":"object","properties":{"id":{"type":"string"},"minimum_order_quantity":{"type":"number","nullable":true},"order_multiple":{"type":"number","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"variant_id":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"product_name":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true}},"required":["id","minimum_order_quantity","order_multiple","created_at","updated_at","variant_id","variant_sku","product_name","options_text"],"x-typelizer":true},"Catalog":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"active":{"type":"boolean"},"position":{"type":"number","nullable":true},"metadata":{"type":"object","nullable":true},"minimum_order_quantity":{"type":"number","nullable":true},"order_multiple":{"type":"number","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"products_count":{"type":"number"},"pricing_strategy":{"type":"string"},"order_minimums":{"type":"array","items":{"$ref":"#/components/schemas/CatalogOrderMinimum"}},"price_list":{"$ref":"#/components/schemas/PriceList"},"assignments":{"type":"array","items":{"$ref":"#/components/schemas/CatalogAssignment"}}},"required":["id","name","description","active","position","metadata","minimum_order_quantity","order_multiple","created_at","updated_at","products_count","pricing_strategy"],"x-typelizer":true},"Category":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"permalink":{"type":"string"},"position":{"type":"number"},"depth":{"type":"number"},"meta_title":{"type":"string","nullable":true},"meta_description":{"type":"string","nullable":true},"meta_keywords":{"type":"string","nullable":true},"children_count":{"type":"number"},"parent_id":{"type":"string","nullable":true},"description":{"type":"string"},"description_html":{"type":"string"},"image_url":{"type":"string","nullable":true},"square_image_url":{"type":"string","nullable":true},"is_root":{"type":"boolean"},"is_child":{"type":"boolean"},"is_leaf":{"type":"boolean"},"parent":{"$ref":"#/components/schemas/Category"},"children":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"ancestors":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"external_references":{"type":"object"},"translations":{"type":"object"},"metadata":{"type":"object"},"pretty_name":{"type":"string"},"lft":{"type":"number"},"rgt":{"type":"number"},"products_count":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","permalink","position","depth","meta_title","meta_description","meta_keywords","children_count","parent_id","description","description_html","image_url","square_image_url","is_root","is_child","is_leaf","external_references","metadata","pretty_name","lft","rgt","products_count","created_at","updated_at"],"x-typelizer":true},"Channel":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"code":{"type":"string"},"active":{"type":"boolean"},"default":{"type":"boolean"},"storefront_access":{"type":"string","nullable":true,"enum":["public","prices_hidden","login_required"]},"guest_checkout":{"type":"boolean","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"order_routing_strategy":{"type":"string","nullable":true,"description":"Order routing strategy; null inherits the store setting. Built-in: rules. Extensions may register more."},"stock_location_ids":{"type":"array","items":{"type":"string"}},"default_catalog_id":{"type":"string","nullable":true}},"required":["id","name","code","active","default","storefront_access","guest_checkout","created_at","updated_at","order_routing_strategy","stock_location_ids","default_catalog_id"],"x-typelizer":true},"ClaimLineItem":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"send_replacement":{"type":"boolean"},"description":{"type":"string","nullable":true},"refund_amount":{"type":"string"},"paid_amount":{"type":"string"},"pre_tax_amount":{"type":"string"},"included_tax_total":{"type":"string"},"additional_tax_total":{"type":"string"},"tax_total":{"type":"string"},"variant_id":{"type":"string","nullable":true},"replacement_variant_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"variant":{"$ref":"#/components/schemas/Variant"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"replacement_variant":{"$ref":"#/components/schemas/Variant"}},"required":["id","quantity","send_replacement","description","refund_amount","paid_amount","pre_tax_amount","included_tax_total","additional_tax_total","tax_total","variant_id","replacement_variant_id","line_item_id","created_at","updated_at"],"x-typelizer":true},"ClaimReason":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"can_be_deleted":{"type":"boolean"}},"required":["id","name","active","created_at","updated_at","can_be_deleted"],"x-typelizer":true},"Claim":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["open","approved","resolved","denied","canceled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"resolution":{"type":"string","nullable":true},"order_id":{"type":"string","nullable":true},"reason_id":{"type":"string","nullable":true},"refund_total":{"type":"string"},"approved_at":{"type":"string","nullable":true},"resolved_at":{"type":"string","nullable":true},"denied_at":{"type":"string","nullable":true},"canceled_at":{"type":"string","nullable":true},"reason":{"$ref":"#/components/schemas/ClaimReason"},"claim_line_items":{"type":"array","items":{"$ref":"#/components/schemas/ClaimLineItem"}},"memo":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"created_by_id":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by":{"$ref":"#/components/schemas/Actor"},"order":{"$ref":"#/components/schemas/Order"},"refunds":{"type":"array","items":{"$ref":"#/components/schemas/Refund"}}},"required":["id","number","status","resolution","order_id","reason_id","refund_total","approved_at","resolved_at","denied_at","canceled_at","memo","metadata","created_at","updated_at","created_by_id","created_by_type"],"x-typelizer":true},"CollectionRule":{"type":"object","properties":{"id":{"type":"string"},"value":{"type":"string","nullable":true},"match_policy":{"type":"string","enum":["is_equal_to","is_not_equal_to","contains","does_not_contain"]},"type":{"type":"string","description":"Rule type. Built-in: tag, available_on, sale. Extensions may register more."}},"required":["id","value","match_policy","type"],"x-typelizer":true},"Collection":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"permalink":{"type":"string"},"position":{"type":"number"},"sort_order":{"type":"string"},"meta_title":{"type":"string","nullable":true},"meta_description":{"type":"string","nullable":true},"meta_keywords":{"type":"string","nullable":true},"products_count":{"type":"number"},"description":{"type":"string"},"description_html":{"type":"string"},"image_url":{"type":"string","nullable":true},"square_image_url":{"type":"string","nullable":true},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"translations":{"type":"object"},"automatic":{"type":"boolean"},"rules_match_policy":{"type":"string","enum":["all","any"]},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CollectionRule"}}},"required":["id","name","permalink","position","sort_order","meta_title","meta_description","meta_keywords","products_count","description","description_html","image_url","square_image_url","automatic","rules_match_policy","metadata","created_at","updated_at"],"x-typelizer":true},"CommissionLine":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["percentage","fixed"]},"currency":{"type":"string"},"taxability_reason":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"rate":{"type":"string"},"tax_rate":{"type":"string"},"amount":{"type":"string"},"tax_amount":{"type":"string"},"total":{"type":"string"},"order_id":{"type":"string"},"seller_id":{"type":"string"},"line_item_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"commission_rate_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"commission_rate":{"$ref":"#/components/schemas/CommissionRate"}},"required":["id","kind","currency","taxability_reason","country_code","state_code","created_at","updated_at","rate","tax_rate","amount","tax_amount","total","order_id","seller_id","line_item_id","fulfillment_id","commission_rate_id","seller_name"],"x-typelizer":true},"CommissionRate":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"code":{"type":"string","nullable":true},"enabled":{"type":"boolean"},"position":{"type":"number"},"kind":{"type":"string","enum":["percentage","fixed"]},"tax_inclusive":{"type":"boolean"},"include_shipping":{"type":"boolean"},"metadata":{"type":"object","nullable":true},"deleted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"value":{"type":"string"},"commission_tax_rate":{"type":"string","nullable":true},"amounts":{"type":"object"},"bounds":{"type":"object"},"global":{"type":"boolean"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CommissionRule"}}},"required":["id","name","code","enabled","position","kind","tax_inclusive","include_shipping","metadata","deleted_at","created_at","updated_at","value","commission_tax_rate","amounts","bounds","global","rules"],"x-typelizer":true},"CommissionRule":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: seller_rule, category_rule, product_rule, item_total_rule. Extensions may register more."},"commission_rate_id":{"type":"string"},"preferences":{"$ref":"#/components/schemas/CommissionRulePreferences"},"product_ids":{"type":"array","items":{"type":"string"},"nullable":true},"seller_ids":{"type":"array","items":{"type":"string"},"nullable":true},"category_ids":{"type":"array","items":{"type":"string"},"nullable":true},"sellers":{"type":"array","items":{"$ref":"#/components/schemas/Seller"}},"categories":{"type":"array","items":{"$ref":"#/components/schemas/Category"}}},"required":["id","created_at","updated_at","type","commission_rate_id","preferences","product_ids","seller_ids","category_ids"],"x-typelizer":true},"CompanyInvitation":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"expires_at":{"type":"string","nullable":true},"company_id":{"type":"string"},"status":{"type":"string","enum":["pending","accepted","revoked","expired"]},"accepted_at":{"type":"string","nullable":true},"revoked_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","email","expires_at","company_id","status","accepted_at","revoked_at","created_at","updated_at"],"x-typelizer":true},"CompanyMembership":{"type":"object","properties":{"id":{"type":"string"},"company_id":{"type":"string"},"customer_id":{"type":"string"},"email":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","company_id","customer_id","email","created_at","updated_at"],"x-typelizer":true},"Company":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"kind":{"type":"string","enum":["company","division"]},"po_number_required":{"type":"boolean"},"parent_id":{"type":"string","nullable":true},"ancestors":{"type":"array","items":{"type":"object"}},"external_references":{"type":"object"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"children_count":{"type":"number"},"members_count":{"type":"number"},"children":{"type":"array","items":{"$ref":"#/components/schemas/Company"}},"addresses":{"type":"array","items":{"$ref":"#/components/schemas/Address"}},"memberships":{"type":"array","items":{"$ref":"#/components/schemas/CompanyMembership"}}},"required":["id","name","kind","po_number_required","parent_id","ancestors","external_references","metadata","created_at","updated_at","children_count","members_count"],"x-typelizer":true},"ConsentRecord":{"type":"object","properties":{"id":{"type":"string"},"purpose":{"type":"string"},"source":{"type":"string","enum":["checkout","registration","account","admin","newsletter","anonymization","unknown","import","storefront"]},"accepted":{"type":"boolean"},"email":{"type":"string","nullable":true},"ip_address":{"type":"string","nullable":true},"created_at":{"type":"string"},"recorded_at":{"type":"string","nullable":true},"documents":{"type":"array","items":{"type":"object"}}},"required":["id","purpose","source","accepted","email","ip_address","created_at","recorded_at","documents"],"x-typelizer":true},"Country":{"type":"object","properties":{"iso":{"type":"string"},"iso3":{"type":"string"},"name":{"type":"string"},"states_required":{"type":"boolean"},"zipcode_required":{"type":"boolean"},"states":{"type":"array","items":{"$ref":"#/components/schemas/State"}},"market":{"allOf":[{"$ref":"#/components/schemas/Market"}],"nullable":true}},"required":["iso","iso3","name","states_required","zipcode_required"],"x-typelizer":true},"CouponCode":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"state":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"promotion_id":{"type":"string"},"order_id":{"type":"string","nullable":true}},"required":["id","code","state","created_at","updated_at","promotion_id","order_id"],"x-typelizer":true},"CreditCard":{"type":"object","properties":{"id":{"type":"string"},"brand":{"type":"string"},"last4":{"type":"string"},"month":{"type":"number"},"year":{"type":"number"},"name":{"type":"string","nullable":true},"default":{"type":"boolean"},"gateway_payment_profile_id":{"type":"string","nullable":true},"customer_id":{"type":"string","nullable":true},"payment_method_id":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","brand","last4","month","year","name","default","gateway_payment_profile_id","customer_id","payment_method_id","metadata","created_at","updated_at"],"x-typelizer":true},"CustomFieldDefinition":{"type":"object","properties":{"id":{"type":"string"},"namespace":{"type":"string"},"key":{"type":"string"},"label":{"type":"string"},"field_type":{"type":"string","enum":["short_text","long_text","rich_text","number","boolean","json"]},"storefront_visible":{"type":"boolean"},"searchable":{"type":"boolean"},"sortable":{"type":"boolean"},"filter_key":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"resource_type":{"type":"string","description":"Shorthand of the resource the field attaches to, for example product, variant, order, customer or category. Discover the full list from the resource_types endpoint; extensions may register more."}},"required":["id","namespace","key","label","field_type","storefront_visible","searchable","sortable","filter_key","created_at","updated_at","resource_type"],"x-typelizer":true},"CustomField":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"field_type":{"type":"string","enum":["short_text","long_text","rich_text","number","boolean","json"]},"key":{"type":"string"},"value":{},"created_at":{"type":"string"},"updated_at":{"type":"string"},"storefront_visible":{"type":"boolean"},"custom_field_definition_id":{"type":"string"}},"required":["id","label","field_type","key","value","created_at","updated_at","storefront_visible","custom_field_definition_id"],"x-typelizer":true},"CustomerGroup":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"customers_count":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"customers":{"type":"array","items":{"$ref":"#/components/schemas/Customer"}}},"required":["id","name","description","customers_count","created_at","updated_at"],"x-typelizer":true},"Customer":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"first_name":{"type":"string","nullable":true},"last_name":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"accepts_email_marketing":{"type":"boolean"},"email_marketing_consent_updated_at":{"type":"string","nullable":true},"full_name":{"type":"string"},"available_store_credit_total":{"type":"string"},"addresses":{"type":"array","items":{"$ref":"#/components/schemas/Address"}},"default_billing_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"default_shipping_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"newsletter_subscriber":{"allOf":[{"$ref":"#/components/schemas/NewsletterSubscriber"}],"nullable":true},"customer_groups":{"type":"array","items":{"$ref":"#/components/schemas/CustomerGroup"}},"failed_attempts":{"type":"number"},"metadata":{"type":"object"},"email_marketing_consent_source":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"anonymized_at":{"type":"string","nullable":true},"anonymized":{"type":"boolean"},"tags":{"type":"array","items":{"type":"string"}},"internal_note":{"type":"string","nullable":true},"internal_note_html":{"type":"string","nullable":true},"default_billing_address_id":{"type":"string","nullable":true},"default_shipping_address_id":{"type":"string","nullable":true},"orders_count":{"type":"number"},"total_spent":{"type":"string"},"last_order_completed_at":{"type":"string","nullable":true},"orders":{"type":"array","items":{"$ref":"#/components/schemas/Order"}},"store_credits":{"type":"array","items":{"$ref":"#/components/schemas/StoreCredit"}},"customer_group_ids":{"type":"array","items":{"type":"string"}},"companies":{"type":"array","items":{"$ref":"#/components/schemas/Company"}}},"required":["id","email","first_name","last_name","phone","accepts_email_marketing","email_marketing_consent_updated_at","full_name","available_store_credit_total","failed_attempts","metadata","email_marketing_consent_source","created_at","updated_at","anonymized_at","anonymized","tags","internal_note","internal_note_html","default_billing_address_id","default_shipping_address_id","orders_count","total_spent","last_order_completed_at","customer_group_ids"],"x-typelizer":true},"DashboardCounter":{"type":"object","properties":{"key":{"type":"string","description":"Registered counter name. The dashboard translates it; built-in: orders_to_fulfill, payments_to_collect, open_returns, open_exchanges, open_claims, low_stock_items, out_of_stock_items."},"value":{"type":"number"},"link":{"type":"object","nullable":true,"description":"The list filter that shows exactly the rows counted, or null when no list can."},"nav":{"type":"string","nullable":true,"description":"Sidebar entry key this count badges, or null."}},"required":["key","value","link","nav"],"x-typelizer":true},"DataRequest":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"kind":{"type":"string","enum":["access","erasure"]},"status":{"anyOf":[{"type":"string","enum":["pending","processing","completed","failed"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"requested_at":{"type":"string","nullable":true},"completed_at":{"type":"string","nullable":true},"expires_at":{"type":"string","nullable":true},"email":{"type":"string"},"error_message":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"customer_id":{"type":"string","nullable":true},"requested_by_id":{"type":"string","nullable":true},"customer":{"$ref":"#/components/schemas/Customer"}},"required":["id","number","kind","status","requested_at","completed_at","expires_at","email","error_message","created_at","updated_at","customer_id","requested_by_id"],"x-typelizer":true},"DeliveryMethodRule":{"type":"object","properties":{"id":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: item_total_rule, weight_rule, excluded_products_rule, channel_rule, volume_rule, company_rule. Extensions may register more."},"preferences":{"$ref":"#/components/schemas/DeliveryMethodRulePreferences"},"product_ids":{"type":"array","items":{"type":"string"}}},"required":["id","active","created_at","updated_at","type","preferences","product_ids"],"x-typelizer":true},"DeliveryMethod":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"code":{"type":"string","nullable":true},"estimated_transit_business_days_min":{"type":"number","nullable":true},"estimated_transit_business_days_max":{"type":"number","nullable":true},"digital":{"type":"boolean"},"pickup":{"type":"boolean"},"pickup_point":{"type":"boolean"},"admin_name":{"type":"string","nullable":true},"storefront_visible":{"type":"boolean"},"tracking_url":{"type":"string","nullable":true},"available_to_sellers":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"deleted_at":{"type":"string"},"markup_flat":{"type":"string","nullable":true},"markup_percent":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"services":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryMethodService"}},"rules":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryMethodRule"}},"tax_category_id":{"type":"string","nullable":true},"delivery_profile_id":{"type":"string"},"delivery_origin_group_id":{"type":"string","nullable":true},"delivery_zone_id":{"type":"string","nullable":true},"stock_location_ids":{"type":"array","items":{"type":"string"}},"fulfillment_provider":{"type":"string","description":"Fulfillment provider. Built-in: manual, digital, pickup, pickup_point. Provider gems register more (e.g. easy_post)."},"pickup_point_provider":{"type":"string","nullable":true,"description":"Pickup point network. None built in; provider gems register them."},"rate_provider":{"type":"string","nullable":true,"description":"Rate provider; null prices through the calculator. Built-in: internal, freight. Provider gems register more (e.g. easy_post)."},"calculator":{"allOf":[{"$ref":"#/components/schemas/DeliveryMethodCalculator"}],"nullable":true}},"required":["id","name","code","estimated_transit_business_days_min","estimated_transit_business_days_max","digital","pickup","pickup_point","admin_name","storefront_visible","tracking_url","available_to_sellers","created_at","updated_at","deleted_at","markup_flat","markup_percent","seller_id","seller_name","services","rules","tax_category_id","delivery_profile_id","delivery_origin_group_id","delivery_zone_id","stock_location_ids","fulfillment_provider","pickup_point_provider","rate_provider","calculator"],"x-typelizer":true},"DeliveryMethodService":{"type":"object","properties":{"id":{"type":"string"},"carrier":{"type":"string"},"service":{"type":"string"},"label":{"type":"string","nullable":true},"markup_flat":{"type":"string","nullable":true},"markup_percent":{"type":"string","nullable":true},"position":{"type":"number"}},"required":["id","carrier","service","label","markup_flat","markup_percent","position"],"x-typelizer":true},"DeliveryOriginGroup":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string","nullable":true},"position":{"type":"number","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivery_profile_id":{"type":"string"},"stock_location_ids":{"type":"array","items":{"type":"string"}},"delivery_zones_count":{"type":"number"},"delivery_methods_count":{"type":"number"}},"required":["id","name","position","created_at","updated_at","delivery_profile_id","stock_location_ids","delivery_zones_count","delivery_methods_count"],"x-typelizer":true},"DeliveryProfile":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"default":{"type":"boolean"},"position":{"type":"number","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"kind":{"type":"string","description":"Profile kind. Built-in: shipping, digital. Extensions may register more."},"digital":{"type":"boolean"},"offers_pickup":{"type":"boolean"},"offers_shipping":{"type":"boolean"},"stock_location_ids":{"type":"array","items":{"type":"string"}},"origin_groups":{"type":"array","items":{"type":"object"}},"products_count":{"type":"number"},"delivery_methods_count":{"type":"number"},"delivery_zones_count":{"type":"number"}},"required":["id","name","default","position","created_at","updated_at","kind","digital","offers_pickup","offers_shipping","stock_location_ids","origin_groups","products_count","delivery_methods_count","delivery_zones_count"],"x-typelizer":true},"DeliveryRate":{"type":"object","properties":{"id":{"type":"string"},"delivery_method_id":{"type":"string"},"name":{"type":"string"},"selected":{"type":"boolean"},"cost":{"type":"string"},"total":{"type":"string"},"additional_tax_total":{"type":"string"},"included_tax_total":{"type":"string"},"tax_total":{"type":"string"},"carrier":{"type":"string","nullable":true},"service_level":{"type":"string","nullable":true},"estimated_delivery_date":{"type":"string","nullable":true},"unpriced":{"type":"boolean"},"freight_summary":{"allOf":[{"$ref":"#/components/schemas/FreightSummary"}],"nullable":true},"delivery_method":{"$ref":"#/components/schemas/DeliveryMethod"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","delivery_method_id","name","selected","cost","total","additional_tax_total","included_tax_total","tax_total","carrier","service_level","estimated_delivery_date","unpriced","freight_summary","metadata","created_at","updated_at"],"x-typelizer":true},"Delivery":{"type":"object","properties":{"id":{"type":"string"},"tracking_number":{"type":"string"},"carrier":{"type":"string","nullable":true},"carrier_name":{"type":"string","nullable":true},"service":{"type":"string","nullable":true},"status":{"type":"string","enum":["pending","pre_transit","in_transit","out_for_delivery","available_for_pickup","delivered","return_to_sender","failure","unknown"]},"tracking_url":{"type":"string","nullable":true},"estimated_delivery_at":{"type":"string","nullable":true},"delivered_at":{"type":"string","nullable":true},"details":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"shipping_label_id":{"type":"string","nullable":true}},"required":["id","tracking_number","carrier","carrier_name","service","status","tracking_url","estimated_delivery_at","delivered_at","details","created_at","updated_at","shipping_label_id"],"x-typelizer":true},"DeliveryZoneMember":{"type":"object","properties":{"id":{"type":"string"},"member_type":{"type":"string","enum":["country","state","postal_code"]},"country_code":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"postal_code_prefix":{"type":"string","nullable":true},"postal_code_from":{"type":"string","nullable":true},"postal_code_to":{"type":"string","nullable":true},"country_name":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","member_type","country_code","state_code","postal_code_prefix","postal_code_from","postal_code_to","country_name","state_name","created_at","updated_at"],"x-typelizer":true},"DeliveryZone":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"members":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryZoneMember"}},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivery_profile_id":{"type":"string"},"delivery_origin_group_id":{"type":"string","nullable":true},"delivery_method_ids":{"type":"array","items":{"type":"string"}}},"required":["id","name","description","created_at","updated_at","delivery_profile_id","delivery_origin_group_id","delivery_method_ids"],"x-typelizer":true},"DigitalAsset":{"type":"object","properties":{"id":{"type":"string"},"variant_id":{"type":"string","nullable":true},"filename":{"type":"string","nullable":true},"content_type":{"type":"string","nullable":true},"authorized_clicks":{"type":"number","nullable":true},"authorized_days":{"type":"number","nullable":true},"byte_size":{"type":"number","nullable":true},"provider_settings":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"provider_type":{"type":"string","nullable":true,"description":"Digital asset provider; null is an uploaded file. Built-in: file. Extensions may register more."},"provider_name":{"type":"string","description":"Digital asset provider name. Built-in: File. Extensions may register more."},"download_url":{"type":"string","nullable":true},"effective_authorized_clicks":{"type":"number"},"effective_authorized_days":{"type":"number"}},"required":["id","variant_id","filename","content_type","authorized_clicks","authorized_days","byte_size","provider_settings","created_at","updated_at","provider_type","provider_name","download_url","effective_authorized_clicks","effective_authorized_days"],"x-typelizer":true},"DigitalLink":{"type":"object","properties":{"id":{"type":"string"},"access_counter":{"type":"number"},"filename":{"type":"string"},"content_type":{"type":"string"},"download_url":{"type":"string"},"expires_at":{"type":"string","nullable":true},"authorizable":{"type":"boolean"},"expired":{"type":"boolean"},"access_limit_exceeded":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","access_counter","filename","content_type","download_url","expires_at","authorizable","expired","access_limit_exceeded","created_at","updated_at"],"x-typelizer":true},"Discount":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"kind":{"type":"string","enum":["promotion","manual"]},"code":{"type":"string","nullable":true},"value_type":{"type":"string","nullable":true},"value":{"type":"string","nullable":true},"promotion_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"amount":{"type":"string"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","label","kind","code","value_type","value","promotion_id","line_item_id","fulfillment_id","amount","metadata","created_at","updated_at"],"x-typelizer":true},"EmailTemplateDraft":{"type":"object","properties":{"id":{"type":"string"},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"lock_version":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"updated_by_id":{"type":"string","nullable":true},"updated_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"updated_by":{"$ref":"#/components/schemas/Actor"}},"required":["id","subject","body","lock_version","created_at","updated_at","updated_by_id","updated_by_type"],"x-typelizer":true},"EmailTemplatePreview":{"type":"object","properties":{"id":{"type":"string","nullable":true},"subject":{"type":"string"},"html":{"type":"string"},"text":{"type":"string"},"email_key":{"type":"string"},"variables":{"type":"object"}},"required":["id","subject","html","text","email_key","variables"],"x-typelizer":true},"EmailTemplateRevision":{"type":"object","properties":{"id":{"type":"string"},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"created_at":{"type":"string"},"published_by_id":{"type":"string","nullable":true},"published_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"published_by":{"$ref":"#/components/schemas/Actor"}},"required":["id","subject","body","created_at","published_by_id","published_by_type"],"x-typelizer":true},"EmailTemplateSampleRecord":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"created_at":{"type":"string"}},"required":["id","label","created_at"],"x-typelizer":true},"EmailTemplate":{"type":"object","properties":{"id":{"type":"string"},"key":{"type":"string"},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"language":{"type":"string"},"customized_languages":{"type":"array","items":{"type":"string"}},"kind":{"type":"string","enum":["email","layout","partial"]},"customized":{"type":"boolean"},"published_at":{"type":"string","nullable":true},"default_subject":{"type":"string","nullable":true},"default_body":{"type":"string"},"published_language":{"type":"string","nullable":true},"default_changed":{"type":"boolean"},"base_subject":{"type":"string","nullable":true},"base_body":{"type":"string","nullable":true},"draft":{"allOf":[{"$ref":"#/components/schemas/EmailTemplateDraft"}],"nullable":true}},"required":["id","key","subject","body","language","customized_languages","kind","customized","published_at","default_subject","default_body","published_language","default_changed","base_subject","base_body","draft"],"x-typelizer":true},"ExchangeLineItem":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"received_quantity":{"type":"number"},"resellable":{"type":"boolean"},"original_price":{"type":"string"},"new_variant_price":{"type":"string"},"price_difference":{"type":"string"},"original_tax_total":{"type":"string"},"new_tax_total":{"type":"string"},"original_variant_id":{"type":"string","nullable":true},"new_variant_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"fulfillment_item_id":{"type":"string","nullable":true},"original_variant":{"$ref":"#/components/schemas/Variant"},"new_variant":{"$ref":"#/components/schemas/Variant"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","quantity","received_quantity","resellable","original_price","new_variant_price","price_difference","original_tax_total","new_tax_total","original_variant_id","new_variant_id","line_item_id","fulfillment_item_id","created_at","updated_at"],"x-typelizer":true},"Exchange":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["requested","approved","received","fulfilled","canceled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"order_id":{"type":"string","nullable":true},"reason_id":{"type":"string","nullable":true},"price_difference":{"type":"string"},"approved_at":{"type":"string","nullable":true},"received_at":{"type":"string","nullable":true},"fulfilled_at":{"type":"string","nullable":true},"canceled_at":{"type":"string","nullable":true},"reason":{"$ref":"#/components/schemas/ReturnReason"},"exchange_line_items":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeLineItem"}},"memo":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_location_id":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by":{"$ref":"#/components/schemas/Actor"},"order":{"$ref":"#/components/schemas/Order"},"stock_location":{"$ref":"#/components/schemas/StockLocation"},"refunds":{"type":"array","items":{"$ref":"#/components/schemas/Refund"}}},"required":["id","number","status","order_id","reason_id","price_difference","approved_at","received_at","fulfilled_at","canceled_at","memo","metadata","created_at","updated_at","stock_location_id","created_by_id","created_by_type"],"x-typelizer":true},"Export":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"format":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","nullable":true},"user_id":{"type":"string","nullable":true},"done":{"type":"boolean"},"store_id":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"filename":{"type":"string","nullable":true},"byte_size":{"type":"number","nullable":true},"download_url":{"type":"string","nullable":true}},"required":["id","number","format","created_at","updated_at","type","user_id","done","store_id","seller_id","seller_name","filename","byte_size","download_url"],"x-typelizer":true},"Fee":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"kind":{"anyOf":[{"type":"string","enum":["surcharge","handling","gift_wrap","cod","payment","duty","exchange"]},{"type":"string"}],"description":"What sort of charge this is. `duty` is a customs duty on a cross-border order and is not taxed; the other kinds are. Extensions may register further kinds."},"line_item_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"amount":{"type":"string"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","label","kind","line_item_id","fulfillment_id","amount","metadata","created_at","updated_at"],"x-typelizer":true},"FileUpload":{"type":"object","properties":{"signed_id":{"type":"string"},"filename":{"type":"string"},"content_type":{"type":"string"},"byte_size":{"type":"number"},"visibility":{"type":"string","enum":["public","private"]},"expires_at":{"type":"string"},"upload":{"allOf":[{"$ref":"#/components/schemas/FileUploadTarget"}],"nullable":true}},"required":["signed_id","filename","content_type","byte_size","visibility","expires_at","upload"],"x-typelizer":true},"FileUploadTarget":{"type":"object","properties":{"method":{"type":"string"},"url":{"type":"string"},"headers":{"type":"object"}},"required":["method","url","headers"],"x-typelizer":true},"FreightSummaryLine":{"type":"object","properties":{"variant_id":{"type":"string","nullable":true},"sku":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"units":{"type":"number"},"cartons":{"type":"number","nullable":true},"pallets":{"type":"number","nullable":true},"units_per_carton":{"type":"number","nullable":true},"cartons_per_pallet":{"type":"number","nullable":true},"complete":{"type":"boolean"},"weight_per_carton":{"type":"string","nullable":true},"volume":{"type":"string"},"weight":{"type":"string"}},"required":["variant_id","sku","name","units","cartons","pallets","units_per_carton","cartons_per_pallet","complete","weight_per_carton","volume","weight"],"x-typelizer":true},"FreightSummary":{"type":"object","properties":{"total_units":{"type":"number"},"total_cartons":{"type":"number"},"total_pallets":{"type":"number","nullable":true},"total_volume":{"type":"string"},"total_weight":{"type":"string"},"complete":{"type":"boolean"},"lines":{"type":"array","items":{"$ref":"#/components/schemas/FreightSummaryLine"}}},"required":["total_units","total_cartons","total_pallets","total_volume","total_weight","complete","lines"],"x-typelizer":true},"FulfillmentItem":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"status":{"anyOf":[{"type":"string","enum":["on_hand","backordered","shipped","returned"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"variant_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true}},"required":["id","quantity","status","variant_id","line_item_id","name","options_text"],"x-typelizer":true},"Fulfillment":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"tracking":{"type":"string","nullable":true},"tracking_url":{"type":"string","nullable":true},"pickup_point_data":{"type":"object","nullable":true},"selected_delivery_rate_id":{"type":"string","nullable":true},"unpriced":{"type":"boolean"},"cost":{"type":"string"},"total":{"type":"string"},"discount_total":{"type":"string"},"additional_tax_total":{"type":"string"},"included_tax_total":{"type":"string"},"tax_total":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["unfulfilled","fulfilled","delivered","canceled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"fulfillment_type":{"type":"string","enum":["shipping","digital","pickup","pickup_point"]},"fulfilled_at":{"type":"string","nullable":true},"delivered_at":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/FulfillmentManifestItem"}},"deliveries":{"type":"array","items":{"$ref":"#/components/schemas/Delivery"}},"delivery_method":{"$ref":"#/components/schemas/DeliveryMethod"},"stock_location":{"$ref":"#/components/schemas/StockLocation"},"delivery_rates":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryRate"}},"tax_lines":{"type":"array","items":{"$ref":"#/components/schemas/TaxLine"}},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"adjustment_total":{"type":"string"},"pre_tax_amount":{"type":"string"},"order_id":{"type":"string","nullable":true},"stock_location_id":{"type":"string","nullable":true},"documents":{"type":"array","items":{"type":"object"}},"labels":{"type":"array","items":{"$ref":"#/components/schemas/ShippingLabel"}},"provider_generates_labels":{"type":"boolean"},"fulfillment_items":{"type":"array","items":{"$ref":"#/components/schemas/FulfillmentItem"}},"order":{"$ref":"#/components/schemas/Order"}},"required":["id","number","tracking","tracking_url","pickup_point_data","selected_delivery_rate_id","unpriced","cost","total","discount_total","additional_tax_total","included_tax_total","tax_total","status","fulfillment_type","fulfilled_at","delivered_at","items","deliveries","metadata","created_at","updated_at","adjustment_total","pre_tax_amount","order_id","stock_location_id","documents","labels","provider_generates_labels"],"x-typelizer":true},"GiftCardBatch":{"type":"object","properties":{"id":{"type":"string"},"codes_count":{"type":"number"},"currency":{"type":"string","nullable":true},"prefix":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount":{"type":"string","nullable":true},"expires_at":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true}},"required":["id","codes_count","currency","prefix","created_at","updated_at","amount","expires_at","created_by_id"],"x-typelizer":true},"GiftCard":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["active","partially_redeemed","redeemed","canceled","expired"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"currency":{"type":"string"},"amount":{"type":"string"},"amount_used":{"type":"string"},"amount_authorized":{"type":"string"},"amount_remaining":{"type":"string"},"expires_at":{"type":"string","nullable":true},"redeemed_at":{"type":"string","nullable":true},"expired":{"type":"boolean"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"customer_id":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true},"customer":{"$ref":"#/components/schemas/Customer"},"created_by":{"$ref":"#/components/schemas/AdminUser"},"gift_card_batch":{"$ref":"#/components/schemas/GiftCardBatch"},"orders":{"type":"array","items":{"$ref":"#/components/schemas/Order"}}},"required":["id","code","status","currency","amount","amount_used","amount_authorized","amount_remaining","expires_at","redeemed_at","expired","active","created_at","updated_at","customer_id","created_by_id"],"x-typelizer":true},"ImportMapping":{"type":"object","properties":{"id":{"type":"string"},"schema_field":{"type":"string"},"file_column":{"type":"string","nullable":true},"required":{"type":"boolean"}},"required":["id","schema_field","file_column","required"],"x-typelizer":true},"ImportRow":{"type":"object","properties":{"id":{"type":"string"},"row_number":{"type":"number"},"status":{"anyOf":[{"type":"string","enum":["pending","processing","completed","failed"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"validation_errors":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"import_id":{"type":"string","nullable":true},"item_type":{"type":"string","nullable":true},"item_id":{"type":"string","nullable":true},"data":{"type":"object"}},"required":["id","row_number","status","validation_errors","created_at","updated_at","import_id","item_type","item_id","data"],"x-typelizer":true},"Import":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"rows_count":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","nullable":true,"description":"Import type. Built-in: products, product_translations, customers, price_list_prices. Extensions may register more."},"status":{"anyOf":[{"type":"string","enum":["pending","mapping","completed_mapping","processing","completed","failed"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"store_id":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"owner_type":{"type":"string","nullable":true,"deprecated":true},"owner_id":{"type":"string","nullable":true,"deprecated":true},"user_id":{"type":"string","nullable":true},"processing_errors":{"type":"string","nullable":true},"delimiter":{"type":"string"},"price_list_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"original_filename":{"type":"string","nullable":true},"original_byte_size":{"type":"number","nullable":true},"original_file_url":{"type":"string","nullable":true},"completed_rows_count":{"type":"number"},"failed_rows_count":{"type":"number"},"schema_fields":{"type":"array","items":{"$ref":"#/components/schemas/ImportSchemaField"}},"csv_headers":{"type":"array","items":{"type":"string"}},"sample_row":{"type":"object"},"mappings":{"type":"array","items":{"$ref":"#/components/schemas/ImportMapping"}}},"required":["id","number","rows_count","created_at","updated_at","type","status","store_id","seller_id","owner_type","owner_id","user_id","processing_errors","delimiter","price_list_id","seller_name","original_filename","original_byte_size","original_file_url","completed_rows_count","failed_rows_count","schema_fields","csv_headers","sample_row","mappings"],"x-typelizer":true},"Integration":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Integration type, registered by the provider gem that owns it (for example the EasyPost provider). Core ships none."},"group":{"type":"string","nullable":true},"preferences":{"$ref":"#/components/schemas/IntegrationPreferences"}},"required":["id","name","active","created_at","updated_at","type","group","preferences"],"x-typelizer":true},"InvitationAcceptanceLink":{"type":"object","properties":{"id":{"type":"string"},"acceptance_url":{"type":"string"}},"required":["id","acceptance_url"],"x-typelizer":true},"Invitation":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","accepted"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"created_at":{"type":"string"},"updated_at":{"type":"string"},"expires_at":{"type":"string"},"role_id":{"type":"string"},"role_name":{"type":"string"},"inviter_email":{"type":"string"},"invitee_exists":{"type":"boolean"},"store":{"type":"object"}},"required":["id","email","status","created_at","updated_at","expires_at","role_id","role_name","inviter_email","invitee_exists","store"],"x-typelizer":true},"LineItem":{"type":"object","properties":{"id":{"type":"string"},"variant_id":{"type":"string"},"seller_id":{"type":"string","nullable":true},"preorder":{"type":"boolean"},"preorder_ships_at":{"type":"string","nullable":true},"quantity":{"type":"number"},"currency":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"options_text":{"type":"string"},"price":{"type":"string"},"total":{"type":"string"},"adjustment_total":{"type":"string"},"additional_tax_total":{"type":"string"},"included_tax_total":{"type":"string"},"discount_total":{"type":"string"},"pre_tax_amount":{"type":"string"},"discounted_amount":{"type":"string"},"compare_at_amount":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}},"digital_links":{"type":"array","items":{"$ref":"#/components/schemas/DigitalLink"}},"tax_lines":{"type":"array","items":{"$ref":"#/components/schemas/TaxLine"}},"metadata":{"type":"object"},"price_source":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"catalog_price":{"type":"string","nullable":true},"price_list_id":{"type":"string","nullable":true},"price_list_name":{"type":"string","nullable":true},"catalog_id":{"type":"string","nullable":true},"catalog_name":{"type":"string","nullable":true},"cost_price":{"type":"string","nullable":true},"tax_category_id":{"type":"string","nullable":true},"variant":{"$ref":"#/components/schemas/Variant"},"tax_category":{"$ref":"#/components/schemas/TaxCategory"}},"required":["id","variant_id","seller_id","preorder","preorder_ships_at","quantity","currency","name","slug","options_text","price","total","adjustment_total","additional_tax_total","included_tax_total","discount_total","pre_tax_amount","discounted_amount","compare_at_amount","thumbnail_url","option_values","digital_links","metadata","price_source","created_at","updated_at","catalog_price","price_list_id","price_list_name","catalog_id","catalog_name","cost_price","tax_category_id"],"x-typelizer":true},"Market":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"currency":{"type":"string"},"default_locale":{"type":"string"},"tax_inclusive":{"type":"boolean"},"default":{"type":"boolean"},"country_codes":{"type":"array","items":{"type":"string"}},"country_isos":{"type":"array","items":{"type":"string"},"deprecated":true},"supported_locales":{"type":"array","items":{"type":"string"}},"countries":{"type":"array","items":{"$ref":"#/components/schemas/Country"}},"created_at":{"type":"string"},"updated_at":{"type":"string"},"tax_provider":{"type":"string","nullable":true,"description":"Tax provider; null uses the store default. Built-in: internal. Provider gems register more."}},"required":["id","name","currency","default_locale","tax_inclusive","default","country_codes","country_isos","supported_locales","created_at","updated_at","tax_provider"],"x-typelizer":true},"Media":{"type":"object","properties":{"id":{"type":"string"},"product_id":{"type":"string","nullable":true},"variant_ids":{"type":"array","items":{"type":"string"}},"position":{"type":"number"},"alt":{"type":"string","nullable":true},"media_type":{"type":"string","enum":["image","video","external_video"]},"external_video_url":{"type":"string","nullable":true},"focal_point_x":{"type":"number","nullable":true},"focal_point_y":{"type":"number","nullable":true},"video_provider":{"type":"string","nullable":true},"video_embed_url":{"type":"string","nullable":true},"video_url":{"type":"string","nullable":true},"poster_url":{"type":"string","nullable":true},"original_url":{"type":"string","nullable":true},"mini_url":{"type":"string","nullable":true},"small_url":{"type":"string","nullable":true},"medium_url":{"type":"string","nullable":true},"large_url":{"type":"string","nullable":true},"xlarge_url":{"type":"string","nullable":true},"og_image_url":{"type":"string","nullable":true},"external_references":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"attached":{"type":"boolean"},"filename":{"type":"string","nullable":true},"content_type":{"type":"string","nullable":true},"byte_size":{"type":"number","nullable":true},"embed_url":{"type":"string","nullable":true},"signed_id":{"type":"string","nullable":true},"viewable_id":{"type":"string","nullable":true},"download_url":{"type":"string","nullable":true},"metadata":{"type":"object"},"viewable_type":{"type":"string","nullable":true}},"required":["id","product_id","variant_ids","position","alt","media_type","external_video_url","focal_point_x","focal_point_y","video_provider","video_embed_url","video_url","poster_url","original_url","mini_url","small_url","medium_url","large_url","xlarge_url","og_image_url","external_references","created_at","updated_at","attached","filename","content_type","byte_size","embed_url","signed_id","viewable_id","download_url","metadata","viewable_type"],"x-typelizer":true},"MembershipProduct":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"thumbnail_url":{"type":"string","nullable":true}},"required":["id","name","thumbnail_url"],"x-typelizer":true},"NewsletterSubscriber":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"verified":{"type":"boolean"},"verified_at":{"type":"string","nullable":true},"customer_id":{"type":"string","nullable":true}},"required":["id","email","created_at","updated_at","verified","verified_at","customer_id"],"x-typelizer":true},"OptionType":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"number"},"kind":{"type":"string","enum":["dropdown","color_swatch","buttons"]},"translations":{"type":"object"},"metadata":{"type":"object"},"filterable":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}}},"required":["id","name","label","position","kind","metadata","filterable","created_at","updated_at"],"x-typelizer":true},"OptionValue":{"type":"object","properties":{"id":{"type":"string"},"option_type_id":{"type":"string"},"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"number"},"color_code":{"type":"string","nullable":true},"option_type_name":{"type":"string"},"option_type_label":{"type":"string"},"image_url":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"option_type":{"$ref":"#/components/schemas/OptionType"}},"required":["id","option_type_id","name","label","position","color_code","option_type_name","option_type_label","image_url","metadata","created_at","updated_at"],"x-typelizer":true},"OrderCancellationReason":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"can_be_deleted":{"type":"boolean"}},"required":["id","name","active","created_at","updated_at","can_be_deleted"],"x-typelizer":true},"OrderGroup":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"email":{"type":"string","nullable":true},"currency":{"type":"string"},"total":{"type":"string","nullable":true},"item_total":{"type":"string","nullable":true},"fulfillment_status":{"type":"string","nullable":true,"enum":["backorder","canceled","partial","unfulfilled","fulfilled","delivered","pending","ready","shipped"]},"payment_status":{"type":"string","nullable":true,"enum":["none","authorized","partially_paid","paid","partially_refunded","refunded","overcharged","voided"]},"completed_at":{"type":"string","nullable":true},"billing_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"shipping_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"orders":{"type":"array","items":{"$ref":"#/components/schemas/Order"}},"customer_id":{"type":"string","nullable":true},"cart_id":{"type":"string","nullable":true},"seller_count":{"type":"number"},"includes_first_party":{"type":"boolean"},"confirmation_delivered":{"type":"boolean"},"store_owner_notification_delivered":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"payments":{"type":"array","items":{"$ref":"#/components/schemas/Payment"}}},"required":["id","number","email","currency","total","item_total","fulfillment_status","payment_status","completed_at","billing_address","shipping_address","orders","customer_id","cart_id","seller_count","includes_first_party","confirmation_delivered","store_owner_notification_delivered","created_at","updated_at","payments"],"x-typelizer":true},"OrderRoutingRule":{"type":"object","properties":{"id":{"type":"string"},"position":{"type":"number"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: preferred_location, default_location, minimize_splits. Extensions may register more."},"channel_id":{"type":"string"},"preferences":{"$ref":"#/components/schemas/OrderRoutingRulePreferences"}},"required":["id","position","active","created_at","updated_at","type","channel_id","preferences"],"x-typelizer":true},"Order":{"type":"object","properties":{"id":{"type":"string"},"market_id":{"type":"string","nullable":true},"withdrawal_period_ends_at":{"type":"string","nullable":true},"within_withdrawal_period":{"type":"boolean"},"cart_id":{"type":"string","nullable":true},"channel_id":{"type":"string","nullable":true},"company_id":{"type":"string","nullable":true},"company_name":{"type":"string","nullable":true},"po_document_filename":{"type":"string","nullable":true},"po_document_byte_size":{"type":"number","nullable":true},"number":{"type":"string"},"email":{"type":"string"},"customer_note":{"type":"string","nullable":true},"po_number":{"type":"string","nullable":true},"currency":{"type":"string"},"locale":{"type":"string","nullable":true},"total_quantity":{"type":"number"},"coupon_code":{"type":"string","nullable":true},"fulfillment_status":{"type":"string","nullable":true,"enum":["backorder","canceled","partial","unfulfilled","fulfilled","delivered","pending","ready","shipped"]},"payment_status":{"type":"string","nullable":true,"enum":["none","authorized","partially_paid","paid","partially_refunded","refunded","overcharged","voided"]},"completed_at":{"type":"string","nullable":true},"item_total":{"type":"string"},"adjustment_total":{"type":"string"},"discount_total":{"type":"string"},"tax_total":{"type":"string"},"included_tax_total":{"type":"string"},"additional_tax_total":{"type":"string"},"total":{"type":"string"},"gift_card_total":{"type":"string"},"amount_due":{"type":"string"},"delivery_total":{"type":"string"},"fee_total":{"type":"string"},"store_credit_total":{"type":"string"},"covered_by_store_credit":{"type":"boolean"},"items":{"type":"array","items":{"$ref":"#/components/schemas/LineItem"}},"fulfillments":{"type":"array","items":{"$ref":"#/components/schemas/Fulfillment"}},"payments":{"type":"array","items":{"$ref":"#/components/schemas/Payment"}},"billing_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"shipping_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"gift_card":{"allOf":[{"$ref":"#/components/schemas/GiftCard"}],"nullable":true},"market":{"allOf":[{"$ref":"#/components/schemas/Market"}],"nullable":true},"external_references":{"type":"object"},"status":{"type":"string","enum":["draft","placed","canceled"]},"last_ip_address":{"type":"string","nullable":true},"considered_risky":{"type":"boolean"},"confirmation_delivered":{"type":"boolean"},"store_owner_notification_delivered":{"type":"boolean","nullable":true},"metadata":{"type":"object"},"cancel_note":{"type":"string","nullable":true},"canceled_at":{"type":"string","nullable":true},"approved_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"payment_total":{"type":"string"},"commission_amount_total":{"type":"string"},"commission_tax_total":{"type":"string"},"commission_total":{"type":"string"},"preferred_stock_location_id":{"type":"string","nullable":true},"po_document_url":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"},"order_group_id":{"type":"string","nullable":true},"tags":{"type":"array","items":{"type":"string"}},"internal_note":{"type":"string","nullable":true},"internal_note_html":{"type":"string","nullable":true},"approver_id":{"type":"string","nullable":true},"approver_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"approver":{"$ref":"#/components/schemas/Actor"},"canceler_id":{"type":"string","nullable":true},"canceler_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"canceler":{"$ref":"#/components/schemas/Actor"},"created_by_id":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by":{"$ref":"#/components/schemas/Actor"},"cancel_reason_id":{"type":"string","nullable":true},"cancel_reason_name":{"type":"string","nullable":true},"customer_id":{"type":"string","nullable":true},"applied_promotions":{"type":"array","items":{"$ref":"#/components/schemas/AppliedPromotion"}},"payment_splits":{"type":"array","items":{"$ref":"#/components/schemas/PaymentSplit"}},"cart":{"$ref":"#/components/schemas/Cart"},"channel":{"$ref":"#/components/schemas/Channel"},"preferred_stock_location":{"$ref":"#/components/schemas/StockLocation"},"payment_methods":{"type":"array","items":{"$ref":"#/components/schemas/PaymentMethod"}},"customer":{"$ref":"#/components/schemas/Customer"},"cancel_reason":{"$ref":"#/components/schemas/OrderCancellationReason"},"returns":{"type":"array","items":{"$ref":"#/components/schemas/Return"}},"exchanges":{"type":"array","items":{"$ref":"#/components/schemas/Exchange"}},"claims":{"type":"array","items":{"$ref":"#/components/schemas/Claim"}},"freight_summary":{"allOf":[{"$ref":"#/components/schemas/FreightSummary"}],"nullable":true}},"required":["id","market_id","withdrawal_period_ends_at","within_withdrawal_period","cart_id","channel_id","company_id","company_name","po_document_filename","po_document_byte_size","number","email","customer_note","po_number","currency","locale","total_quantity","coupon_code","fulfillment_status","payment_status","completed_at","item_total","adjustment_total","discount_total","tax_total","included_tax_total","additional_tax_total","total","gift_card_total","amount_due","delivery_total","fee_total","store_credit_total","covered_by_store_credit","gift_card","market","external_references","status","last_ip_address","considered_risky","confirmation_delivered","store_owner_notification_delivered","metadata","cancel_note","canceled_at","approved_at","created_at","updated_at","payment_total","commission_amount_total","commission_tax_total","commission_total","preferred_stock_location_id","po_document_url","seller_id","order_group_id","tags","internal_note","internal_note_html","approver_id","approver_type","canceler_id","canceler_type","created_by_id","created_by_type","cancel_reason_id","cancel_reason_name","customer_id","freight_summary"],"x-typelizer":true},"PackageType":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"kind":{"type":"string","enum":["box","envelope","carton","pallet","container"]},"length":{"type":"string","nullable":true},"width":{"type":"string","nullable":true},"height":{"type":"string","nullable":true},"weight":{"type":"string","nullable":true},"max_weight":{"type":"string","nullable":true},"default":{"type":"boolean"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"volume":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true}},"required":["id","name","kind","length","width","height","weight","max_weight","default","metadata","created_at","updated_at","dimensions_unit","weight_unit","volume","seller_id","seller_name"],"x-typelizer":true},"PaymentMethod":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"type":{"type":"string","description":"Payment method type. Built-in: check, store_credit, custom_payment_source_method, bogus (test only); payment provider gems register their own, for example stripe."},"session_required":{"type":"boolean"},"source_required":{"type":"boolean"},"metadata":{"type":"object"},"active":{"type":"boolean"},"auto_capture":{"type":"boolean","nullable":true},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"],"nullable":true},"resolved_capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"]},"storefront_visible":{"type":"boolean"},"position":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"preferences":{"$ref":"#/components/schemas/PaymentMethodPreferences"},"logo_url":{"type":"string","nullable":true},"docs_url":{"type":"string","nullable":true},"third_party":{"type":"boolean"}},"required":["id","name","description","type","session_required","source_required","metadata","active","auto_capture","capture_method","resolved_capture_method","storefront_visible","position","created_at","updated_at","preferences","logo_url","docs_url","third_party"],"x-typelizer":true},"Payment":{"type":"object","properties":{"id":{"type":"string"},"payment_method_id":{"type":"string"},"response_code":{"type":"string","nullable":true},"number":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["checkout","processing","pending","completed","failed","void","invalid"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"amount":{"type":"string"},"source_type":{"type":"string","nullable":true,"enum":["credit_card","store_credit","payment_source"]},"source_id":{"type":"string","nullable":true},"source":{"anyOf":[{"$ref":"#/components/schemas/CreditCard"},{"$ref":"#/components/schemas/StoreCredit"},{"$ref":"#/components/schemas/PaymentSource"}],"nullable":true},"payment_method":{"$ref":"#/components/schemas/PaymentMethod"},"metadata":{"type":"object"},"avs_response":{"type":"string","nullable":true},"cvv_response_code":{"type":"string","nullable":true},"cvv_response_message":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"captured_amount":{"type":"string"},"order_id":{"type":"string","nullable":true},"order":{"$ref":"#/components/schemas/Order"},"refunds":{"type":"array","items":{"$ref":"#/components/schemas/Refund"}},"payment_splits":{"type":"array","items":{"$ref":"#/components/schemas/PaymentSplit"}}},"required":["id","payment_method_id","response_code","number","status","amount","source_type","source_id","source","metadata","avs_response","cvv_response_code","cvv_response_message","created_at","updated_at","captured_amount","order_id"],"x-typelizer":true},"PaymentSource":{"type":"object","properties":{"id":{"type":"string"},"gateway_payment_profile_id":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","gateway_payment_profile_id","metadata","created_at","updated_at"],"x-typelizer":true},"PaymentSplit":{"type":"object","properties":{"id":{"type":"string"},"currency":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"authorized_amount":{"type":"string"},"captured_amount":{"type":"string"},"refunded_amount":{"type":"string"},"claimed_amount":{"type":"string"},"net_captured_amount":{"type":"string"},"refundable_amount":{"type":"string"},"payment_id":{"type":"string"},"payment_number":{"type":"string","nullable":true},"order_id":{"type":"string"},"order_number":{"type":"string","nullable":true}},"required":["id","currency","created_at","updated_at","authorized_amount","captured_amount","refunded_amount","claimed_amount","net_captured_amount","refundable_amount","payment_id","payment_number","order_id","order_number"],"x-typelizer":true},"Permission":{"type":"object","properties":{"key":{"type":"string"},"resource":{"type":"string"},"kind":{"type":"string","enum":["read","write"]},"group":{"type":"string"},"group_label":{"type":"string"},"label":{"type":"string"},"description":{"type":"string"}},"required":["key","resource","kind","group","group_label","label","description"],"x-typelizer":true},"Policy":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"body":{"type":"string","nullable":true},"body_html":{"type":"string","nullable":true},"updated_at":{"type":"string"},"created_at":{"type":"string"}},"required":["id","name","slug","body","body_html","updated_at","created_at"],"x-typelizer":true},"PriceAdjustmentTier":{"type":"object","properties":{"id":{"type":"string"},"min_quantity":{"type":"number"},"percentage":{"type":"string"}},"required":["id","min_quantity","percentage"],"x-typelizer":true},"PriceHistory":{"type":"object","properties":{"id":{"type":"string"},"currency":{"type":"string"},"amount":{"type":"string","nullable":true},"recorded_at":{"type":"string"},"variant_id":{"type":"string"},"price_id":{"type":"string"},"compare_at_amount":{"type":"string","nullable":true},"created_at":{"type":"string"}},"required":["id","currency","amount","recorded_at","variant_id","price_id","compare_at_amount","created_at"],"x-typelizer":true},"PriceListProduct":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"thumbnail_url":{"type":"string","nullable":true},"price_list_variants":{"type":"array","items":{"$ref":"#/components/schemas/CatalogPrice"}}},"required":["id","name","thumbnail_url"],"x-typelizer":true},"PriceList":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"status":{"anyOf":[{"type":"string","enum":["draft","active","inactive","scheduled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"position":{"type":"number"},"match_policy":{"type":"string","enum":["all","any"]},"adjust_compare_at":{"type":"boolean"},"starts_at":{"type":"string","nullable":true},"ends_at":{"type":"string","nullable":true},"deleted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"price_adjustment_percentage":{"type":"string","nullable":true},"automatic_pricing":{"type":"boolean"},"currently_active":{"type":"boolean"},"products_count":{"type":"number"},"prices_count":{"type":"number"},"price_adjustment_tiers":{"type":"array","items":{"$ref":"#/components/schemas/PriceAdjustmentTier"}},"price_rules":{"type":"array","items":{"$ref":"#/components/schemas/PriceRule"}}},"required":["id","name","description","status","position","match_policy","adjust_compare_at","starts_at","ends_at","deleted_at","created_at","updated_at","price_adjustment_percentage","automatic_pricing","currently_active","products_count","prices_count","price_adjustment_tiers"],"x-typelizer":true},"PriceRule":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: channel_rule, customer_group_rule, market_rule, user_rule, volume_rule, zone_rule. Extensions may register more."},"price_list_id":{"type":"string"},"preferences":{"$ref":"#/components/schemas/PriceRulePreferences"},"markets":{"type":"array","items":{"$ref":"#/components/schemas/Market"}},"customer_groups":{"type":"array","items":{"$ref":"#/components/schemas/CustomerGroup"}},"channels":{"type":"array","items":{"$ref":"#/components/schemas/Channel"}},"customers":{"type":"array","items":{"$ref":"#/components/schemas/Customer"}}},"required":["id","created_at","updated_at","type","price_list_id","preferences"],"x-typelizer":true},"Price":{"type":"object","properties":{"id":{"type":"string"},"currency":{"type":"string","nullable":true},"amount":{"type":"string","nullable":true},"compare_at_amount":{"type":"string","nullable":true},"price_list_id":{"type":"string","nullable":true},"min_quantity":{"type":"number"},"variant_id":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"variant":{"$ref":"#/components/schemas/Variant"}},"required":["id","currency","amount","compare_at_amount","price_list_id","min_quantity","variant_id","created_at","updated_at"],"x-typelizer":true},"ProductPublication":{"type":"object","properties":{"id":{"type":"string"},"published_at":{"type":"string","nullable":true},"unpublished_at":{"type":"string","nullable":true},"product_id":{"type":"string"},"channel_id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","published_at","unpublished_at","product_id","channel_id","created_at","updated_at"],"x-typelizer":true},"Product":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"meta_title":{"type":"string","nullable":true},"meta_description":{"type":"string","nullable":true},"meta_keywords":{"type":"string","nullable":true},"variant_count":{"type":"number"},"available_on":{"type":"string","nullable":true},"preorder_ships_at":{"type":"string","nullable":true},"purchasable":{"type":"boolean"},"preorder":{"type":"boolean"},"in_stock":{"type":"boolean"},"backorderable":{"type":"boolean"},"available":{"type":"boolean"},"description":{"type":"string","nullable":true},"description_html":{"type":"string","nullable":true},"default_variant_id":{"type":"string"},"buy_box_variant_id":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true},"tags":{"type":"array","items":{"type":"string"}},"price":{"allOf":[{"$ref":"#/components/schemas/Price"}],"nullable":true},"original_price":{"allOf":[{"$ref":"#/components/schemas/Price"}],"nullable":true},"seller_id":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"},"primary_media":{"$ref":"#/components/schemas/Media"},"media":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"variants":{"type":"array","items":{"$ref":"#/components/schemas/Variant"}},"default_variant":{"$ref":"#/components/schemas/Variant"},"option_types":{"type":"array","items":{"$ref":"#/components/schemas/OptionType"}},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}},"categories":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"prior_price":{"allOf":[{"$ref":"#/components/schemas/PriceHistory"}],"nullable":true},"external_references":{"type":"object"},"translations":{"type":"object"},"status":{"anyOf":[{"type":"string","enum":["draft","active","archived","proposed","rejected"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"metadata":{"type":"object"},"deleted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"submission":{"allOf":[{"$ref":"#/components/schemas/ProductSubmission"}],"nullable":true},"seller_name":{"type":"string","nullable":true},"product_type_id":{"type":"string","nullable":true},"tax_category_id":{"type":"string","nullable":true},"digital_assets":{"type":"array","items":{"$ref":"#/components/schemas/DigitalAsset"}},"collections":{"type":"array","items":{"$ref":"#/components/schemas/Collection"}},"product_publications":{"type":"array","items":{"$ref":"#/components/schemas/ProductPublication"}},"channels":{"type":"array","items":{"$ref":"#/components/schemas/Channel"}},"product_type":{"$ref":"#/components/schemas/ProductType"}},"required":["id","name","slug","meta_title","meta_description","meta_keywords","variant_count","available_on","preorder_ships_at","purchasable","preorder","in_stock","backorderable","available","description","description_html","default_variant_id","buy_box_variant_id","thumbnail_url","tags","price","original_price","seller_id","external_references","status","metadata","deleted_at","created_at","updated_at","delivery_profile_id","seller_name","product_type_id","tax_category_id"],"x-typelizer":true},"ProductSubmission":{"type":"object","properties":{"id":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","approved","rejected","withdrawn"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"review_note":{"type":"string","nullable":true},"reviewed_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"product_id":{"type":"string"},"metadata":{"type":"object","nullable":true},"updated_at":{"type":"string"},"submitted_by_id":{"type":"string","nullable":true},"reviewed_by_id":{"type":"string","nullable":true},"reviewed_by_name":{"type":"string","nullable":true},"auto_approved":{"type":"boolean"}},"required":["id","status","review_note","reviewed_at","created_at","product_id","metadata","updated_at","submitted_by_id","reviewed_by_id","reviewed_by_name","auto_approved"],"x-typelizer":true},"ProductTypeCustomFieldDefinition":{"type":"object","properties":{"id":{"type":"string"},"key":{"type":"string"},"namespace":{"type":"string"},"label":{"type":"string"},"field_type":{"type":"string","enum":["short_text","long_text","rich_text","number","boolean","json"]},"required":{"type":"boolean"},"sort_order":{"type":"number"}},"required":["id","key","namespace","label","field_type","required","sort_order"],"x-typelizer":true},"ProductType":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"translations":{"type":"object"},"products_count":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"option_type_ids":{"type":"array","items":{"type":"string"}},"category_ids":{"type":"array","items":{"type":"string"}},"custom_field_definitions":{"type":"array","items":{"$ref":"#/components/schemas/ProductTypeCustomFieldDefinition"}}},"required":["id","name","products_count","created_at","updated_at","delivery_profile_id","option_type_ids","category_ids","custom_field_definitions"],"x-typelizer":true},"PromotionAction":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Action type. Built-in: create_adjustment, create_item_adjustments, create_line_items, free_shipping. Extensions may register more."},"promotion_id":{"type":"string"},"preferences":{"type":"object"},"calculator":{"allOf":[{"$ref":"#/components/schemas/PromotionActionCalculator"}],"nullable":true},"line_items":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionLineItem"},"nullable":true}},"required":["id","created_at","updated_at","type","promotion_id","preferences","calculator","line_items"],"x-typelizer":true},"PromotionRule":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: currency, country, channel, market, item_total, product, customer, customer_group, first_order, customer_logged_in, one_use_per_user, category, option_value. Extensions may register more."},"promotion_id":{"type":"string"},"preferences":{"$ref":"#/components/schemas/PromotionRulePreferences"},"product_ids":{"type":"array","items":{"type":"string"},"nullable":true},"category_ids":{"type":"array","items":{"type":"string"},"nullable":true},"customer_ids":{"type":"array","items":{"type":"string"},"nullable":true},"option_value_ids":{"type":"array","items":{"type":"string"},"nullable":true},"products":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"categories":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"customers":{"type":"array","items":{"$ref":"#/components/schemas/Customer"}},"customer_groups":{"type":"array","items":{"$ref":"#/components/schemas/CustomerGroup"}},"countries":{"type":"array","items":{"$ref":"#/components/schemas/Country"}},"channels":{"type":"array","items":{"$ref":"#/components/schemas/Channel"}},"markets":{"type":"array","items":{"$ref":"#/components/schemas/Market"}},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}}},"required":["id","created_at","updated_at","type","promotion_id","preferences","product_ids","category_ids","customer_ids","option_value_ids"],"x-typelizer":true},"Promotion":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"code":{"type":"string","nullable":true},"starts_at":{"type":"string","nullable":true},"expires_at":{"type":"string","nullable":true},"usage_limit":{"type":"number","nullable":true},"match_policy":{"type":"string","enum":["all","any"]},"path":{"type":"string","nullable":true},"kind":{"type":"string","enum":["coupon_code","automatic"]},"multi_codes":{"type":"boolean"},"number_of_codes":{"type":"number","nullable":true},"code_prefix":{"type":"string","nullable":true},"promotion_category_id":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"action_ids":{"type":"array","items":{"type":"string"}},"rule_ids":{"type":"array","items":{"type":"string"}}},"required":["id","name","description","code","starts_at","expires_at","usage_limit","match_policy","path","kind","multi_codes","number_of_codes","code_prefix","promotion_category_id","metadata","created_at","updated_at","action_ids","rule_ids"],"x-typelizer":true},"PurchaseOrderItem":{"type":"object","properties":{"id":{"type":"string"},"quantity_ordered":{"type":"number"},"quantity_received":{"type":"number"},"quantity_rejected":{"type":"number"},"quantity_over":{"type":"number"},"outstanding":{"type":"number"},"currency":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"unit_cost":{"type":"string"},"total_cost":{"type":"string"},"purchase_order_id":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"product_id":{"type":"string","nullable":true},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true}},"required":["id","quantity_ordered","quantity_received","quantity_rejected","quantity_over","outstanding","currency","created_at","updated_at","unit_cost","total_cost","purchase_order_id","variant_id","product_id","variant_name","variant_sku","options_text","thumbnail_url"],"x-typelizer":true},"PurchaseOrder":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"status":{"type":"string"},"currency":{"type":"string"},"reference":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"metadata":{"type":"object"},"close_reason":{"type":"string","nullable":true},"items_count":{"type":"number"},"quantity_received_total":{"type":"number"},"quantity_rejected_total":{"type":"number"},"ordered_at":{"type":"string","nullable":true},"received_at":{"type":"string","nullable":true},"closed_short_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"expected_at":{"type":"string","nullable":true},"cancel_by":{"type":"string","nullable":true},"closed_short":{"type":"boolean"},"quantity_ordered_total":{"type":"number"},"editable":{"type":"boolean"},"subtotal":{"type":"string"},"supplier_id":{"type":"string","nullable":true},"destination_location_id":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/PurchaseOrderItem"}},"stock_receipts":{"type":"array","items":{"$ref":"#/components/schemas/StockReceipt"}},"supplier":{"$ref":"#/components/schemas/Supplier"},"destination_location":{"$ref":"#/components/schemas/StockLocation"}},"required":["id","number","status","currency","reference","notes","metadata","close_reason","items_count","quantity_received_total","quantity_rejected_total","ordered_at","received_at","closed_short_at","created_at","updated_at","expected_at","cancel_by","closed_short","quantity_ordered_total","editable","subtotal","supplier_id","destination_location_id"],"x-typelizer":true},"RefundReason":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"can_be_deleted":{"type":"boolean"}},"required":["id","name","active","created_at","updated_at","can_be_deleted"],"x-typelizer":true},"Refund":{"type":"object","properties":{"id":{"type":"string"},"transaction_id":{"type":"string","nullable":true},"amount":{"type":"string","nullable":true},"payment_id":{"type":"string","nullable":true},"refund_reason_id":{"type":"string","nullable":true},"originator_id":{"type":"string","nullable":true},"originator_type":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"tax_amount":{"type":"string"},"refunder_id":{"type":"string","nullable":true},"refunder_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"refunder":{"$ref":"#/components/schemas/Actor"},"payment":{"$ref":"#/components/schemas/Payment"}},"required":["id","transaction_id","amount","payment_id","refund_reason_id","originator_id","originator_type","metadata","created_at","updated_at","tax_amount","refunder_id","refunder_type"],"x-typelizer":true},"ReturnLineItem":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"received_quantity":{"type":"number"},"resellable":{"type":"boolean"},"pre_tax_amount":{"type":"string"},"included_tax_total":{"type":"string"},"additional_tax_total":{"type":"string"},"tax_total":{"type":"string"},"refund_amount":{"type":"string"},"variant_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"fulfillment_item_id":{"type":"string","nullable":true},"variant":{"$ref":"#/components/schemas/Variant"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"line_item":{"$ref":"#/components/schemas/LineItem"},"tax_lines":{"type":"array","items":{"$ref":"#/components/schemas/TaxLine"}}},"required":["id","quantity","received_quantity","resellable","pre_tax_amount","included_tax_total","additional_tax_total","tax_total","refund_amount","variant_id","line_item_id","fulfillment_item_id","created_at","updated_at"],"x-typelizer":true},"ReturnReason":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"can_be_deleted":{"type":"boolean"}},"required":["id","name","active","created_at","updated_at","can_be_deleted"],"x-typelizer":true},"Return":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["requested","approved","received","refunded","canceled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"order_id":{"type":"string","nullable":true},"reason_id":{"type":"string","nullable":true},"refund_total":{"type":"string"},"refund_tax_total":{"type":"string"},"approved_at":{"type":"string","nullable":true},"received_at":{"type":"string","nullable":true},"refunded_at":{"type":"string","nullable":true},"canceled_at":{"type":"string","nullable":true},"reason":{"$ref":"#/components/schemas/ReturnReason"},"return_line_items":{"type":"array","items":{"$ref":"#/components/schemas/ReturnLineItem"}},"memo":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_location_id":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by":{"$ref":"#/components/schemas/Actor"},"refunded_total":{"type":"string"},"refundable_total":{"type":"string"},"order":{"$ref":"#/components/schemas/Order"},"stock_location":{"$ref":"#/components/schemas/StockLocation"},"refunds":{"type":"array","items":{"$ref":"#/components/schemas/Refund"}},"documents":{"type":"array","items":{"type":"object"}},"labels":{"type":"array","items":{"$ref":"#/components/schemas/ShippingLabel"}},"deliveries":{"type":"array","items":{"$ref":"#/components/schemas/Delivery"}}},"required":["id","number","status","order_id","reason_id","refund_total","refund_tax_total","approved_at","received_at","refunded_at","canceled_at","memo","metadata","created_at","updated_at","stock_location_id","created_by_id","created_by_type","refunded_total","refundable_total","documents","labels","deliveries"],"x-typelizer":true},"Role":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"permissions":{"type":"array","items":{"type":"string"}},"mutable":{"type":"boolean"},"users_count":{"type":"number"}},"required":["id","name","description","created_at","updated_at","permissions","mutable","users_count"],"x-typelizer":true},"SavedReport":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"query":{"type":"object"},"seeded":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"user_id":{"type":"string","nullable":true},"author_name":{"type":"string","nullable":true}},"required":["id","name","description","query","seeded","created_at","updated_at","user_id","author_name"],"x-typelizer":true},"SellerBalance":{"type":"object","properties":{"currency":{"type":"string"},"settlement_currency":{"type":"string"},"converted":{"type":"boolean"},"seller_id":{"type":"string"},"earned":{"type":"string"},"pending":{"type":"string"},"payable":{"type":"string"},"paid":{"type":"string"},"balance":{"type":"string"}},"required":["currency","settlement_currency","converted","seller_id","earned","pending","payable","paid","balance"],"x-typelizer":true},"SellerPayout":{"type":"object","properties":{"id":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","processing","completed","failed","unresolved"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"currency":{"type":"string"},"reference":{"type":"string","nullable":true},"metadata":{"type":"object"},"period_start":{"type":"string","nullable":true},"period_end":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount":{"type":"string"},"seller_id":{"type":"string"},"seller_name":{"type":"string","nullable":true},"transfers_count":{"type":"number"},"provider":{"type":"string","description":"Payout provider. Built-in: system. Provider gems register more (e.g. stripe)."}},"required":["id","status","currency","reference","metadata","period_start","period_end","created_at","updated_at","amount","seller_id","seller_name","transfers_count","provider"],"x-typelizer":true},"SellerRequirement":{"type":"object","properties":{"id":{"type":"string"},"position":{"type":"number"},"active":{"type":"boolean"},"required":{"type":"boolean"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"kind":{"type":"string","description":"Requirement kind. Built-in: accept_terms, complete_profile, billing_address, returns_address, delivery_method, package_type, minimum_products, payout_account, required_custom_fields, policy, attestation, operator_review, document. Extensions may register more."},"name":{"type":"string"},"description":{"type":"string","nullable":true},"preferences":{"$ref":"#/components/schemas/SellerRequirementPreferences"},"custom_field_definition_ids":{"type":"array","items":{"type":"string"}},"allow_multiple":{"type":"boolean"},"accepts_submissions":{"type":"boolean"},"reviewed_by_operator":{"type":"boolean"}},"required":["id","position","active","required","metadata","created_at","updated_at","kind","name","description","preferences","custom_field_definition_ids","allow_multiple","accepts_submissions","reviewed_by_operator"],"x-typelizer":true},"SellerRequirementStatus":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","description":"Requirement kind. Built-in: accept_terms, complete_profile, billing_address, returns_address, delivery_method, package_type, minimum_products, payout_account, required_custom_fields, policy, attestation, operator_review, document. Extensions may register more."},"name":{"type":"string"},"description":{"type":"string","nullable":true},"required":{"type":"boolean"},"position":{"type":"number"},"status":{"type":"string","enum":["complete","incomplete","pending","rejected"]},"action_url":{"type":"string","nullable":true},"blocker":{"type":"object","nullable":true},"blocking":{"type":"boolean"},"required_policy_name":{"type":"string","nullable":true},"submission":{"$ref":"#/components/schemas/SellerRequirementSubmission"},"published_policy":{"$ref":"#/components/schemas/Policy"}},"required":["id","kind","name","description","required","position","status","action_url","blocker","blocking","required_policy_name"],"x-typelizer":true},"SellerRequirementSubmission":{"type":"object","properties":{"id":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","accepted","rejected","waived"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"note":{"type":"string","nullable":true},"review_note":{"type":"string","nullable":true},"reference":{"type":"string","nullable":true},"metadata":{"type":"object","nullable":true},"reviewed_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"seller_id":{"type":"string"},"requirement_id":{"type":"string"},"requirement_name":{"type":"string"},"file_url":{"type":"string","nullable":true},"file_name":{"type":"string","nullable":true}},"required":["id","status","note","review_note","reference","metadata","reviewed_at","created_at","updated_at","seller_id","requirement_id","requirement_name","file_url","file_name"],"x-typelizer":true},"Seller":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"about":{"type":"string"},"about_html":{"type":"string"},"logo_url":{"type":"string","nullable":true},"square_logo_url":{"type":"string","nullable":true},"cover_photo_url":{"type":"string","nullable":true},"status":{"anyOf":[{"type":"string","enum":["pending","invited","canceled","onboarding","ready_for_review","approved","rejected","suspended"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"contact_email":{"type":"string","nullable":true},"billing_email":{"type":"string","nullable":true},"tax_remittance":{"type":"string"},"payouts_schedule_interval":{"type":"string","nullable":true},"metadata":{"type":"object","nullable":true},"holiday_mode_until":{"type":"string","nullable":true},"terms_accepted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"deleted_at":{"type":"string","nullable":true},"minimum_payout_amount":{"type":"string","nullable":true},"on_holiday":{"type":"boolean"},"sellable":{"type":"boolean"},"products_count":{"type":"number"},"users_count":{"type":"number"},"onboarding_progress":{"type":"object"},"onboarding_complete":{"type":"boolean"},"legal_name":{"type":"string","nullable":true},"registration_number":{"type":"string","nullable":true},"billing_address":{"$ref":"#/components/schemas/Address"},"returns_address":{"$ref":"#/components/schemas/Address"}},"required":["id","name","slug","about","about_html","logo_url","square_logo_url","cover_photo_url","status","contact_email","billing_email","tax_remittance","payouts_schedule_interval","metadata","holiday_mode_until","terms_accepted_at","created_at","updated_at","deleted_at","minimum_payout_amount","on_holiday","sellable","products_count","users_count","onboarding_progress","onboarding_complete","legal_name","registration_number"],"x-typelizer":true},"SellerTeamMember":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"first_name":{"type":"string","nullable":true},"last_name":{"type":"string","nullable":true},"full_name":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"avatar_url":{"type":"string","nullable":true}},"required":["id","email","first_name","last_name","full_name","created_at","updated_at","avatar_url"],"x-typelizer":true},"SellerTransfer":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["earning","refund_reversal"]},"status":{"anyOf":[{"type":"string","enum":["pending","processing","completed","failed","unresolved"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"currency":{"type":"string"},"reference":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount":{"type":"string"},"settled_amount":{"type":"string","nullable":true},"settled_currency":{"type":"string","nullable":true},"converted":{"type":"boolean"},"seller_id":{"type":"string"},"order_id":{"type":"string","nullable":true},"payout_id":{"type":"string","nullable":true},"reversed_from_id":{"type":"string","nullable":true},"refund_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"order_number":{"type":"string","nullable":true},"provider":{"type":"string","description":"Payout provider. Built-in: system. Provider gems register more (e.g. stripe)."}},"required":["id","kind","status","currency","reference","metadata","created_at","updated_at","amount","settled_amount","settled_currency","converted","seller_id","order_id","payout_id","reversed_from_id","refund_id","seller_name","order_number","provider"],"x-typelizer":true},"SetupTask":{"type":"object","properties":{"name":{"type":"string"},"done":{"type":"boolean"}},"required":["name","done"],"x-typelizer":true},"ShippingLabel":{"type":"object","properties":{"id":{"type":"string"},"source":{"type":"string","enum":["purchased","uploaded"]},"status":{"anyOf":[{"type":"string","enum":["purchased","refund_requested","refunded"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"carrier":{"type":"string","nullable":true},"carrier_name":{"type":"string","nullable":true},"service":{"type":"string","nullable":true},"tracking_number":{"type":"string","nullable":true},"currency":{"type":"string","nullable":true},"format":{"type":"string","nullable":true},"external_id":{"type":"string","nullable":true},"metadata":{"type":"object"},"refunded_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"owner_id":{"type":"string"},"owner_type":{"type":"string","enum":["fulfillment","return"]},"cost":{"type":"string"},"integration_id":{"type":"string","nullable":true},"file_pending":{"type":"boolean"},"download_url":{"type":"string","nullable":true}},"required":["id","source","status","carrier","carrier_name","service","tracking_number","currency","format","external_id","metadata","refunded_at","created_at","updated_at","owner_id","owner_type","cost","integration_id","file_pending","download_url"],"x-typelizer":true},"State":{"type":"object","properties":{"abbr":{"type":"string"},"name":{"type":"string"}},"required":["abbr","name"],"x-typelizer":true},"StockLevel":{"type":"object","properties":{"id":{"type":"string"},"count_on_hand":{"type":"number"},"backorderable":{"type":"boolean"},"stock_location_id":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"external_references":{"type":"object"},"metadata":{"type":"object"},"reserved_count":{"type":"number"},"incoming_count":{"type":"number"},"purchasable_count":{"type":"number"},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_location_name":{"type":"string","nullable":true},"product_id":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true},"allocated_count":{"type":"number"},"available_count":{"type":"number"},"stock_location":{"$ref":"#/components/schemas/StockLocation"},"variant":{"$ref":"#/components/schemas/Variant"}},"required":["id","count_on_hand","backorderable","stock_location_id","variant_id","external_references","metadata","reserved_count","incoming_count","purchasable_count","variant_name","variant_sku","created_at","updated_at","stock_location_name","product_id","options_text","thumbnail_url","allocated_count","available_count"],"x-typelizer":true},"StockLocation":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"address1":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"zipcode":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true},"country_name":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"state_text":{"type":"string","nullable":true},"pickup_ready_in_minutes":{"type":"number","nullable":true},"pickup_instructions":{"type":"string","nullable":true},"external_references":{"type":"object"},"admin_name":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"active":{"type":"boolean"},"default":{"type":"boolean"},"backorderable_default":{"type":"boolean"},"propagate_all_variants":{"type":"boolean"},"kind":{"anyOf":[{"type":"string","enum":["warehouse","store","fulfillment_center"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"pickup_enabled":{"type":"boolean"},"pickup_stock_policy":{"type":"string","enum":["local","any"]},"returns_enabled":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"seller_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"}},"required":["id","name","address1","city","zipcode","country_code","country_name","state_code","state_text","pickup_ready_in_minutes","pickup_instructions","external_references","admin_name","address2","state_name","phone","company","active","default","backorderable_default","propagate_all_variants","kind","pickup_enabled","pickup_stock_policy","returns_enabled","created_at","updated_at","seller_id","seller_name"],"x-typelizer":true},"StockMovement":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"kind":{"type":"string","nullable":true,"enum":["received","allocated","shipped","released","adjusted"]},"reason":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_level_id":{"type":"string","nullable":true},"stock_location_id":{"type":"string","nullable":true},"stock_location_name":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"order_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"return_id":{"type":"string","nullable":true},"exchange_id":{"type":"string","nullable":true},"stock_transfer_id":{"type":"string","nullable":true},"stock_receipt_id":{"type":"string","nullable":true},"purchase_order_id":{"type":"string","nullable":true},"order_number":{"type":"string","nullable":true},"return_number":{"type":"string","nullable":true},"exchange_number":{"type":"string","nullable":true},"stock_transfer_number":{"type":"string","nullable":true},"purchase_order_number":{"type":"string","nullable":true},"unit_cost":{"type":"string","nullable":true}},"required":["id","quantity","kind","reason","created_at","updated_at","stock_level_id","stock_location_id","stock_location_name","variant_id","variant_name","variant_sku","order_id","fulfillment_id","return_id","exchange_id","stock_transfer_id","stock_receipt_id","purchase_order_id","order_number","return_number","exchange_number","stock_transfer_number","purchase_order_number","unit_cost"],"x-typelizer":true},"StockReceiptItem":{"type":"object","properties":{"id":{"type":"string"},"quantity_accepted":{"type":"number"},"quantity_rejected":{"type":"number"},"rejection_reason":{"type":"string","nullable":true,"enum":["damaged","wrong_item","expired","other"]},"notes":{"type":"string","nullable":true},"line_type":{"type":"string","enum":["purchase_order_item","stock_transfer_item"]},"line_id":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"product_id":{"type":"string","nullable":true},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true}},"required":["id","quantity_accepted","quantity_rejected","rejection_reason","notes","line_type","line_id","variant_id","product_id","variant_name","variant_sku","thumbnail_url"],"x-typelizer":true},"StockReceipt":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"reference":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"metadata":{"type":"object"},"quantity_accepted_total":{"type":"number"},"quantity_rejected_total":{"type":"number"},"received_at":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"receivable_type":{"type":"string","enum":["purchase_order","stock_transfer"]},"receivable_id":{"type":"string"},"received_by_id":{"type":"string","nullable":true},"received_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"received_by":{"$ref":"#/components/schemas/Actor"},"items_count":{"type":"number"},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockReceiptItem"}}},"required":["id","number","reference","notes","metadata","quantity_accepted_total","quantity_rejected_total","received_at","created_at","updated_at","receivable_type","receivable_id","received_by_id","received_by_type","items_count"],"x-typelizer":true},"StockReservation":{"type":"object","properties":{"id":{"type":"string"},"stock_level_id":{"type":"string"},"line_item_id":{"type":"string"},"order_id":{"type":"string"},"variant_id":{"type":"string","nullable":true},"stock_location_id":{"type":"string","nullable":true},"quantity":{"type":"number"},"expires_at":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","stock_level_id","line_item_id","order_id","variant_id","stock_location_id","quantity","expires_at","active","created_at","updated_at"],"x-typelizer":true},"StockTransferItem":{"type":"object","properties":{"id":{"type":"string"},"quantity_shipped":{"type":"number"},"quantity_received":{"type":"number"},"quantity_rejected":{"type":"number"},"quantity_over":{"type":"number"},"outstanding":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_transfer_id":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"product_id":{"type":"string","nullable":true},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true}},"required":["id","quantity_shipped","quantity_received","quantity_rejected","quantity_over","outstanding","created_at","updated_at","stock_transfer_id","variant_id","product_id","variant_name","variant_sku","options_text","thumbnail_url"],"x-typelizer":true},"StockTransfer":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"reference":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"source_location_id":{"type":"string"},"destination_location_id":{"type":"string"},"status":{"type":"string"},"notes":{"type":"string","nullable":true},"metadata":{"type":"object"},"close_reason":{"type":"string","nullable":true},"items_count":{"type":"number"},"quantity_received_total":{"type":"number"},"quantity_rejected_total":{"type":"number"},"shipped_at":{"type":"string","nullable":true},"received_at":{"type":"string","nullable":true},"closed_short_at":{"type":"string","nullable":true},"deleted_at":{"type":"string","nullable":true},"closed_short":{"type":"boolean"},"quantity_shipped_total":{"type":"number"},"editable":{"type":"boolean"},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockTransferItem"}},"stock_receipts":{"type":"array","items":{"$ref":"#/components/schemas/StockReceipt"}},"source_location":{"$ref":"#/components/schemas/StockLocation"},"destination_location":{"$ref":"#/components/schemas/StockLocation"}},"required":["id","number","reference","created_at","updated_at","source_location_id","destination_location_id","status","notes","metadata","close_reason","items_count","quantity_received_total","quantity_rejected_total","shipped_at","received_at","closed_short_at","deleted_at","closed_short","quantity_shipped_total","editable"],"x-typelizer":true},"StoreCreditEvent":{"type":"object","properties":{"id":{"type":"string"},"action":{"type":"string"},"authorization_code":{"type":"string","nullable":true},"display_action":{"type":"string","nullable":true},"amount":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"store_credit_id":{"type":"string"},"originator_type":{"type":"string","nullable":true},"originator_id":{"type":"string","nullable":true}},"required":["id","action","authorization_code","display_action","amount","created_at","updated_at","store_credit_id","originator_type","originator_id"],"x-typelizer":true},"StoreCredit":{"type":"object","properties":{"id":{"type":"string"},"amount":{"type":"string"},"amount_used":{"type":"string"},"amount_remaining":{"type":"string"},"currency":{"type":"string"},"memo":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount_authorized":{"type":"string"},"outstanding":{"type":"boolean"},"customer_id":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true},"originator_type":{"type":"string","nullable":true},"originator_id":{"type":"string","nullable":true},"customer":{"$ref":"#/components/schemas/Customer"},"created_by":{"$ref":"#/components/schemas/AdminUser"}},"required":["id","amount","amount_used","amount_remaining","currency","memo","metadata","created_at","updated_at","amount_authorized","outstanding","customer_id","created_by_id","originator_type","originator_id"],"x-typelizer":true},"Store":{"type":"object","properties":{"id":{"type":"string"},"metadata":{"type":"object"},"name":{"type":"string"},"code":{"type":"string"},"default_currency":{"type":"string"},"default_locale":{"type":"string"},"default_country_code":{"type":"string","nullable":true},"mail_from_address":{"type":"string","nullable":true},"customer_support_email":{"type":"string","nullable":true},"new_order_notifications_email":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"order_routing_strategy":{"type":"string","description":"Order routing strategy. Built-in: rules. Extensions may register more."},"payout_provider":{"type":"string","nullable":true,"description":"Payout provider; null uses the installation default. Built-in: system. Provider gems register more (e.g. stripe)."},"admin_locale":{"type":"string","nullable":true},"timezone":{"type":"string"},"storefront_url":{"type":"string","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"unit_system":{"type":"string","enum":["metric","imperial"]},"storefront_access":{"type":"string","enum":["public","prices_hidden","login_required"]},"guest_checkout":{"type":"boolean"},"always_include_confirm_step":{"type":"boolean"},"company_field_enabled":{"type":"boolean"},"address_requires_company":{"type":"boolean"},"address_requires_phone":{"type":"boolean"},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"]},"track_inventory_levels":{"type":"boolean"},"stock_reservations_enabled":{"type":"boolean"},"low_stock_threshold":{"type":"number"},"tax_using_ship_address":{"type":"boolean"},"track_price_history":{"type":"boolean"},"show_products_without_price":{"type":"boolean"},"disable_sku_validation":{"type":"boolean"},"pricing_provider":{"type":"string"},"inventory_provider":{"type":"string"},"pricing_provider_failure_policy":{"type":"string","enum":["fallback","strict"]},"inventory_provider_failure_policy":{"type":"string","enum":["fallback","strict"]},"default_payouts_schedule_interval":{"type":"string","enum":["daily","weekly","biweekly","monthly","manual"]},"auto_approve_sellers":{"type":"boolean"},"auto_approve_seller_products":{"type":"boolean"},"send_seller_transactional_emails":{"type":"boolean"},"document_number_format":{"type":"string","enum":["sequential","random"]},"order_number_prefix":{"type":"string"},"order_number_suffix":{"type":"string"},"order_number_sequence_start":{"type":"number"},"limit_digital_download_count":{"type":"boolean"},"digital_asset_authorized_clicks":{"type":"number"},"limit_digital_download_days":{"type":"boolean"},"digital_asset_authorized_days":{"type":"number"},"send_consumer_transactional_emails":{"type":"boolean"},"email_accent_color":{"type":"string","nullable":true},"email_background_color":{"type":"string","nullable":true},"email_card_color":{"type":"string","nullable":true},"email_text_color":{"type":"string","nullable":true},"email_heading_color":{"type":"string","nullable":true},"email_font":{"type":"string","nullable":true,"enum":["inter","system","helvetica","georgia","roboto","lato","merriweather"]},"order_number_sequence_started":{"type":"boolean"},"default_minimum_payout_amount":{"type":"string","nullable":true},"default_commission_tax_rate":{"type":"string","nullable":true},"url":{"type":"string"},"api_url":{"type":"string"},"setup_tasks":{"type":"array","items":{"$ref":"#/components/schemas/SetupTask"}},"supported_currencies":{"type":"array","items":{"type":"string"}},"supported_locales":{"type":"array","items":{"type":"string"}},"available_locales":{"type":"array","items":{"type":"string"}},"logo_url":{"type":"string","nullable":true},"mailer_logo_url":{"type":"string","nullable":true}},"required":["id","metadata","name","code","default_currency","default_locale","default_country_code","mail_from_address","customer_support_email","new_order_notifications_email","created_at","updated_at","order_routing_strategy","payout_provider","admin_locale","timezone","storefront_url","weight_unit","unit_system","storefront_access","guest_checkout","always_include_confirm_step","company_field_enabled","address_requires_company","address_requires_phone","capture_method","track_inventory_levels","stock_reservations_enabled","low_stock_threshold","tax_using_ship_address","track_price_history","show_products_without_price","disable_sku_validation","pricing_provider","inventory_provider","pricing_provider_failure_policy","inventory_provider_failure_policy","default_payouts_schedule_interval","auto_approve_sellers","auto_approve_seller_products","send_seller_transactional_emails","document_number_format","order_number_prefix","order_number_suffix","order_number_sequence_start","limit_digital_download_count","digital_asset_authorized_clicks","limit_digital_download_days","digital_asset_authorized_days","send_consumer_transactional_emails","email_accent_color","email_background_color","email_card_color","email_text_color","email_heading_color","email_font","order_number_sequence_started","default_minimum_payout_amount","default_commission_tax_rate","url","api_url","setup_tasks","supported_currencies","supported_locales","available_locales","logo_url","mailer_logo_url"],"x-typelizer":true},"Supplier":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"contact_name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true},"postal_code":{"type":"string","nullable":true},"purchase_orders_count":{"type":"number"},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"deleted_at":{"type":"string","nullable":true},"can_be_deleted":{"type":"boolean"}},"required":["id","name","contact_name","email","phone","notes","address1","address2","city","state_name","state_code","country_code","postal_code","purchase_orders_count","metadata","created_at","updated_at","deleted_at","can_be_deleted"],"x-typelizer":true},"TaxCategory":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"tax_code":{"type":"string","nullable":true},"description":{"type":"string","nullable":true},"is_default":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","tax_code","description","is_default","created_at","updated_at"],"x-typelizer":true},"TaxExemptionCertificate":{"type":"object","properties":{"id":{"type":"string"},"certificate_number":{"type":"string"},"reason_code":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","verified","expired","revoked"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"issuing_authority":{"type":"string","nullable":true},"metadata":{"type":"object","nullable":true},"issued_at":{"type":"string"},"expires_at":{"type":"string"},"verified_at":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"company_id":{"type":"string"},"country_code":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"active":{"type":"boolean"},"lapsed":{"type":"boolean"},"can_be_deleted":{"type":"boolean"},"document_filename":{"type":"string","nullable":true},"document_byte_size":{"type":"number","nullable":true},"document_url":{"type":"string","nullable":true}},"required":["id","certificate_number","reason_code","status","issuing_authority","metadata","issued_at","expires_at","verified_at","created_at","updated_at","company_id","country_code","state_code","active","lapsed","can_be_deleted","document_filename","document_byte_size","document_url"],"x-typelizer":true},"TaxIdentifier":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","description":"Tax identifier kind, keyed to a registered validator. Built-in: eu_vat. Extensions may register more."},"value":{"type":"string"},"validation_status":{"type":"string","nullable":true,"enum":["pending","verified","unverified","unavailable","unsupported"]},"validation_evidence":{"type":"object","nullable":true},"source":{"type":"string","nullable":true,"enum":["override","company","customer"]},"validated_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"validatable":{"type":"boolean"},"customer_id":{"type":"string","nullable":true},"cart_id":{"type":"string","nullable":true},"order_id":{"type":"string","nullable":true}},"required":["id","kind","value","validation_status","validation_evidence","source","validated_at","created_at","updated_at","validatable","customer_id","cart_id","order_id"],"x-typelizer":true},"TaxLine":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"included":{"type":"boolean"},"credit":{"type":"boolean"},"rate":{"type":"string","nullable":true},"tax_rate_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"fee_id":{"type":"string","nullable":true},"return_line_item_id":{"type":"string","nullable":true},"claim_line_item_id":{"type":"string","nullable":true},"exchange_line_item_id":{"type":"string","nullable":true},"amount":{"type":"string"},"provider_id":{"type":"string","nullable":true},"metadata":{"type":"object","nullable":true},"taxability_reason":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"data":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"original_tax_line_id":{"type":"string","nullable":true}},"required":["id","label","included","credit","rate","tax_rate_id","line_item_id","fulfillment_id","fee_id","return_line_item_id","claim_line_item_id","exchange_line_item_id","amount","provider_id","metadata","taxability_reason","country_code","state_code","data","created_at","updated_at","original_tax_line_id"],"x-typelizer":true},"TaxRate":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"included_in_price":{"type":"boolean"},"show_rate_in_label":{"type":"boolean"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"deleted_at":{"type":"string","nullable":true},"rate":{"type":"string","nullable":true},"rate_percent":{"type":"string","nullable":true},"tax_category_id":{"type":"string","nullable":true},"store_id":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true}},"required":["id","name","included_in_price","show_rate_in_label","metadata","created_at","updated_at","deleted_at","rate","rate_percent","tax_category_id","store_id","country_code","state_code"],"x-typelizer":true},"Variant":{"type":"object","properties":{"id":{"type":"string"},"product_id":{"type":"string"},"sku":{"type":"string","nullable":true},"options_text":{"type":"string"},"track_inventory":{"type":"boolean"},"media_count":{"type":"number"},"preorder_ships_at":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true},"purchasable":{"type":"boolean"},"in_stock":{"type":"boolean"},"backorderable":{"type":"boolean"},"preorder":{"type":"boolean"},"weight":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"depth":{"type":"number","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"minimum_order_quantity":{"type":"number","nullable":true},"order_multiple":{"type":"number","nullable":true},"purchase_unit":{"type":"string","nullable":true,"enum":["unit","carton"]},"units_per_carton":{"type":"number","nullable":true},"price":{"$ref":"#/components/schemas/Price"},"original_price":{"allOf":[{"$ref":"#/components/schemas/Price"}],"nullable":true},"seller_id":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"},"primary_media":{"$ref":"#/components/schemas/Media"},"media":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"prior_price":{"allOf":[{"$ref":"#/components/schemas/PriceHistory"}],"nullable":true},"external_references":{"type":"object"},"metadata":{"type":"object"},"position":{"type":"number"},"cost_currency":{"type":"string","nullable":true},"barcode":{"type":"string","nullable":true},"backorder_limit":{"type":"number","nullable":true},"hs_code":{"type":"string","nullable":true},"country_of_origin":{"type":"string","nullable":true},"customs_description":{"type":"string","nullable":true},"carton_weight":{"type":"string","nullable":true},"cartons_per_pallet":{"type":"number","nullable":true},"deleted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"cost_price":{"type":"string","nullable":true},"preorderable":{"type":"boolean"},"tax_category_id":{"type":"string","nullable":true},"carton_package_type_id":{"type":"string","nullable":true},"units_per_pallet":{"type":"number","nullable":true},"available_stock":{"type":"number","nullable":true},"reserved_quantity":{"type":"number"},"total_on_hand":{"type":"number","nullable":true},"product_name":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"prices":{"type":"array","items":{"$ref":"#/components/schemas/Price"}},"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevel"}}},"required":["id","product_id","sku","options_text","track_inventory","media_count","preorder_ships_at","thumbnail_url","purchasable","in_stock","backorderable","preorder","weight","height","width","depth","weight_unit","dimensions_unit","minimum_order_quantity","order_multiple","purchase_unit","units_per_carton","price","original_price","seller_id","option_values","external_references","metadata","position","cost_currency","barcode","backorder_limit","hs_code","country_of_origin","customs_description","carton_weight","cartons_per_pallet","deleted_at","created_at","updated_at","cost_price","preorderable","tax_category_id","carton_package_type_id","units_per_pallet","available_stock","reserved_quantity","total_on_hand","product_name","delivery_profile_id"],"x-typelizer":true},"WebhookDelivery":{"type":"object","properties":{"id":{"type":"string"},"event_name":{"type":"string"},"event_id":{"type":"string","nullable":true},"response_code":{"type":"number","nullable":true},"execution_time":{"type":"number","nullable":true},"error_type":{"type":"string","nullable":true},"request_errors":{"type":"string","nullable":true},"response_body":{"type":"string","nullable":true},"success":{"type":"boolean","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivered_at":{"type":"string","nullable":true},"payload":{"type":"object","nullable":true},"webhook_endpoint_id":{"type":"string"},"webhook_endpoint_url":{"type":"string"}},"required":["id","event_name","event_id","response_code","execution_time","error_type","request_errors","response_body","success","created_at","updated_at","delivered_at","payload","webhook_endpoint_id","webhook_endpoint_url"],"x-typelizer":true},"WebhookEndpoint":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string","nullable":true},"url":{"type":"string"},"active":{"type":"boolean"},"subscriptions":{"type":"array","items":{"type":"string"}},"disabled_reason":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"disabled_at":{"type":"string","nullable":true},"secret_key":{"type":"string","nullable":true},"last_delivery_at":{"type":"string","nullable":true},"recent_delivery_count":{"type":"number"},"recent_failure_count":{"type":"number"},"total_delivery_count":{"type":"number"},"successful_delivery_count":{"type":"number"},"failed_delivery_count":{"type":"number"}},"required":["id","name","url","active","subscriptions","disabled_reason","created_at","updated_at","disabled_at","secret_key","last_delivery_at","recent_delivery_count","recent_failure_count","total_delivery_count","successful_delivery_count","failed_delivery_count"],"x-typelizer":true},"WebhookEvent":{"type":"object","properties":{"name":{"type":"string"},"group":{"type":"string"},"credential_permission":{"type":"string","nullable":true},"credential":{"type":"boolean"},"deprecated":{"type":"boolean"},"replaced_by":{"type":"string","nullable":true}},"required":["name","group","credential_permission","credential","deprecated","replaced_by"],"x-typelizer":true},"CommissionRuleCategoryRulePreferences":{"type":"object","properties":{"category_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^ctg_[A-Za-z0-9]+$","x-spree-prefix":"ctg"},"default":[]}},"additionalProperties":false},"CommissionRuleItemTotalRulePreferences":{"type":"object","properties":{"min_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"max_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"additionalProperties":false},"CommissionRuleProductRulePreferences":{"type":"object","properties":{},"additionalProperties":false},"CommissionRuleSellerRulePreferences":{"type":"object","properties":{"seller_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^sel_[A-Za-z0-9]+$","x-spree-prefix":"sel"},"default":[]}},"additionalProperties":false},"CommissionRulePreferences":{"description":"Settings of a commission rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/CommissionRuleCategoryRulePreferences"},{"$ref":"#/components/schemas/CommissionRuleItemTotalRulePreferences"},{"$ref":"#/components/schemas/CommissionRuleProductRulePreferences"},{"$ref":"#/components/schemas/CommissionRuleSellerRulePreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"category_rule":"#/components/schemas/CommissionRuleCategoryRulePreferences","item_total_rule":"#/components/schemas/CommissionRuleItemTotalRulePreferences","product_rule":"#/components/schemas/CommissionRuleProductRulePreferences","seller_rule":"#/components/schemas/CommissionRuleSellerRulePreferences"}},"DeliveryCalculatorDigitalDeliveryPreferences":{"type":"object","properties":{"amounts":{"type":"object","additionalProperties":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"default":{},"x-spree-property-names":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorFlatPercentItemTotalPreferences":{"type":"object","properties":{"flat_percent":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"}},"additionalProperties":false},"DeliveryCalculatorFlatRatePreferences":{"type":"object","properties":{"amounts":{"type":"object","additionalProperties":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"default":{},"x-spree-property-names":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorFlexiRatePreferences":{"type":"object","properties":{"first_item":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"additional_item":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"max_items":{"type":"integer","default":0},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorPerItemPreferences":{"type":"object","properties":{"amounts":{"type":"object","additionalProperties":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"default":{},"x-spree-property-names":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorPriceSackPreferences":{"type":"object","properties":{"minimal_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"normal_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"discount_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorPreferences":{"description":"Settings of a delivery calculator, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/DeliveryCalculatorDigitalDeliveryPreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorFlatPercentItemTotalPreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorFlatRatePreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorFlexiRatePreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorPerItemPreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorPriceSackPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"digital_delivery":"#/components/schemas/DeliveryCalculatorDigitalDeliveryPreferences","flat_percent_item_total":"#/components/schemas/DeliveryCalculatorFlatPercentItemTotalPreferences","flat_rate":"#/components/schemas/DeliveryCalculatorFlatRatePreferences","flexi_rate":"#/components/schemas/DeliveryCalculatorFlexiRatePreferences","per_item":"#/components/schemas/DeliveryCalculatorPerItemPreferences","price_sack":"#/components/schemas/DeliveryCalculatorPriceSackPreferences"}},"DeliveryMethodRuleChannelRulePreferences":{"type":"object","properties":{"channel_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^ch_[A-Za-z0-9]+$","x-spree-prefix":"ch"},"default":[]}},"additionalProperties":false},"DeliveryMethodRuleCompanyRulePreferences":{"type":"object","properties":{"company_orders_only":{"type":"boolean","default":true}},"additionalProperties":false},"DeliveryMethodRuleExcludedProductsRulePreferences":{"type":"object","properties":{},"additionalProperties":false},"DeliveryMethodRuleItemTotalRulePreferences":{"type":"object","properties":{"minimum_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"maximum_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"additionalProperties":false},"DeliveryMethodRuleVolumeRulePreferences":{"type":"object","properties":{"minimum_volume":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"maximum_volume":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"additionalProperties":false},"DeliveryMethodRuleWeightRulePreferences":{"type":"object","properties":{"minimum_weight":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"maximum_weight":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"additionalProperties":false},"DeliveryMethodRulePreferences":{"description":"Settings of a delivery method rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/DeliveryMethodRuleChannelRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleCompanyRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleExcludedProductsRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleItemTotalRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleVolumeRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleWeightRulePreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"channel_rule":"#/components/schemas/DeliveryMethodRuleChannelRulePreferences","company_rule":"#/components/schemas/DeliveryMethodRuleCompanyRulePreferences","excluded_products_rule":"#/components/schemas/DeliveryMethodRuleExcludedProductsRulePreferences","item_total_rule":"#/components/schemas/DeliveryMethodRuleItemTotalRulePreferences","volume_rule":"#/components/schemas/DeliveryMethodRuleVolumeRulePreferences","weight_rule":"#/components/schemas/DeliveryMethodRuleWeightRulePreferences"}},"IntegrationPreferences":{"description":"Settings of a integration, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{}},"OrderRoutingRuleDefaultLocationPreferences":{"type":"object","properties":{},"additionalProperties":false},"OrderRoutingRuleMinimizeSplitsPreferences":{"type":"object","properties":{},"additionalProperties":false},"OrderRoutingRulePreferredLocationPreferences":{"type":"object","properties":{},"additionalProperties":false},"OrderRoutingRulePreferences":{"description":"Settings of a order routing rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/OrderRoutingRuleDefaultLocationPreferences"},{"$ref":"#/components/schemas/OrderRoutingRuleMinimizeSplitsPreferences"},{"$ref":"#/components/schemas/OrderRoutingRulePreferredLocationPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"default_location":"#/components/schemas/OrderRoutingRuleDefaultLocationPreferences","minimize_splits":"#/components/schemas/OrderRoutingRuleMinimizeSplitsPreferences","preferred_location":"#/components/schemas/OrderRoutingRulePreferredLocationPreferences"}},"PaymentMethodBogusPreferences":{"type":"object","properties":{"dummy_key":{"type":"string","default":"PUBLICKEY123"},"dummy_secret_key":{"type":"string","x-spree-secret":true,"nullable":true}},"additionalProperties":false},"PaymentMethodCheckPreferences":{"type":"object","properties":{},"additionalProperties":false},"PaymentMethodCustomPaymentSourceMethodPreferences":{"type":"object","properties":{},"additionalProperties":false},"PaymentMethodStoreCreditPreferences":{"type":"object","properties":{},"additionalProperties":false},"PaymentMethodPreferences":{"description":"Settings of a payment method, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/PaymentMethodBogusPreferences"},{"$ref":"#/components/schemas/PaymentMethodCheckPreferences"},{"$ref":"#/components/schemas/PaymentMethodCustomPaymentSourceMethodPreferences"},{"$ref":"#/components/schemas/PaymentMethodStoreCreditPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"bogus":"#/components/schemas/PaymentMethodBogusPreferences","check":"#/components/schemas/PaymentMethodCheckPreferences","custom_payment_source_method":"#/components/schemas/PaymentMethodCustomPaymentSourceMethodPreferences","store_credit":"#/components/schemas/PaymentMethodStoreCreditPreferences"}},"PriceRuleChannelRulePreferences":{"type":"object","properties":{"channel_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^ch_[A-Za-z0-9]+$","x-spree-prefix":"ch"},"default":[]}},"additionalProperties":false},"PriceRuleCustomerGroupRulePreferences":{"type":"object","properties":{"customer_group_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^cg_[A-Za-z0-9]+$","x-spree-prefix":"cg"},"default":[]}},"additionalProperties":false},"PriceRuleMarketRulePreferences":{"type":"object","properties":{"market_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^mkt_[A-Za-z0-9]+$","x-spree-prefix":"mkt"},"default":[]}},"additionalProperties":false},"PriceRuleUserRulePreferences":{"type":"object","properties":{"user_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^cust_[A-Za-z0-9]+$","x-spree-prefix":"cust"},"default":[]}},"additionalProperties":false},"PriceRuleVolumeRulePreferences":{"type":"object","properties":{"min_quantity":{"type":"integer","default":1},"max_quantity":{"type":"integer","nullable":true}},"additionalProperties":false},"PriceRulePreferences":{"description":"Settings of a price rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/PriceRuleChannelRulePreferences"},{"$ref":"#/components/schemas/PriceRuleCustomerGroupRulePreferences"},{"$ref":"#/components/schemas/PriceRuleMarketRulePreferences"},{"$ref":"#/components/schemas/PriceRuleUserRulePreferences"},{"$ref":"#/components/schemas/PriceRuleVolumeRulePreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"channel_rule":"#/components/schemas/PriceRuleChannelRulePreferences","customer_group_rule":"#/components/schemas/PriceRuleCustomerGroupRulePreferences","market_rule":"#/components/schemas/PriceRuleMarketRulePreferences","user_rule":"#/components/schemas/PriceRuleUserRulePreferences","volume_rule":"#/components/schemas/PriceRuleVolumeRulePreferences"}},"PromotionCalculatorFlatPercentItemTotalPreferences":{"type":"object","properties":{"flat_percent":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"}},"additionalProperties":false},"PromotionCalculatorFlatRatePreferences":{"type":"object","properties":{"amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"},"apply_only_on_full_priced_items":{"type":"boolean","default":false}},"additionalProperties":false},"PromotionCalculatorFlexiRatePreferences":{"type":"object","properties":{"first_item":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"additional_item":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"max_items":{"type":"integer","default":0},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"},"apply_only_on_full_priced_items":{"type":"boolean","default":false}},"additionalProperties":false},"PromotionCalculatorPercentOnLineItemPreferences":{"type":"object","properties":{"percent":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"apply_only_on_full_priced_items":{"type":"boolean","default":false}},"additionalProperties":false},"PromotionCalculatorTieredFlatRatePreferences":{"type":"object","properties":{"tiers":{"type":"array","items":{"type":"object","properties":{"threshold":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"value":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$"}},"required":["threshold","value"],"additionalProperties":false},"default":[]},"base_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"PromotionCalculatorTieredPercentPreferences":{"type":"object","properties":{"tiers":{"type":"array","items":{"type":"object","properties":{"threshold":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"value":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$"}},"required":["threshold","value"],"additionalProperties":false},"default":[]},"base_percent":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"}},"additionalProperties":false},"PromotionCalculatorPreferences":{"description":"Settings of a promotion calculator, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/PromotionCalculatorFlatPercentItemTotalPreferences"},{"$ref":"#/components/schemas/PromotionCalculatorFlatRatePreferences"},{"$ref":"#/components/schemas/PromotionCalculatorFlexiRatePreferences"},{"$ref":"#/components/schemas/PromotionCalculatorPercentOnLineItemPreferences"},{"$ref":"#/components/schemas/PromotionCalculatorTieredFlatRatePreferences"},{"$ref":"#/components/schemas/PromotionCalculatorTieredPercentPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"flat_percent_item_total":"#/components/schemas/PromotionCalculatorFlatPercentItemTotalPreferences","flat_rate":"#/components/schemas/PromotionCalculatorFlatRatePreferences","flexi_rate":"#/components/schemas/PromotionCalculatorFlexiRatePreferences","percent_on_line_item":"#/components/schemas/PromotionCalculatorPercentOnLineItemPreferences","tiered_flat_rate":"#/components/schemas/PromotionCalculatorTieredFlatRatePreferences","tiered_percent":"#/components/schemas/PromotionCalculatorTieredPercentPreferences"}},"PromotionRuleCategoryPreferences":{"type":"object","properties":{"match_policy":{"type":"string","enum":["any","all"],"default":"any"}},"additionalProperties":false},"PromotionRuleChannelPreferences":{"type":"object","properties":{"channel_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^ch_[A-Za-z0-9]+$","x-spree-prefix":"ch"},"default":[]}},"additionalProperties":false},"PromotionRuleCountryPreferences":{"type":"object","properties":{"country_codes":{"type":"array","items":{"type":"string","format":"iso-country","pattern":"^[A-Z]{2}$"},"default":[]},"country_id":{"type":"integer","nullable":true},"country_code":{"type":"string","format":"iso-country","pattern":"^[A-Z]{2}$","nullable":true}},"additionalProperties":false},"PromotionRuleCurrencyPreferences":{"type":"object","properties":{"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$","nullable":true}},"additionalProperties":false},"PromotionRuleCustomerPreferences":{"type":"object","properties":{},"additionalProperties":false},"PromotionRuleCustomerGroupPreferences":{"type":"object","properties":{"customer_group_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^cg_[A-Za-z0-9]+$","x-spree-prefix":"cg"},"default":[]}},"additionalProperties":false},"PromotionRuleCustomerLoggedInPreferences":{"type":"object","properties":{},"additionalProperties":false},"PromotionRuleFirstOrderPreferences":{"type":"object","properties":{},"additionalProperties":false},"PromotionRuleItemTotalPreferences":{"type":"object","properties":{"amount_min":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"100"},"operator_min":{"type":"string","default":">"},"amount_max":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"operator_max":{"type":"string","default":"<"}},"additionalProperties":false},"PromotionRuleMarketPreferences":{"type":"object","properties":{"market_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^mkt_[A-Za-z0-9]+$","x-spree-prefix":"mkt"},"default":[]}},"additionalProperties":false},"PromotionRuleOneUsePerUserPreferences":{"type":"object","properties":{},"additionalProperties":false},"PromotionRuleOptionValuePreferences":{"type":"object","properties":{"match_policy":{"type":"string","enum":["any"],"default":"any"},"eligible_values":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^optval_[A-Za-z0-9]+$","x-spree-prefix":"optval"},"default":[]}},"additionalProperties":false},"PromotionRuleProductPreferences":{"type":"object","properties":{"match_policy":{"type":"string","enum":["any","all","none"],"default":"any"}},"additionalProperties":false},"PromotionRulePreferences":{"description":"Settings of a promotion rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/PromotionRuleCategoryPreferences"},{"$ref":"#/components/schemas/PromotionRuleChannelPreferences"},{"$ref":"#/components/schemas/PromotionRuleCountryPreferences"},{"$ref":"#/components/schemas/PromotionRuleCurrencyPreferences"},{"$ref":"#/components/schemas/PromotionRuleCustomerPreferences"},{"$ref":"#/components/schemas/PromotionRuleCustomerGroupPreferences"},{"$ref":"#/components/schemas/PromotionRuleCustomerLoggedInPreferences"},{"$ref":"#/components/schemas/PromotionRuleFirstOrderPreferences"},{"$ref":"#/components/schemas/PromotionRuleItemTotalPreferences"},{"$ref":"#/components/schemas/PromotionRuleMarketPreferences"},{"$ref":"#/components/schemas/PromotionRuleOneUsePerUserPreferences"},{"$ref":"#/components/schemas/PromotionRuleOptionValuePreferences"},{"$ref":"#/components/schemas/PromotionRuleProductPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"category":"#/components/schemas/PromotionRuleCategoryPreferences","channel":"#/components/schemas/PromotionRuleChannelPreferences","country":"#/components/schemas/PromotionRuleCountryPreferences","currency":"#/components/schemas/PromotionRuleCurrencyPreferences","customer":"#/components/schemas/PromotionRuleCustomerPreferences","customer_group":"#/components/schemas/PromotionRuleCustomerGroupPreferences","customer_logged_in":"#/components/schemas/PromotionRuleCustomerLoggedInPreferences","first_order":"#/components/schemas/PromotionRuleFirstOrderPreferences","item_total":"#/components/schemas/PromotionRuleItemTotalPreferences","market":"#/components/schemas/PromotionRuleMarketPreferences","one_use_per_user":"#/components/schemas/PromotionRuleOneUsePerUserPreferences","option_value":"#/components/schemas/PromotionRuleOptionValuePreferences","product":"#/components/schemas/PromotionRuleProductPreferences"}},"SellerRequirementAcceptTermsPreferences":{"type":"object","properties":{"terms_body":{"type":"string","x-spree-widget":"textarea","nullable":true},"terms_effective_from":{"type":"string","format":"date","nullable":true},"terms_url":{"type":"string","nullable":true}},"additionalProperties":false},"SellerRequirementAttestationPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementBillingAddressPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementCompleteProfilePreferences":{"type":"object","properties":{"require_about":{"type":"boolean","default":true},"require_logo":{"type":"boolean","default":true},"require_cover_photo":{"type":"boolean","default":false},"require_contact_email":{"type":"boolean","default":true}},"additionalProperties":false},"SellerRequirementDeliveryMethodPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementDocumentPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementMinimumProductsPreferences":{"type":"object","properties":{"minimum_count":{"type":"integer","default":1}},"additionalProperties":false},"SellerRequirementOperatorReviewPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementPackageTypePreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementPayoutAccountPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementPolicyPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementRequiredCustomFieldsPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementReturnsAddressPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementPreferences":{"description":"Settings of a seller requirement, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/SellerRequirementAcceptTermsPreferences"},{"$ref":"#/components/schemas/SellerRequirementAttestationPreferences"},{"$ref":"#/components/schemas/SellerRequirementBillingAddressPreferences"},{"$ref":"#/components/schemas/SellerRequirementCompleteProfilePreferences"},{"$ref":"#/components/schemas/SellerRequirementDeliveryMethodPreferences"},{"$ref":"#/components/schemas/SellerRequirementDocumentPreferences"},{"$ref":"#/components/schemas/SellerRequirementMinimumProductsPreferences"},{"$ref":"#/components/schemas/SellerRequirementOperatorReviewPreferences"},{"$ref":"#/components/schemas/SellerRequirementPackageTypePreferences"},{"$ref":"#/components/schemas/SellerRequirementPayoutAccountPreferences"},{"$ref":"#/components/schemas/SellerRequirementPolicyPreferences"},{"$ref":"#/components/schemas/SellerRequirementRequiredCustomFieldsPreferences"},{"$ref":"#/components/schemas/SellerRequirementReturnsAddressPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"accept_terms":"#/components/schemas/SellerRequirementAcceptTermsPreferences","attestation":"#/components/schemas/SellerRequirementAttestationPreferences","billing_address":"#/components/schemas/SellerRequirementBillingAddressPreferences","complete_profile":"#/components/schemas/SellerRequirementCompleteProfilePreferences","delivery_method":"#/components/schemas/SellerRequirementDeliveryMethodPreferences","document":"#/components/schemas/SellerRequirementDocumentPreferences","minimum_products":"#/components/schemas/SellerRequirementMinimumProductsPreferences","operator_review":"#/components/schemas/SellerRequirementOperatorReviewPreferences","package_type":"#/components/schemas/SellerRequirementPackageTypePreferences","payout_account":"#/components/schemas/SellerRequirementPayoutAccountPreferences","policy":"#/components/schemas/SellerRequirementPolicyPreferences","required_custom_fields":"#/components/schemas/SellerRequirementRequiredCustomFieldsPreferences","returns_address":"#/components/schemas/SellerRequirementReturnsAddressPreferences"}},"DeliveryMethodCalculator":{"type":"object","description":"How the delivery method prices a shipment","properties":{"type":{"type":"string","description":"Wire shorthand for the calculator subclass"},"preferences":{"$ref":"#/components/schemas/DeliveryCalculatorPreferences"}},"required":["type","preferences"]},"PromotionActionCalculator":{"type":"object","description":"The action's nested calculator (when the action carries one — null for actions like `free_shipping`)","properties":{"type":{"type":"string","description":"Wire shorthand for the calculator subclass"},"preferences":{"$ref":"#/components/schemas/PromotionCalculatorPreferences"}},"required":["type","preferences"]},"AddressInputParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"company":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"phone":{"type":"string"},"label":{"type":"string"},"zipcode":{"type":"string","description":"Legacy spelling of `postal_code`; send only one of the two."},"country_code":{"type":"string","description":"ISO 3166-1 alpha-2 code, such as `US`."},"state_code":{"type":"string","description":"The state or province abbreviation, such as `NY`."},"state_name":{"type":"string","description":"For countries without states in the database."},"alternative_phone":{"type":"string"}}},"AdminUserUpdateParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"role_ids":{"type":"array","items":{"type":"string"},"description":"Role IDs of the current store the user should hold. Replaces the user's roles on this store; an empty list removes them all."}}},"AllowedOriginCreateParams":{"type":"object","properties":{"origin":{"type":"string","description":"Origin to allow in admin CORS preflight checks: a bare `scheme://host[:port]` (no path, query or fragment) using `http` or `https`."}},"required":["origin"]},"AllowedOriginUpdateParams":{"type":"object","properties":{"origin":{"type":"string","description":"Origin to allow in admin CORS preflight checks: a bare `scheme://host[:port]` (no path, query or fragment) using `http` or `https`."}}},"ApiKeyCreateParams":{"type":"object","properties":{"name":{"type":"string"},"key_type":{"type":"string","enum":["publishable","secret"]},"scopes":{"type":"array","items":{"type":"string"},"description":"Required for secret keys. You can only grant scopes you hold yourself. Fixed once created: to change them, create a new key and revoke the old one."},"channel_id":{"type":"string","description":"Binds a publishable key to one channel of the store (`ch_...`), so it rejects requests for other channels. Fixed once created; omit it for a store-wide key."}},"required":["name","key_type"]},"ApiKeyUpdateParams":{"type":"object","properties":{"name":{"type":"string"}},"required":["name"]},"BulkTagsParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"},"description":"The records to change. Records the caller cannot update are skipped; an empty list changes nothing."},"tags":{"type":"array","items":{"type":"string"}}},"required":["ids","tags"]},"CatalogAssignParams":{"type":"object","properties":{"assignable_type":{"type":"string","enum":["customer_group","company"],"description":"Buyer audiences only. A company assignment covers its subtree."},"assignable_id":{"type":"string"}},"required":["assignable_type","assignable_id"]},"CatalogAssignmentParams":{"type":"object","properties":{"assignable_type":{"type":"string","enum":["customer_group","company"],"description":"Buyer audiences only. A company assignment covers its subtree."},"assignable_id":{"type":"string"}},"required":["assignable_type","assignable_id"]},"CatalogOrderMinimumParams":{"type":"object","properties":{"currency":{"type":"string","description":"ISO 4217 code. Required on create; one minimum per currency."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"}}},"CatalogParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","description":"Internal note on what the agreement is, never shown to shoppers.","nullable":true},"active":{"type":"boolean"},"position":{"type":"integer"},"minimum_order_quantity":{"type":"integer","description":"The catalog-wide quantity terms, between a variant's own rule and a per-variant override. Null leaves the field to the variant's own rule.","nullable":true},"order_multiple":{"type":"integer","description":"The catalog-wide quantity terms, between a variant's own rule and a per-variant override. Null leaves the field to the variant's own rule.","nullable":true},"metadata":{"type":"object","additionalProperties":true},"assignments":{"type":"array","items":{"$ref":"#/components/schemas/CatalogAssignmentParams"},"description":"The whole audience. An entry left out is withdrawn; omitting the key leaves the audience alone."},"order_minimums":{"type":"array","items":{"$ref":"#/components/schemas/CatalogOrderMinimumParams"},"description":"The whole order-minimum set. A currency left out has its minimum lifted; omitting the key leaves them alone."},"price_list":{"allOf":[{"$ref":"#/components/schemas/CatalogPriceListParams"}],"description":"The price list this catalog prices through, written inline: an object creates the owned list or updates it. Null deletes the list (a soft delete). Omit the key, or send `{}`, to leave the pricing alone. A catalog with an empty assortment prices without hiding anything; curate or import products to make it restrictive.","nullable":true}}},"CatalogPriceListParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"status":{"type":"string"},"match_policy":{"type":"string"},"starts_at":{"type":"string","format":"date-time","nullable":true},"ends_at":{"type":"string","format":"date-time","nullable":true},"price_adjustment_percentage":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Signed: negative discounts off base prices, positive marks up.","nullable":true},"adjust_compare_at":{"type":"boolean"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PriceListRuleParams"},"description":"Contextual rules, in practice a `volume_rule`. Audience rules are left as they are, and an empty list clears the contextual rules."},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceListPriceOverrideParams"},"description":"Explicit per-variant amounts. An empty list clears them, which is what switching to a percentage sends."},"price_adjustment_tiers":{"type":"array","items":{"$ref":"#/components/schemas/PriceAdjustmentTierParams"},"description":"Quantity bands on the percentage. The payload is the whole ladder, so an empty list clears it."}}},"CatalogProductTermsParams":{"type":"object","properties":{"terms":{"type":"object","additionalProperties":true,"description":"Quantity terms keyed by product: `{ minimum_order_quantity, order_multiple }`, each a whole number or null. A product whose pair is both null has its terms cleared; a product not yet in the assortment is added."}},"required":["terms"]},"CategoryCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"parent_id":{"type":"string","description":"The parent category. Omitted or null, a new category goes to the top level and an existing one keeps its parent: moving one to the top level is the reposition endpoint.","nullable":true},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"permalink":{"type":"string"},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the landscape image, or null to remove it.","nullable":true},"square_image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the square image, or null to remove it.","nullable":true},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}},"required":["name"]},"CategoryRepositionParams":{"type":"object","properties":{"new_parent_id":{"type":"string","description":"The new parent. Omit or null to move the category to the top level.","nullable":true},"new_position":{"type":"integer","description":"0-based index among the new parent's children."}},"required":["new_position"]},"CategoryUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"parent_id":{"type":"string","description":"The parent category. Omitted or null, a new category goes to the top level and an existing one keeps its parent: moving one to the top level is the reposition endpoint.","nullable":true},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"permalink":{"type":"string"},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the landscape image, or null to remove it.","nullable":true},"square_image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the square image, or null to remove it.","nullable":true},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}}},"ChannelAddProductsParams":{"type":"object","properties":{"product_ids":{"type":"array","items":{"type":"string"}},"published_at":{"type":"string","format":"date-time","description":"When the publications go live. Null means immediately.","nullable":true},"unpublished_at":{"type":"string","format":"date-time","description":"When the publications come down. Null means never.","nullable":true}},"required":["product_ids"]},"ChannelCreateParams":{"type":"object","properties":{"name":{"type":"string"},"code":{"type":"string","description":"URL-safe slug, derived from `name` when blank (`Point of Sale` becomes `point-of-sale`)."},"active":{"type":"boolean"},"default":{"type":"boolean"},"order_routing_strategy":{"type":"string","description":"Order routing strategy shorthand (built-in: `rules`). Null inherits the store setting.","nullable":true},"storefront_access":{"type":"string","enum":["public","prices_hidden","login_required"],"description":"What anonymous visitors can see. Null inherits the store setting.","nullable":true},"guest_checkout":{"type":"boolean","description":"Whether guests can check out without an account. Null inherits the store setting.","nullable":true},"default_catalog_id":{"type":"string","description":"Catalog (`cat_...`) shown to shoppers no company or customer group catalog covers. Null means every product published on the channel.","nullable":true},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Stock locations (`sloc_...`) that fulfill this channel. Replaces the whole set; an empty list means every location of the store."}},"required":["name"]},"ChannelRemoveProductsParams":{"type":"object","properties":{"product_ids":{"type":"array","items":{"type":"string"}}},"required":["product_ids"]},"ChannelUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"code":{"type":"string","description":"URL-safe slug, derived from `name` when blank (`Point of Sale` becomes `point-of-sale`)."},"active":{"type":"boolean"},"default":{"type":"boolean"},"order_routing_strategy":{"type":"string","description":"Order routing strategy shorthand (built-in: `rules`). Null inherits the store setting.","nullable":true},"storefront_access":{"type":"string","enum":["public","prices_hidden","login_required"],"description":"What anonymous visitors can see. Null inherits the store setting.","nullable":true},"guest_checkout":{"type":"boolean","description":"Whether guests can check out without an account. Null inherits the store setting.","nullable":true},"default_catalog_id":{"type":"string","description":"Catalog (`cat_...`) shown to shoppers no company or customer group catalog covers. Null means every product published on the channel.","nullable":true},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Stock locations (`sloc_...`) that fulfill this channel. Replaces the whole set; an empty list means every location of the store."}}},"ClaimCancelParams":{"type":"object","properties":{"reason":{"type":"string","description":"A note on why the claim was canceled."}}},"ClaimCreateParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"line_item_id":{"type":"string"},"quantity":{"type":"integer"},"description":{"type":"string"},"send_replacement":{"type":"boolean"},"replacement_variant_id":{"type":"string","description":"Defaults to the variant that was bought."},"refund_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"}},"required":["line_item_id","quantity"]},"description":"Affected items, and how each should be made right."},"reason_id":{"type":"string","description":"One of the store's claim reasons."},"memo":{"type":"string"}},"required":["items"]},"ClaimDenyParams":{"type":"object","properties":{"reason":{"type":"string","description":"Recorded on the claim for the customer."}}},"ClaimResolveParams":{"type":"object","properties":{"resolution":{"type":"string","enum":["refund","replacement","refund_and_replacement"],"description":"Money back, a replacement shipment, or both."},"refund_method":{"type":"string","enum":["original_payment","store_credit"],"description":"Defaults to `store_credit`."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Defaults to the claim total."},"replacement_line_item_ids":{"type":"array","items":{"type":"string"},"description":"Which claim lines to send a replacement for. Omit to keep what the claim was opened with."}},"required":["resolution"]},"ClaimUpdateParams":{"type":"object","properties":{"reason_id":{"type":"string","description":"One of the store's claim reasons."},"memo":{"type":"string"},"metadata":{"type":"object","additionalProperties":true}}},"CollectionCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"permalink":{"type":"string"},"position":{"type":"integer","description":"1-based position among the store's collections; the server shifts its siblings. The nested products reposition endpoints, unlike this, take 0-based indexes."},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the landscape image, or null to remove it.","nullable":true},"square_image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the square image, or null to remove it.","nullable":true},"automatic":{"type":"boolean","description":"When true, membership is materialized from `rules` instead of curated by hand."},"rules_match_policy":{"type":"string","enum":["all","any"],"description":"Whether a product must match all rules or any of them. Defaults to `all`."},"sort_order":{"type":"string","enum":["manual","best_selling","price asc","price desc","available_on desc","available_on asc","name asc","name desc"],"description":"Default product sort for the storefront listing; a shopper's own sort wins. Defaults to `manual`."},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CollectionRuleParams"},"description":"The complete desired rule set. Entries with an `id` update, entries without one are created, and existing rules left out are removed."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}},"required":["name"]},"CollectionRuleParams":{"type":"object","properties":{"id":{"type":"string","description":"Omit to create a new rule."},"type":{"type":"string","description":"Wire shorthand for the rule kind, from the collection rule types endpoint."},"value":{"type":"string"},"match_policy":{"type":"string","enum":["is_equal_to","is_not_equal_to","contains","does_not_contain"]}}},"CollectionUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"permalink":{"type":"string"},"position":{"type":"integer","description":"1-based position among the store's collections; the server shifts its siblings. The nested products reposition endpoints, unlike this, take 0-based indexes."},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the landscape image, or null to remove it.","nullable":true},"square_image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the square image, or null to remove it.","nullable":true},"automatic":{"type":"boolean","description":"When true, membership is materialized from `rules` instead of curated by hand."},"rules_match_policy":{"type":"string","enum":["all","any"],"description":"Whether a product must match all rules or any of them. Defaults to `all`."},"sort_order":{"type":"string","enum":["manual","best_selling","price asc","price desc","available_on desc","available_on asc","name asc","name desc"],"description":"Default product sort for the storefront listing; a shopper's own sort wins. Defaults to `manual`."},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CollectionRuleParams"},"description":"The complete desired rule set. Entries with an `id` update, entries without one are created, and existing rules left out are removed."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}}},"CommissionRateCreateParams":{"type":"object","properties":{"name":{"type":"string"},"code":{"type":"string","description":"Your own identifier for this rate; unique per store.","nullable":true},"enabled":{"type":"boolean"},"position":{"type":"integer","description":"Place in the list. Rates resolve top-down and the first whose rules match wins, so 1 is tried first. New rates are created at the top; send this to move one. A rate with no rules matches every sale, so the marketplace default belongs at the bottom."},"kind":{"type":"string","enum":["percentage","fixed"],"description":"`percentage` charges a share of the sale; `fixed` charges a flat fee."},"value":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"A percentage (10 = 10%) or a flat amount, per `kind`."},"tax_inclusive":{"type":"boolean","description":"Charge on the price including the customer's VAT. Left off, commission is charged on the seller's net revenue, which is the usual basis where the fee is taxed as its own supply."},"include_shipping":{"type":"boolean","description":"Also charge commission on the seller's delivery revenue. Percentage rates only."},"commission_tax_rate":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"VAT on the commission itself, as a fraction rather than a percentage. Null lets the store's tax engine answer for the seller's jurisdiction.","nullable":true},"metadata":{"type":"object","additionalProperties":true},"amounts":{"type":"object","additionalProperties":true,"description":"What a flat fee charges, keyed by currency, as decimal strings. A sale in a currency with no amount falls to the next matching rate. Replaces the whole set."},"bounds":{"type":"object","additionalProperties":true,"description":"The floor and cap a percentage charges within, keyed by currency: `{ min_amount, max_amount }` decimal strings. A sale in a currency with no bounds is charged unbounded. Replaces the whole set."},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CommissionRuleDraftParams"},"description":"The full targeting; what you send replaces what the rate holds."}},"required":["name","kind","value"]},"CommissionRateUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"code":{"type":"string","description":"Your own identifier for this rate; unique per store.","nullable":true},"enabled":{"type":"boolean"},"position":{"type":"integer","description":"Place in the list. Rates resolve top-down and the first whose rules match wins, so 1 is tried first. New rates are created at the top; send this to move one. A rate with no rules matches every sale, so the marketplace default belongs at the bottom."},"kind":{"type":"string","enum":["percentage","fixed"],"description":"`percentage` charges a share of the sale; `fixed` charges a flat fee."},"value":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"A percentage (10 = 10%) or a flat amount, per `kind`."},"tax_inclusive":{"type":"boolean","description":"Charge on the price including the customer's VAT. Left off, commission is charged on the seller's net revenue, which is the usual basis where the fee is taxed as its own supply."},"include_shipping":{"type":"boolean","description":"Also charge commission on the seller's delivery revenue. Percentage rates only."},"commission_tax_rate":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"VAT on the commission itself, as a fraction rather than a percentage. Null lets the store's tax engine answer for the seller's jurisdiction.","nullable":true},"metadata":{"type":"object","additionalProperties":true},"amounts":{"type":"object","additionalProperties":true,"description":"What a flat fee charges, keyed by currency, as decimal strings. A sale in a currency with no amount falls to the next matching rate. Replaces the whole set."},"bounds":{"type":"object","additionalProperties":true,"description":"The floor and cap a percentage charges within, keyed by currency: `{ min_amount, max_amount }` decimal strings. A sale in a currency with no bounds is charged unbounded. Replaces the whole set."},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CommissionRuleDraftParams"},"description":"The full targeting; what you send replaces what the rate holds."}}},"CommissionRuleDraftParams":{"type":"object","properties":{"id":{"type":"string","description":"Present for an existing rule; omit to create one.","nullable":true},"type":{"type":"string","description":"A kind from `GET /commission_rates/rule_types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Configuration for the kind, per its type's `schema`."},"product_ids":{"type":"array","items":{"type":"string"},"description":"For kinds that name products, which are kept outside preferences."}},"required":["type"]},"CompanyAddressParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"company":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"phone":{"type":"string"},"label":{"type":"string"},"zipcode":{"type":"string","description":"Legacy spelling of `postal_code`; send only one of the two."},"country_code":{"type":"string","description":"ISO 3166-1 alpha-2 code, such as `US`."},"state_code":{"type":"string","description":"The state or province abbreviation, such as `NY`."},"state_name":{"type":"string","description":"For countries without states in the database."},"default_billing":{"type":"boolean","description":"True makes this the default address of that kind, false gives the slot up, and leaving it out keeps the current default."},"default_shipping":{"type":"boolean","description":"True makes this the default address of that kind, false gives the slot up, and leaving it out keeps the current default."}}},"CompanyMembershipCreateParams":{"type":"object","properties":{"customer_email":{"type":"string","description":"An existing customer becomes a member immediately; an unknown email becomes an invitation, and the response is an invitation instead of a membership."},"metadata":{"type":"object","additionalProperties":true}},"required":["customer_email"]},"CompanyParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string","description":"Required when creating."},"kind":{"type":"string","enum":["company","division"],"description":"`company` is a legal entity (may hold tax registrations), `division` an organizational unit. Roots must be `company`."},"parent_id":{"type":"string","description":"The parent node. Omit or null for a root.","nullable":true},"po_number_required":{"type":"boolean","description":"Whether this buyer's own procurement process demands a PO reference on every order: checkout asks for one and refuses to complete without it."},"metadata":{"type":"object","additionalProperties":true}}},"CustomFieldCreateParams":{"type":"object","properties":{"custom_field_definition_id":{"type":"string"},"value":{"description":"A value matching the definition's `field_type`: a scalar for text, number and boolean fields; a list or a hash for JSON fields."}},"required":["custom_field_definition_id","value"]},"CustomFieldDefinitionCreateParams":{"type":"object","properties":{"namespace":{"type":"string","description":"Defaults to `custom`."},"key":{"type":"string"},"label":{"type":"string","description":"Human-readable name; defaults to the titleized `key`."},"field_type":{"type":"string","description":"Custom field type token (`short_text`, `long_text`, `rich_text`, `number`, …). An extension type that has no token is named by its registered class instead."},"resource_type":{"type":"string","description":"Shorthand of the resource the field attaches to, from the resource types endpoint."},"storefront_visible":{"type":"boolean","description":"When false, the definition is admin-only and never exposed in the Store API."},"searchable":{"type":"boolean","description":"Include values in storefront product text search. Supported for `short_text`, `long_text` and `number` fields; other types are refused."},"sortable":{"type":"boolean","description":"Allow storefront product listings to sort by this field (`sort=cf_{namespace}_{key}`). Supported for `short_text` and `number` fields; other types are refused."}},"required":["key","field_type","resource_type"]},"CustomFieldDefinitionUpdateParams":{"type":"object","properties":{"namespace":{"type":"string","description":"Defaults to `custom`."},"key":{"type":"string"},"label":{"type":"string","description":"Human-readable name; defaults to the titleized `key`."},"field_type":{"type":"string","description":"Custom field type token (`short_text`, `long_text`, `rich_text`, `number`, …). An extension type that has no token is named by its registered class instead."},"resource_type":{"type":"string","description":"Shorthand of the resource the field attaches to, from the resource types endpoint."},"storefront_visible":{"type":"boolean","description":"When false, the definition is admin-only and never exposed in the Store API."},"searchable":{"type":"boolean","description":"Include values in storefront product text search. Supported for `short_text`, `long_text` and `number` fields; other types are refused."},"sortable":{"type":"boolean","description":"Allow storefront product listings to sort by this field (`sort=cf_{namespace}_{key}`). Supported for `short_text` and `number` fields; other types are refused."}}},"CustomFieldUpdateParams":{"type":"object","properties":{"value":{"description":"A value matching the definition's `field_type`: a scalar for text, number and boolean fields; a list or a hash for JSON fields."}},"required":["value"]},"CustomFieldValueParams":{"type":"object","properties":{"id":{"type":"string"},"custom_field_definition_id":{"type":"string"},"value":{"description":"A scalar for text, number and boolean fields; a list or a hash for JSON fields."}}},"CustomerAddressParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"company":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"phone":{"type":"string"},"label":{"type":"string"},"zipcode":{"type":"string","description":"Legacy spelling of `postal_code`; send only one of the two."},"country_code":{"type":"string","description":"ISO 3166-1 alpha-2 code, such as `US`."},"state_code":{"type":"string","description":"The state or province abbreviation, such as `NY`."},"state_name":{"type":"string","description":"For countries without states in the database."},"alternative_phone":{"type":"string"},"quick_checkout":{"type":"boolean"},"is_default_billing":{"type":"boolean","description":"Makes this the customer's default address of that kind."},"is_default_shipping":{"type":"boolean","description":"Makes this the customer's default address of that kind."}}},"CustomerBulkGroupsParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"customer_group_ids":{"type":"array","items":{"type":"string"},"description":"Groups from other stores are ignored."}},"required":["ids","customer_group_ids"]},"CustomerCreateParams":{"type":"object","properties":{"email":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"phone":{"type":"string"},"password":{"type":"string","description":"Optional: a customer created without one claims the account through a password reset."},"password_confirmation":{"type":"string","description":"Optional: a customer created without one claims the account through a password reset."},"selected_locale":{"type":"string"},"avatar_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`."},"accepts_email_marketing":{"type":"boolean"},"internal_note":{"type":"string","description":"Rich text HTML. Reads come back as this plus `internal_note_html`."},"metadata":{"type":"object","additionalProperties":true},"tags":{"type":"array","items":{"type":"string"}},"customer_group_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the customer's group membership."}},"required":["email"]},"CustomerGroupCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"customer_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the group's members."}},"required":["name"]},"CustomerGroupUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"customer_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the group's members."}}},"CustomerStoreCreditCreateParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"currency":{"type":"string"},"memo":{"type":"string"}},"required":["amount","currency"]},"CustomerStoreCreditUpdateParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"memo":{"type":"string"}}},"CustomerUpdateParams":{"type":"object","properties":{"email":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"phone":{"type":"string"},"password":{"type":"string","description":"Optional: a customer created without one claims the account through a password reset."},"password_confirmation":{"type":"string","description":"Optional: a customer created without one claims the account through a password reset."},"selected_locale":{"type":"string"},"avatar_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`."},"accepts_email_marketing":{"type":"boolean"},"internal_note":{"type":"string","description":"Rich text HTML. Reads come back as this plus `internal_note_html`."},"metadata":{"type":"object","additionalProperties":true},"tags":{"type":"array","items":{"type":"string"}},"customer_group_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the customer's group membership."}}},"DataRequestCreateParams":{"type":"object","properties":{"customer_id":{"type":"string"},"kind":{"type":"string","enum":["access","erasure"],"description":"`access` asks for a copy of the customer's personal data; `erasure` asks for it to be erased."}},"required":["customer_id","kind"]},"DeliveryCreateParams":{"type":"object","properties":{"tracking_number":{"type":"string","description":"A carrier tracking number, a freight PRO or container number, or a full tracking link. A corrected number resets the carrier status to `pending`."},"carrier":{"type":"string","description":"Free text; detected from the number's format when omitted."},"service":{"type":"string"},"tracking_url":{"type":"string"}},"required":["tracking_number"]},"DeliveryMarkDeliveredParams":{"type":"object","properties":{"delivered_at":{"type":"string","format":"date-time","description":"When it arrived. Defaults to now."},"notify_customer":{"type":"boolean","description":"Whether the customer gets a delivery notification once the parcel completes. Defaults to true."}}},"DeliveryMethodParams":{"type":"object","properties":{"name":{"type":"string"},"admin_name":{"type":"string","nullable":true},"code":{"type":"string","nullable":true},"fulfillment_provider":{"type":"string","description":"Fulfillment provider shorthand (see the fulfillment providers endpoint), e.g. `manual`."},"pickup_point_provider":{"type":"string","nullable":true},"rate_provider":{"type":"string","description":"Rate provider shorthand (see the rate providers endpoint), e.g. `easy_post`. Omit or send null for the built-in provider, which prices through the method's calculator.","nullable":true},"storefront_visible":{"type":"boolean"},"available_to_sellers":{"type":"boolean","description":"Marketplace only: whether a seller's packages may be quoted by this method. Off by default, and refused on a method that belongs to a seller."},"tracking_url":{"type":"string","nullable":true},"estimated_transit_business_days_min":{"type":"integer","nullable":true},"estimated_transit_business_days_max":{"type":"integer","nullable":true},"tax_category_id":{"type":"string","description":"Prefixed tax category ID (`taxcat_...`), or null to clear.","nullable":true},"markup_flat":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Method-level flat handling fee added on top of provider-quoted rates.","nullable":true},"markup_percent":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Method-level percentage handling fee added on top of provider-quoted rates. Ignored for calculator-priced methods.","nullable":true},"delivery_profile_id":{"type":"string","description":"Delivery profile this method belongs to (`fp_...`); defaults to the store default profile."},"delivery_origin_group_id":{"type":"string","description":"Origin group offering this method (`og_...`); defaults to the zone's group, else the profile's default group."},"delivery_zone_id":{"type":"string","description":"Delivery zone narrowing destinations (`dz_...`), or null for no restriction. Must belong to the method's profile.","nullable":true},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Pickup locations (`sloc_...`); replaces the full set."},"calculator":{"type":"object","properties":{"type":{"type":"string"},"preferences":{"type":"object","additionalProperties":true}},"description":"How the method prices a shipment: a type from the calculators endpoint and its preferences, matching that type's `schema`."},"rules":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","description":"A rule kind from the delivery method rule types endpoint."},"active":{"type":"boolean"},"preferences":{"type":"object","additionalProperties":true},"product_ids":{"type":"array","items":{"type":"string"},"description":"Products an association-backed rule (`excluded_products_rule`) applies to."}}},"description":"Eligibility rules. Replaces the full set: omitted rules are removed."},"services":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryMethodServiceParams"},"description":"Carrier service rows: which provider services this method offers. Replaces the full set: omitted rows are removed; no rows means every service the provider returns is offered."}}},"DeliveryMethodRuleCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"A rule kind from the delivery method rule types endpoint."},"active":{"type":"boolean","description":"Defaults to true on create."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's preference schema."},"product_ids":{"type":"array","items":{"type":"string"},"description":"Products an association-backed rule (`excluded_products_rule`) applies to. An empty list clears them."}},"required":["type"]},"DeliveryMethodRuleUpdateParams":{"type":"object","properties":{"active":{"type":"boolean","description":"Defaults to true on create."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's preference schema."},"product_ids":{"type":"array","items":{"type":"string"},"description":"Products an association-backed rule (`excluded_products_rule`) applies to. An empty list clears them."}}},"DeliveryMethodServiceParams":{"type":"object","properties":{"id":{"type":"string","description":"Prefixed row ID (`dms_...`) when updating an existing row."},"carrier":{"type":"string","description":"Carrier identifier as the provider's API knows it."},"service":{"type":"string","description":"Service identifier as the provider's API knows it."},"label":{"type":"string","description":"Display label shown to customers instead of the carrier-derived name.","nullable":true},"markup_flat":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Overrides the method-level flat markup for this service.","nullable":true},"markup_percent":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Overrides the method-level percentage markup for this service.","nullable":true},"position":{"type":"integer"}},"required":["carrier","service"]},"DeliveryOriginGroupParams":{"type":"object","properties":{"name":{"type":"string","nullable":true},"position":{"type":"integer"},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Prefixed stock location IDs (`sloc_...`); replaces the full set. Empty means every store location."}}},"DeliveryProfileParams":{"type":"object","properties":{"name":{"type":"string"},"kind":{"type":"string","description":"Registered profile kind (`shipping`, `digital`, extension kinds) from the kinds endpoint. Read on create only; defaults to shipping."},"default":{"type":"boolean","description":"Promotes this profile to the store default; the previous default is demoted."},"position":{"type":"integer"},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Prefixed stock location IDs (`sloc_...`); replaces the full set. Empty means every store location."}}},"DeliveryUpdateParams":{"type":"object","properties":{"tracking_number":{"type":"string","description":"A carrier tracking number, a freight PRO or container number, or a full tracking link. A corrected number resets the carrier status to `pending`."},"carrier":{"type":"string","description":"Free text; detected from the number's format when omitted."},"service":{"type":"string"},"tracking_url":{"type":"string"}}},"DeliveryZoneMemberParams":{"type":"object","properties":{"member_type":{"type":"string","enum":["country","state","postal_code"]},"country_code":{"type":"string"},"state_code":{"type":"string","description":"A subdivision code or name. Without `country_code` the country is inferred when only one country matches."},"postal_code_prefix":{"type":"string"},"postal_code_from":{"type":"string"},"postal_code_to":{"type":"string"}},"required":["member_type"]},"DeliveryZoneParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"delivery_profile_id":{"type":"string","description":"Delivery profile this zone belongs to (`fp_...`); defaults to the store default profile."},"delivery_origin_group_id":{"type":"string","description":"Origin group this zone belongs to (`og_...`)."},"members":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryZoneMemberParams"},"description":"Replaces the zone's full member set atomically."}}},"DigitalAssetCreateParams":{"type":"object","properties":{"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` with `visibility: 'private'`. Required for an uploaded file, omitted for a provider-backed asset. On update it replaces the file for everyone who already bought it."},"variant_id":{"type":"string","description":"Defaults to the product's default variant when omitted."},"provider_type":{"type":"string","description":"A provider shorthand from the providers endpoint. Omit for an uploaded file."},"provider_settings":{"type":"object","additionalProperties":true,"description":"Values for the provider's settings schema, keyed by field name."},"authorized_clicks":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true},"authorized_days":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true}}},"DigitalAssetUpdateParams":{"type":"object","properties":{"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` with `visibility: 'private'`. Required for an uploaded file, omitted for a provider-backed asset. On update it replaces the file for everyone who already bought it."},"variant_id":{"type":"string","description":"Defaults to the product's default variant when omitted."},"provider_type":{"type":"string","description":"A provider shorthand from the providers endpoint. Omit for an uploaded file."},"provider_settings":{"type":"object","additionalProperties":true,"description":"Values for the provider's settings schema, keyed by field name."},"authorized_clicks":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true},"authorized_days":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true}}},"DiscountCodeApplyParams":{"type":"object","properties":{"code":{"type":"string"}},"required":["code"]},"DiscountCreateParams":{"type":"object","properties":{"label":{"type":"string"},"value":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"An amount in the order currency for a `flat` discount, or a percentage for a `percent` one."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"On create, an older spelling of `value`, read when `value` is absent. On update, the new amount of the row."},"value_type":{"type":"string","enum":["flat","percent"],"description":"Defaults to `flat`."},"line_item_id":{"type":"string","description":"The line item the discount applies to. Omitted, the value is distributed across the line items.","nullable":true}},"required":["label"]},"DiscountUpdateParams":{"type":"object","properties":{"label":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"On create, an older spelling of `value`, read when `value` is absent. On update, the new amount of the row."}}},"EmailTemplateDraftParams":{"type":"object","properties":{"language":{"type":"string","description":"A language code, or `any` (the default) for the version every language uses."},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"lock_version":{"type":"integer","description":"The `lock_version` the draft was loaded with, or null when there was no draft; a save from an older copy is refused with 409. Omit it to save without checking.","nullable":true},"rebase":{"type":"boolean","description":"Marks the draft as based on Spree's current default, after reviewing what changed in it."}}},"EmailTemplatePreviewParams":{"type":"object","properties":{"language":{"type":"string","description":"A language code, or `any` (the default) for the version every language uses."},"subject":{"type":"string","description":"An unsaved subject, in place of the current one.","nullable":true},"body":{"type":"string","description":"An unsaved body, in place of the current one."},"record_id":{"type":"string","description":"The record to build sample data from; the store's latest matching record otherwise."},"email_key":{"type":"string","description":"For the layout or a partial, the email to show it in."},"branding":{"type":"object","properties":{"accent_color":{"type":"string","nullable":true},"background_color":{"type":"string","nullable":true},"card_color":{"type":"string","nullable":true},"text_color":{"type":"string","nullable":true},"heading_color":{"type":"string","nullable":true},"font":{"type":"string","enum":["inter","system","helvetica","georgia","roboto","lato","merriweather"],"nullable":true}},"description":"Unsaved colors and font to preview, named like the store's `email_*` settings."}}},"EmailTemplateRestoreParams":{"type":"object","properties":{"language":{"type":"string","description":"A language code, or `any` (the default) for the version every language uses."},"lock_version":{"type":"integer","description":"The open draft's `lock_version`, or null when there is none; checked as when saving.","nullable":true}}},"EmailTemplateVersionParams":{"type":"object","properties":{"language":{"type":"string","description":"A language code, or `any` (the default) for the version every language uses."},"lock_version":{"type":"integer","description":"The draft's `lock_version` as reviewed. A draft saved since is refused with 409."}}},"ExchangeCancelParams":{"type":"object","properties":{"reason":{"type":"string","description":"A note on why the exchange was canceled."}}},"ExchangeCreateParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"fulfillment_item_id":{"type":"string"},"new_variant_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["fulfillment_item_id","new_variant_id","quantity"]},"description":"Items coming back, and what goes out in their place."},"stock_location_id":{"type":"string","description":"Where the goods come back to."},"reason_id":{"type":"string","description":"One of the store's return reasons."},"memo":{"type":"string"}},"required":["items"]},"ExchangeFulfillParams":{"type":"object","properties":{"refund_method":{"type":"string","enum":["original_payment","store_credit"],"description":"How a credit is returned when the replacements cost less than what came back. Defaults to `store_credit`. A balance the customer owes is left for the merchant to collect."}}},"ExchangeReceiveParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"exchange_line_item_id":{"type":"string"},"quantity":{"type":"integer"},"resellable":{"type":"boolean","description":"Goods that cannot be resold are received but never restocked. Defaults to true."}},"required":["exchange_line_item_id","quantity"]},"description":"What actually arrived. Omit to receive everything as requested and resellable."}}},"ExchangeUpdateParams":{"type":"object","properties":{"stock_location_id":{"type":"string","description":"Where the goods come back to."},"reason_id":{"type":"string","description":"One of the store's return reasons."},"memo":{"type":"string"},"metadata":{"type":"object","additionalProperties":true}}},"ExportCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Which dataset to export, as its shorthand: `products`, `orders`, `customers`, `product_translations`, `gift_cards`, `coupon_codes`, `newsletter_subscribers`, `price_list_prices`, `purchase_orders`, or a type an extension registers."},"record_selection":{"type":"string","enum":["filtered","all"],"description":"`filtered` (the default) keeps `search_params`; `all` ignores them and exports every record in scope."},"results_url":{"type":"string","description":"Absolute URL of your admin exports view; the export-done email uses it as the download button target. Only honored when it matches one of the store's allowed origins."},"search_params":{"type":"object","additionalProperties":true,"description":"A Ransack query, with the predicates the list endpoint accepts. A `price_list_prices` export requires `price_list_id_eq` naming a price list of the current store, and refuses `record_selection: \"all\"`."}},"required":["type"]},"FeeCreateParams":{"type":"object","properties":{"label":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"kind":{"anyOf":[{"type":"string","enum":["surcharge","handling","gift_wrap","cod","payment","duty","exchange"]},{"type":"string"}],"description":"Defaults to `surcharge`. The values listed are the built-in ones; extensions may add more."},"line_item_id":{"type":"string","description":"The line item or fulfillment the fee belongs to. Omitted, the fee is order-level.","nullable":true},"fulfillment_id":{"type":"string","description":"The line item or fulfillment the fee belongs to. Omitted, the fee is order-level.","nullable":true}},"required":["label","amount"]},"FeeUpdateParams":{"type":"object","properties":{"label":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"kind":{"anyOf":[{"type":"string","enum":["surcharge","handling","gift_wrap","cod","payment","duty","exchange"]},{"type":"string"}],"description":"Defaults to `surcharge`. The values listed are the built-in ones; extensions may add more."}}},"FileUploadCreateParams":{"type":"object","properties":{"filename":{"type":"string"},"content_type":{"type":"string"},"byte_size":{"type":"integer"},"checksum":{"type":"string","description":"Base64-encoded MD5 digest of the file; the storage service checks the bytes against it."},"visibility":{"type":"string","enum":["public","private"],"description":"`public` (the default) for images and videos customers see, `private` for anything else."},"file":{"type":"string","format":"binary","description":"The bytes, for a multipart upload."}},"required":["filename","content_type"]},"FulfillmentCreateParams":{"type":"object","properties":{"stock_location_id":{"type":"string","description":"The location the fulfillment ships from. On update, moving it re-prices the fulfillment against that location's rates."},"source_fulfillment_id":{"type":"string","description":"The only fulfillment of this order to move units from, its exchange and claim replacements included: how a canceled replacement is sent again. Omitted, the customer's bought units are taken from every unshipped fulfillment."},"tracking":{"type":"string","description":"Carrier tracking number, or a full `https://` tracking link, which is served back as `tracking_url` unchanged."},"delivery_method_id":{"type":"string","description":"Delivery method attached as the selected rate. Defaults to the delivery method of the fully drained source fulfillments."},"cost":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Explicit shipping cost, such as the 3PL price. Defaults to the summed cost of the fully drained source fulfillments, which keeps the order total unchanged. Persists only with `status: shipped`; pending fulfillments are re-priced by the rate engine."},"status":{"type":"string","enum":["shipped"],"description":"Pass `shipped` to register an already-shipped external fulfillment."},"metadata":{"type":"object","additionalProperties":true},"items":{"type":"array","items":{"type":"object","properties":{"item_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["item_id","quantity"]},"description":"Line item quantities to fulfill. Omit to fulfill every unit not yet shipped."}},"required":["stock_location_id"]},"FulfillmentFulfillParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"item_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["item_id","quantity"]},"description":"Line item quantities to ship. Omit to ship everything the fulfillment holds; a subset is split onto a new fulfillment, which is the one that ships."},"tracking":{"type":"string","description":"Carrier tracking number or a full `https://` tracking link, stored on the fulfillment that ships."},"tracking_carrier":{"type":"string","description":"Which carrier the number belongs to; detected from the number when omitted."},"notify_customer":{"type":"boolean","description":"Whether the customer gets the shipment email. Defaults to true; pass false to suppress it for this dispatch only."},"force":{"type":"boolean","description":"Hand the goods over even though the order is unpaid or holds backordered units."}}},"FulfillmentMarkDeliveredParams":{"type":"object","properties":{"delivered_at":{"type":"string","format":"date-time","description":"When it arrived. Defaults to now; return windows run from this time."},"notify_customer":{"type":"boolean","description":"Whether the customer gets a delivery notification. Defaults to true."}}},"FulfillmentSplitParams":{"type":"object","properties":{"variant_id":{"type":"string","description":"The variant being moved out."},"quantity":{"type":"integer"},"stock_location_id":{"type":"string","description":"Origin of the new fulfillment. Defaults to the source fulfillment's location."}},"required":["variant_id","quantity"]},"FulfillmentUpdateParams":{"type":"object","properties":{"stock_location_id":{"type":"string","description":"The location the fulfillment ships from. On update, moving it re-prices the fulfillment against that location's rates."},"tracking":{"type":"string","description":"Carrier tracking number, or a full `https://` tracking link, which is served back as `tracking_url` unchanged."},"tracking_carrier":{"type":"string","description":"Which carrier the tracking number belongs to: a slug from the tracking carriers endpoint. Left blank, it is detected from the number's format where possible."},"selected_delivery_rate_id":{"type":"string"}}},"GiftCardApplyParams":{"type":"object","properties":{"code":{"type":"string","description":"The gift card code; matched case-insensitively."}},"required":["code"]},"GiftCardBatchCreateParams":{"type":"object","properties":{"prefix":{"type":"string","description":"Lowercased and prepended to every generated code."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"The amount of each card, greater than zero."},"codes_count":{"type":"integer","description":"How many cards to generate. Capped at `gift_card_batch_limit`; batches over `gift_card_batch_web_limit` generate in the background."},"currency":{"type":"string","description":"ISO 4217 currency code. Defaults to the store currency."},"expires_at":{"type":"string","format":"date","nullable":true}},"required":["prefix","amount","codes_count"]},"GiftCardCreateParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Greater than zero."},"currency":{"type":"string","description":"ISO 4217 currency code. Defaults to the store currency."},"code":{"type":"string","description":"Generated when omitted."},"expires_at":{"type":"string","format":"date","nullable":true},"customer_id":{"type":"string","description":"The customer the card belongs to. Needs the `read_customers` permission; null detaches it.","nullable":true}},"required":["amount"]},"GiftCardUpdateParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Greater than zero."},"currency":{"type":"string","description":"ISO 4217 currency code. Defaults to the store currency."},"code":{"type":"string","description":"Generated when omitted."},"expires_at":{"type":"string","format":"date","nullable":true},"customer_id":{"type":"string","description":"The customer the card belongs to. Needs the `read_customers` permission; null detaches it.","nullable":true}}},"ImportCompleteMappingParams":{"type":"object","properties":{"mappings":{"type":"array","items":{"type":"object","properties":{"schema_field":{"type":"string","description":"A schema field name from the import's `schema_fields`."},"file_column":{"type":"string","description":"The CSV header to read the field from; null unmaps the field.","nullable":true}},"required":["schema_field"]},"description":"Column assignments to apply before processing starts. Omit to accept the ones assigned on create."}}},"ImportCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Which dataset to import, as its shorthand: `products`, `customers`, `product_translations`, `price_list_prices`, `purchase_orders`, or a type an extension registers."},"attachment_signed_id":{"type":"string","description":"The `signed_id` of the uploaded CSV, from `files.upload()` with `visibility: \"private\"`."},"delimiter":{"type":"string","enum":[",",";","|","\t"],"description":"CSV column separator. Defaults to a comma."},"results_url":{"type":"string","description":"Absolute URL of your admin imports view; the import-done email links back to it with `?import=<id>` appended. Only honored when it matches one of the store's allowed origins."},"price_list_id":{"type":"string","description":"For `price_list_prices` imports: the price list the rows are merged into. Must belong to the current store; other types ignore it."}},"required":["type","attachment_signed_id"]},"IntegrationCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Wire shorthand from the integration types endpoint."},"active":{"type":"boolean","description":"Activating runs the connection check, and a failed check is a 422."},"preferences":{"type":"object","additionalProperties":true,"description":"Credential values. Secret preferences come back masked, and sending a masked value back keeps the stored secret."}},"required":["type"]},"IntegrationUpdateParams":{"type":"object","properties":{"active":{"type":"boolean","description":"Activating runs the connection check, and a failed check is a 422."},"preferences":{"type":"object","additionalProperties":true,"description":"Credential values. Secret preferences come back masked, and sending a masked value back keeps the stored secret."}}},"InvitationAcceptParams":{"type":"object","properties":{"password":{"type":"string","description":"Required when the invitee has no account yet: it creates one. An existing account signs in without it."},"password_confirmation":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"}}},"InvitationCreateParams":{"type":"object","properties":{"email":{"type":"string"},"role_id":{"type":"string","description":"The role (`role_...`) the invitee gets on accepting."}},"required":["email","role_id"]},"LineItemCreateParams":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer","description":"Defaults to 1 when adding an item."},"price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Negotiated unit price. Stamps the line `price_source: 'manual'`, so quantity changes and recalculation never re-price it; an explicit null reverts the line to catalog pricing. Omit to leave pricing alone. Draft (incomplete) orders only.","nullable":true},"options":{"type":"object","additionalProperties":true}},"required":["variant_id"]},"LineItemUpdateParams":{"type":"object","properties":{"quantity":{"type":"integer","description":"Defaults to 1 when adding an item."},"price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Negotiated unit price. Stamps the line `price_source: 'manual'`, so quantity changes and recalculation never re-price it; an explicit null reverts the line to catalog pricing. Omit to leave pricing alone. Draft (incomplete) orders only.","nullable":true},"metadata":{"type":"object","additionalProperties":true}}},"MarketCreateParams":{"type":"object","properties":{"name":{"type":"string","description":"Display name, unique within the store."},"currency":{"type":"string","description":"ISO 4217 currency code."},"default_locale":{"type":"string","description":"Locale used as the market default. Always part of `supported_locales`."},"tax_inclusive":{"type":"boolean","description":"Display prices with tax included."},"tax_provider":{"type":"string","description":"Shorthand of the tax engine that prices this market, from the tax providers endpoint. Null uses the installation default.","nullable":true},"default":{"type":"boolean","description":"Setting true demotes the previous default market of the store."},"position":{"type":"integer","description":"Sort order within the store; lower comes first."},"supported_locales":{"type":"array","items":{"type":"string"},"description":"Locales available in this market. The default locale is always included."},"country_codes":{"type":"array","items":{"type":"string"},"description":"ISO 3166-1 alpha-2 codes of the countries in this market. At least one is required."}},"required":["name","currency","default_locale","country_codes"]},"MarketUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"Display name, unique within the store."},"currency":{"type":"string","description":"ISO 4217 currency code."},"default_locale":{"type":"string","description":"Locale used as the market default. Always part of `supported_locales`."},"tax_inclusive":{"type":"boolean","description":"Display prices with tax included."},"tax_provider":{"type":"string","description":"Shorthand of the tax engine that prices this market, from the tax providers endpoint. Null uses the installation default.","nullable":true},"default":{"type":"boolean","description":"Setting true demotes the previous default market of the store."},"position":{"type":"integer","description":"Sort order within the store; lower comes first."},"supported_locales":{"type":"array","items":{"type":"string"},"description":"Locales available in this market. The default locale is always included."},"country_codes":{"type":"array","items":{"type":"string"},"description":"ISO 3166-1 alpha-2 codes of the countries in this market. At least one is required."}}},"MeUpdateParams":{"type":"object","properties":{"selected_locale":{"type":"string","description":"The dashboard display language."},"first_name":{"type":"string"},"last_name":{"type":"string"},"avatar_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` to set the avatar, or null to remove it. Omit it to keep the current photo.","nullable":true}}},"MediaCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"attachment":{"type":"string","description":"The file itself, sent as multipart form data. JSON clients upload first and send `signed_id`."},"url":{"type":"string","description":"Fetch an image from this URL, in the background. Images only: an external video uses `external_video_url`."},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the media file itself."},"source_media_id":{"type":"string","description":"Place a file that is already in the library. The new row shares the source file rather than copying it, and takes its own alt, position and variant links from here."},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Variants to link this product-level media to. Variants of other products are dropped."}}},"MediaLibraryCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"attachment":{"type":"string","description":"The file itself, sent as multipart form data. JSON clients upload first and send `signed_id`."},"url":{"type":"string","description":"Fetch an image from this URL, in the background. Images only: an external video uses `external_video_url`."},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the media file itself."},"source_media_id":{"type":"string","description":"Place a file that is already in the library. The new row shares the source file rather than copying it, and takes its own alt, position and variant links from here."},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Variants to link this product-level media to. Variants of other products are dropped."}}},"MediaLibraryUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"attachment":{"type":"string","description":"The file itself, sent as multipart form data. JSON clients upload first and send `signed_id`."},"url":{"type":"string","description":"Fetch an image from this URL, in the background. Images only: an external video uses `external_video_url`."},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the media file itself."},"source_media_id":{"type":"string","description":"Place a file that is already in the library. The new row shares the source file rather than copying it, and takes its own alt, position and variant links from here."},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Variants to link this product-level media to. Variants of other products are dropped."}}},"MediaUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"attachment":{"type":"string","description":"The file itself, sent as multipart form data. JSON clients upload first and send `signed_id`."},"url":{"type":"string","description":"Fetch an image from this URL, in the background. Images only: an external video uses `external_video_url`."},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the media file itself."},"source_media_id":{"type":"string","description":"Place a file that is already in the library. The new row shares the source file rather than copying it, and takes its own alt, position and variant links from here."},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Variants to link this product-level media to. Variants of other products are dropped."}}},"OptionTypeCreateParams":{"type":"object","properties":{"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"integer"},"filterable":{"type":"boolean"},"kind":{"type":"string","enum":["dropdown","color_swatch","buttons"]},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValueParams"},"description":"Inline option values. Values left out of the list on update are destroyed, so send the full set every time."}},"required":["name","label"]},"OptionTypeUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"integer"},"filterable":{"type":"boolean"},"kind":{"type":"string","enum":["dropdown","color_swatch","buttons"]},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValueParams"},"description":"Inline option values. Values left out of the list on update are destroyed, so send the full set every time."}}},"OptionValueParams":{"type":"object","properties":{"id":{"type":"string","description":"Present for existing values. Omit to create a new one."},"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"integer"},"color_code":{"type":"string","description":"Hex color. Only meaningful when the option type's `kind` is `color_swatch`.","nullable":true},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`, or null to remove the image.","nullable":true}}},"OrderCancelParams":{"type":"object","properties":{"cancel_reason_id":{"type":"string","description":"Why the order was canceled: the id of one of the store's cancellation reasons."},"cancel_note":{"type":"string","description":"Staff-facing note about the cancellation."},"refund_payments":{"type":"boolean","description":"Whether this order's share of a payment shared across a split checkout is handed back."},"refund_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"How much of that share to return. Defaults to all of it; refused on an order whose payment is not shared."},"notify_customer":{"type":"boolean","description":"Send the order cancellation email after canceling."}}},"OrderCompleteParams":{"type":"object","properties":{"payment_pending":{"type":"boolean"},"notify_customer":{"type":"boolean","description":"Send the order confirmation email after completion."}}},"OrderCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"email":{"type":"string"},"customer_id":{"type":"string"},"use_customer_default_address":{"type":"boolean","description":"With `customer_id`, copies the customer's saved billing and shipping addresses onto the order."},"currency":{"type":"string"},"market_id":{"type":"string"},"channel_id":{"type":"string","description":"Defaults to the store primary channel when omitted."},"locale":{"type":"string"},"customer_note":{"type":"string","description":"Public, customer-visible note."},"internal_note":{"type":"string","description":"Staff-only note. Rich text HTML; reads come back as this plus `internal_note_html`."},"po_number":{"type":"string","description":"The buyer's own purchase-order reference. Searchable alongside the order number, and rendered on every order-facing document."},"po_document_signed_id":{"type":"string","description":"The `signed_id` of the buyer's purchase order, from `files.upload()` with `visibility: 'private'`. Null removes the document the order carries.","nullable":true},"shipping_address_id":{"type":"string","description":"An existing address of the customer."},"billing_address_id":{"type":"string","description":"An existing address of the customer."},"preferred_stock_location_id":{"type":"string","description":"Stock location to prefer for fulfillment. Order Routing's built-in preferred-location rule ranks it first; routing falls back to the next rule when the location can't cover the cart."},"company_id":{"type":"string","description":"Makes the order a company purchase, with that company's catalog prices and tax treatment. Null makes a draft a plain customer order again.","nullable":true},"coupon_code":{"type":"string","description":"Applied non-fatally: an invalid code does not block creation."},"metadata":{"type":"object","additionalProperties":true},"tags":{"type":"array","items":{"type":"string"}},"shipping_address":{"$ref":"#/components/schemas/AddressInputParams"},"billing_address":{"$ref":"#/components/schemas/AddressInputParams"},"items":{"type":"array","items":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer"},"price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Negotiated unit price; stamps `price_source: 'manual'`. Null reverts the line to catalog pricing. Draft orders only.","nullable":true},"metadata":{"type":"object","additionalProperties":true}},"required":["variant_id"]},"description":"Line items to upsert, keyed by variant. An entry sets that variant's quantity, creating the line item when the order has none; `quantity: 0` removes it. Variants you do not send are left alone."}}},"OrderRoutingRuleCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Wire shorthand for the rule kind, from the order routing rule types endpoint."},"active":{"type":"boolean"},"position":{"type":"integer","description":"1-based priority in the channel's rule list. Omitted on create, the rule goes last; a new position reorders the rest of the list around it."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's preference schema."}},"required":["type"]},"OrderRoutingRuleUpdateParams":{"type":"object","properties":{"active":{"type":"boolean"},"position":{"type":"integer","description":"1-based priority in the channel's rule list. Omitted on create, the rule goes last; a new position reorders the rest of the list around it."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's preference schema."}}},"OrderUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"email":{"type":"string"},"customer_id":{"type":"string"},"currency":{"type":"string"},"market_id":{"type":"string"},"channel_id":{"type":"string","description":"Defaults to the store primary channel when omitted."},"locale":{"type":"string"},"customer_note":{"type":"string","description":"Public, customer-visible note."},"internal_note":{"type":"string","description":"Staff-only note. Rich text HTML; reads come back as this plus `internal_note_html`."},"po_number":{"type":"string","description":"The buyer's own purchase-order reference. Searchable alongside the order number, and rendered on every order-facing document."},"po_document_signed_id":{"type":"string","description":"The `signed_id` of the buyer's purchase order, from `files.upload()` with `visibility: 'private'`. Null removes the document the order carries.","nullable":true},"preferred_stock_location_id":{"type":"string","description":"Stock location to prefer for fulfillment. Order Routing's built-in preferred-location rule ranks it first; routing falls back to the next rule when the location can't cover the cart."},"company_id":{"type":"string","description":"Makes the order a company purchase, with that company's catalog prices and tax treatment. Null makes a draft a plain customer order again.","nullable":true},"metadata":{"type":"object","additionalProperties":true},"tags":{"type":"array","items":{"type":"string"}},"shipping_address":{"$ref":"#/components/schemas/AddressInputParams"},"billing_address":{"$ref":"#/components/schemas/AddressInputParams"},"items":{"type":"array","items":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer"},"price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Negotiated unit price; stamps `price_source: 'manual'`. Null reverts the line to catalog pricing. Draft orders only.","nullable":true},"metadata":{"type":"object","additionalProperties":true}},"required":["variant_id"]},"description":"Line items to upsert, keyed by variant. An entry sets that variant's quantity, creating the line item when the order has none; `quantity: 0` removes it. Variants you do not send are left alone."}}},"PackageTypeCreateParams":{"type":"object","properties":{"name":{"type":"string","description":"Unique within the store."},"kind":{"type":"string","enum":["box","envelope","carton","pallet","container"],"description":"What this packaging is: the box parcels ship in, or the carton, pallet or container a wholesale order leaves on."},"length":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"],"description":"Unit the three dimensions are in; falls back to the store's unit system.","nullable":true},"weight":{"type":"number","description":"The empty package's own weight, added to content weight on every quote.","nullable":true},"max_weight":{"type":"number","description":"What the package can hold, not the same as its own weight.","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"],"nullable":true},"default":{"type":"boolean","description":"The box every parcel quote is built on. Setting this demotes whichever row held it."},"metadata":{"type":"object","additionalProperties":true}},"required":["name","kind"]},"PackageTypeUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"Unique within the store."},"kind":{"type":"string","enum":["box","envelope","carton","pallet","container"],"description":"What this packaging is: the box parcels ship in, or the carton, pallet or container a wholesale order leaves on."},"length":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"],"description":"Unit the three dimensions are in; falls back to the store's unit system.","nullable":true},"weight":{"type":"number","description":"The empty package's own weight, added to content weight on every quote.","nullable":true},"max_weight":{"type":"number","description":"What the package can hold, not the same as its own weight.","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"],"nullable":true},"default":{"type":"boolean","description":"The box every parcel quote is built on. Setting this demotes whichever row held it."},"metadata":{"type":"object","additionalProperties":true}}},"PasswordResetParams":{"type":"object","properties":{"password":{"type":"string"},"password_confirmation":{"type":"string"}},"required":["password","password_confirmation"]},"PasswordResetRequestParams":{"type":"object","properties":{"email":{"type":"string","format":"email"},"redirect_url":{"type":"string","description":"The page the emailed reset link points at, with the reset token appended. Honored only on the dashboard origin, for an account that is staff of the store; ignored otherwise."}},"required":["email"]},"PaymentCaptureParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Captures part of the authorized amount. Defaults to all of it."}}},"PaymentCreateParams":{"type":"object","properties":{"payment_method_id":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Defaults to the order total left after store credit."},"source_id":{"type":"string","description":"A saved payment source of the order's customer (a credit card), for an off-session charge. Used only by payment methods that require a source."}},"required":["payment_method_id"]},"PaymentMethodCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Wire shorthand from the payment method types endpoint."},"name":{"type":"string"},"description":{"type":"string","nullable":true},"active":{"type":"boolean"},"storefront_visible":{"type":"boolean","description":"False keeps the method to the dashboard; true also offers it on the storefront."},"auto_capture":{"type":"boolean","description":"Deprecated: Use `capture_method`. Removed in 6.1.","deprecated":true,"nullable":true},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"],"description":"When customers are charged for this method. Null inherits the store setting.","nullable":true},"position":{"type":"integer"},"metadata":{"type":"object","additionalProperties":true},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the provider's preference schema, from the payment method types endpoint."}},"required":["type","name"]},"PaymentMethodUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"active":{"type":"boolean"},"storefront_visible":{"type":"boolean","description":"False keeps the method to the dashboard; true also offers it on the storefront."},"auto_capture":{"type":"boolean","description":"Deprecated: Use `capture_method`. Removed in 6.1.","deprecated":true,"nullable":true},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"],"description":"When customers are charged for this method. Null inherits the store setting.","nullable":true},"position":{"type":"integer"},"metadata":{"type":"object","additionalProperties":true},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the provider's preference schema, from the payment method types endpoint."}}},"PolicyCreateParams":{"type":"object","properties":{"name":{"type":"string"},"slug":{"type":"string"},"body":{"type":"string","nullable":true}},"required":["name"]},"PolicyUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"slug":{"type":"string"},"body":{"type":"string","nullable":true}}},"PriceAdjustmentTierParams":{"type":"object","properties":{"min_quantity":{"type":"integer","description":"Above 1; quantity 1 is the list's own `price_adjustment_percentage`."},"percentage":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Signed: negative discounts, positive marks up."}},"required":["min_quantity","percentage"]},"PriceBulkDestroyParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}}},"required":["ids"]},"PriceBulkUpsertParams":{"type":"object","properties":{"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceBulkUpsertRowParams"},"description":"Send an empty list to change nothing."}},"required":["prices"]},"PriceBulkUpsertRowParams":{"type":"object","properties":{"id":{"type":"string","description":"Present: updates that row. Absent: upserts on `(variant_id, currency, price_list_id, min_quantity)`.","nullable":true},"variant_id":{"type":"string"},"currency":{"type":"string"},"price_list_id":{"type":"string","description":"Omit or null for a base price.","nullable":true},"min_quantity":{"type":"integer","description":"The rung of the variant's ladder. Omit for the bottom rung; anything above 1 requires a `price_list_id`. A variant carries at most ten rungs on one list per currency."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"required":["variant_id","currency"]},"PriceCreateParams":{"type":"object","properties":{"variant_id":{"type":"string"},"currency":{"type":"string"},"min_quantity":{"type":"integer","description":"The quantity a line must reach for this price to apply. Omit for the bottom rung of the ladder. Anything above 1 requires a `price_list_id`."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"price_list_id":{"type":"string","description":"Omit or null for a base price; a price list for a list override.","nullable":true}},"required":["variant_id","currency"]},"PriceListCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"position":{"type":"integer"},"starts_at":{"type":"string","format":"date-time","description":"Pair with `ends_at` to schedule the list: activating a list whose start is in the future marks it `scheduled`.","nullable":true},"ends_at":{"type":"string","format":"date-time","nullable":true},"match_policy":{"type":"string","enum":["all","any"],"description":"`all`: every rule must match. `any`: one matching rule is enough."},"price_adjustment_percentage":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Signed: negative discounts off base prices, positive marks up.","nullable":true},"adjust_compare_at":{"type":"boolean"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PriceListRuleParams"},"description":"The complete rule set: rules are matched by `id` and updated, new ones are built, and rules left out are removed."},"price_adjustment_tiers":{"type":"array","items":{"$ref":"#/components/schemas/PriceAdjustmentTierParams"},"description":"Quantity bands on the list's percentage. The payload is the whole ladder: a band left out is removed."},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceListPriceOverrideParams"},"description":"Per-variant price overrides. Each row upserts, so the variants it names become part of the list. Curating whole products goes through the nested products endpoint instead."}},"required":["name"]},"PriceListPriceOverrideParams":{"type":"object","properties":{"id":{"type":"string","description":"Updates this price row. Without it, the row upserts on `(variant_id, currency, min_quantity)`."},"variant_id":{"type":"string"},"currency":{"type":"string"},"min_quantity":{"type":"integer","description":"The rung of the variant's ladder. Omit for the bottom rung."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}}},"PriceListRuleParams":{"type":"object","properties":{"id":{"type":"string","description":"Present for existing rules. Omit to create a new one.","nullable":true},"type":{"type":"string","description":"Wire shorthand for the rule kind, from the price rule types endpoint."},"preferences":{"type":"object","additionalProperties":true,"description":"The rule kind's settings, keyed by preference name."}},"required":["type"]},"PriceListUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"position":{"type":"integer"},"starts_at":{"type":"string","format":"date-time","description":"Pair with `ends_at` to schedule the list: activating a list whose start is in the future marks it `scheduled`.","nullable":true},"ends_at":{"type":"string","format":"date-time","nullable":true},"match_policy":{"type":"string","enum":["all","any"],"description":"`all`: every rule must match. `any`: one matching rule is enough."},"price_adjustment_percentage":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Signed: negative discounts off base prices, positive marks up.","nullable":true},"adjust_compare_at":{"type":"boolean"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PriceListRuleParams"},"description":"The complete rule set: rules are matched by `id` and updated, new ones are built, and rules left out are removed."},"price_adjustment_tiers":{"type":"array","items":{"$ref":"#/components/schemas/PriceAdjustmentTierParams"},"description":"Quantity bands on the list's percentage. The payload is the whole ladder: a band left out is removed."},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceListPriceOverrideParams"},"description":"Per-variant price overrides. Each row upserts, so the variants it names become part of the list. Curating whole products goes through the nested products endpoint instead."}}},"PriceParams":{"type":"object","properties":{"currency":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"A canonical decimal string (`\"1234.56\"`: period decimal, no grouping). The API does not parse localized input."},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"required":["currency","amount"]},"PriceUpdateParams":{"type":"object","properties":{"variant_id":{"type":"string"},"currency":{"type":"string"},"min_quantity":{"type":"integer","description":"The quantity a line must reach for this price to apply. Omit for the bottom rung of the ladder. Anything above 1 requires a `price_list_id`."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"price_list_id":{"type":"string","description":"Omit or null for a base price; a price list for a list override.","nullable":true}}},"ProductBulkCategoriesParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"category_ids":{"type":"array","items":{"type":"string"}}},"required":["ids","category_ids"]},"ProductBulkChannelsParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"channel_ids":{"type":"array","items":{"type":"string"}}},"required":["ids","channel_ids"]},"ProductBulkCollectionsParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"collection_ids":{"type":"array","items":{"type":"string"}}},"required":["ids","collection_ids"]},"ProductBulkDestroyParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"},"description":"Products the caller cannot delete are skipped."}},"required":["ids"]},"ProductBulkStatusParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"status":{"type":"string","enum":["draft","active","archived"],"description":"Products in review are skipped and counted in `skipped_in_review_count`."}},"required":["ids","status"]},"ProductCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"slug":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["draft","active","archived"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"tax_category_id":{"type":"string"},"product_type_id":{"type":"string","description":"The product type this product is created from (`pt_...`). Its option types and categories seed onto the product and its custom field definitions drive the product form. Editing the type later never rewrites existing products.","nullable":true},"delivery_profile_id":{"type":"string","description":"The delivery profile deciding how this product ships (`fp_...`); null falls back to the store default.","nullable":true},"promotionable":{"type":"boolean"},"tags":{"type":"array","items":{"type":"string"}},"category_ids":{"type":"array","items":{"type":"string"}},"collection_ids":{"type":"array","items":{"type":"string"},"description":"Manual collections this product belongs to. Automatic collections are kept as they are, since their rules decide membership."},"metadata":{"type":"object","additionalProperties":true},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Shorthand for a simple (no-options) product: per-currency prices that forward to the product's sole variant. For products with options, set prices per variant under `variants` instead. Don't pass both."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."},"media":{"type":"array","items":{"$ref":"#/components/schemas/ProductMediaParams"},"description":"Media written with the product. Entries with `id` update an existing asset; entries with `signed_id` attach a fresh upload; an external video needs only its URL."},"digital_assets":{"type":"array","items":{"$ref":"#/components/schemas/ProductDigitalAssetParams"},"description":"Downloadable files written with the product. Each entry carries a `signed_id` (an upload to private storage) or a `provider_type` (a provider-backed asset), and attaches to the default variant unless `variant_id` is given. An `id` updates that asset in place, so replaying the list does not duplicate it; removal uses the nested digital assets endpoint."},"product_publications":{"type":"array","items":{"$ref":"#/components/schemas/ProductPublicationParams"}},"variants":{"type":"array","items":{"$ref":"#/components/schemas/ProductVariantParams"},"description":"Every purchasable attribute (sku, prices, stock, weight, dimensions) lives on variants. An entry without `options` upserts onto the default variant of a simple product; pass `id` to update an existing variant."}},"required":["name"]},"ProductDigitalAssetParams":{"type":"object","properties":{"id":{"type":"string"},"signed_id":{"type":"string"},"variant_id":{"type":"string"},"provider_type":{"type":"string","description":"A provider shorthand from the digital asset providers endpoint."},"provider_settings":{"type":"object","additionalProperties":true,"description":"Values for the provider's settings schema, keyed by field name."},"authorized_clicks":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true},"authorized_days":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true}}},"ProductMediaParams":{"type":"object","properties":{"id":{"type":"string"},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`."},"source_media_id":{"type":"string","description":"Copies an asset from the media library."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the variants this media is linked to. An empty list clears them."}}},"ProductMembershipParams":{"type":"object","properties":{"product_ids":{"type":"array","items":{"type":"string"},"description":"Products from other stores, or ones the caller cannot see, are ignored."}},"required":["product_ids"]},"ProductMembershipRepositionParams":{"type":"object","properties":{"new_position":{"type":"integer","description":"0-based index among the parent's products."}},"required":["new_position"]},"ProductPublicationParams":{"type":"object","properties":{"id":{"type":"string"},"channel_id":{"type":"string"},"published_at":{"type":"string","format":"date-time","nullable":true},"unpublished_at":{"type":"string","format":"date-time","nullable":true}}},"ProductRejectParams":{"type":"object","properties":{"reason":{"type":"string","description":"Why the submission was turned down. Sent back to the seller."}}},"ProductTypeCreateParams":{"type":"object","properties":{"name":{"type":"string"},"delivery_profile_id":{"type":"string","description":"Delivery profile stamped onto products created with this type. Null leaves new products on the store default profile.","nullable":true},"option_type_ids":{"type":"array","items":{"type":"string"},"description":"Option types seeded onto products that get this type. Use apply to products to backfill existing ones."},"category_ids":{"type":"array","items":{"type":"string"},"description":"Categories seeded onto products that get this type. Categories from other stores are ignored."},"custom_field_definitions":{"type":"array","items":{"$ref":"#/components/schemas/ProductTypeCustomFieldDefinitionParams"},"description":"The custom field definitions the product form shows. Definitions not listed are removed from the type."}},"required":["name"]},"ProductTypeCustomFieldDefinitionParams":{"type":"object","properties":{"id":{"type":"string","description":"The custom field definition."},"required":{"type":"boolean"},"sort_order":{"type":"integer"}},"required":["id"]},"ProductTypeUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"delivery_profile_id":{"type":"string","description":"Delivery profile stamped onto products created with this type. Null leaves new products on the store default profile.","nullable":true},"option_type_ids":{"type":"array","items":{"type":"string"},"description":"Option types seeded onto products that get this type. Use apply to products to backfill existing ones."},"category_ids":{"type":"array","items":{"type":"string"},"description":"Categories seeded onto products that get this type. Categories from other stores are ignored."},"custom_field_definitions":{"type":"array","items":{"$ref":"#/components/schemas/ProductTypeCustomFieldDefinitionParams"},"description":"The custom field definitions the product form shows. Definitions not listed are removed from the type."}}},"ProductUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"slug":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["draft","active","archived"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"tax_category_id":{"type":"string"},"product_type_id":{"type":"string","description":"The product type this product is created from (`pt_...`). Its option types and categories seed onto the product and its custom field definitions drive the product form. Editing the type later never rewrites existing products.","nullable":true},"delivery_profile_id":{"type":"string","description":"The delivery profile deciding how this product ships (`fp_...`); null falls back to the store default.","nullable":true},"promotionable":{"type":"boolean"},"tags":{"type":"array","items":{"type":"string"}},"category_ids":{"type":"array","items":{"type":"string"}},"collection_ids":{"type":"array","items":{"type":"string"},"description":"Manual collections this product belongs to. Automatic collections are kept as they are, since their rules decide membership."},"metadata":{"type":"object","additionalProperties":true},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Shorthand for a simple (no-options) product: per-currency prices that forward to the product's sole variant. For products with options, set prices per variant under `variants` instead. Don't pass both."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."},"media":{"type":"array","items":{"$ref":"#/components/schemas/ProductMediaParams"},"description":"Media written with the product. Entries with `id` update an existing asset; entries with `signed_id` attach a fresh upload; an external video needs only its URL."},"digital_assets":{"type":"array","items":{"$ref":"#/components/schemas/ProductDigitalAssetParams"},"description":"Downloadable files written with the product. Each entry carries a `signed_id` (an upload to private storage) or a `provider_type` (a provider-backed asset), and attaches to the default variant unless `variant_id` is given. An `id` updates that asset in place, so replaying the list does not duplicate it; removal uses the nested digital assets endpoint."},"product_publications":{"type":"array","items":{"$ref":"#/components/schemas/ProductPublicationParams"}},"variants":{"type":"array","items":{"$ref":"#/components/schemas/ProductVariantParams"},"description":"Every purchasable attribute (sku, prices, stock, weight, dimensions) lives on variants. An entry without `options` upserts onto the default variant of a simple product; pass `id` to update an existing variant."}}},"ProductVariantParams":{"type":"object","properties":{"id":{"type":"string"},"sku":{"type":"string"},"barcode":{"type":"string"},"cost_price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"cost_currency":{"type":"string"},"weight":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"depth":{"type":"number","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"hs_code":{"type":"string"},"country_of_origin":{"type":"string"},"customs_description":{"type":"string"},"minimum_order_quantity":{"type":"integer","nullable":true},"order_multiple":{"type":"integer","nullable":true},"purchase_unit":{"type":"string"},"units_per_carton":{"type":"integer","description":"How many units fill one carton.","nullable":true},"carton_package_type_id":{"type":"string","description":"The carton this variant is packed into: a package type of kind `carton`. Its dimensions are shared by every product packed the same way, so a corrected carton size fixes all of them at once.","nullable":true},"carton_weight":{"type":"number","description":"What one packed carton weighs, in the variant's weight unit.","nullable":true},"cartons_per_pallet":{"type":"integer","description":"How many cartons stack on one pallet.","nullable":true},"seller_id":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"track_inventory":{"type":"boolean"},"preorderable":{"type":"boolean","description":"Sell this variant before it's in stock. Adds the pre-order label and ships-by promise; the cap comes from `backorder_limit`, an incoming stock count, or backorder."},"preorder_ships_at":{"type":"string","format":"date-time","description":"The \"ships by\" date shown to customers while the variant is a pre-order. Once it passes, the variant is no longer a pre-order. Null clears it.","nullable":true},"backorder_limit":{"type":"integer","description":"Maximum units sellable beyond available stock, capping backorders and pre-orders. Null is unlimited.","nullable":true},"tax_category_id":{"type":"string"},"position":{"type":"integer"},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Per-currency prices. Upserted by currency."},"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevelParams"},"description":"Stock per location. Upserted by location; omitted locations are removed."},"options":{"type":"array","items":{"$ref":"#/components/schemas/VariantOptionParams"},"description":"One pair per option type the variant takes part in (size, color). Option types and values are created when missing."}}},"PromotionActionCalculatorParams":{"type":"object","properties":{"type":{"type":"string","description":"The calculator kind, from `GET /promotion_actions/calculators`. Changing it swaps the calculator."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the calculator's settings, such as `amount` or `flat_percent`."}}},"PromotionActionCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"The action kind, from `GET /promotion_actions/types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the action kind's settings schema, from `GET /promotion_actions/types`."},"calculator":{"allOf":[{"$ref":"#/components/schemas/PromotionActionCalculatorParams"}],"description":"For adjustment actions."},"line_items":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionLineItemParams"},"description":"For `create_line_items`: the variants to add and their quantities. Variants left out are removed."}},"required":["type"]},"PromotionActionDraftParams":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","description":"The action kind, from `GET /promotion_actions/types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the action kind's settings schema, from `GET /promotion_actions/types`."},"calculator":{"allOf":[{"$ref":"#/components/schemas/PromotionActionCalculatorParams"}],"description":"For adjustment actions."},"line_items":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionLineItemParams"},"description":"For `create_line_items`: the variants to add and their quantities. Variants left out are removed."}},"required":["type"]},"PromotionActionLineItemParams":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["variant_id","quantity"]},"PromotionActionUpdateParams":{"type":"object","properties":{"preferences":{"type":"object","additionalProperties":true,"description":"Values for the action kind's settings schema, from `GET /promotion_actions/types`."},"calculator":{"allOf":[{"$ref":"#/components/schemas/PromotionActionCalculatorParams"}],"description":"For adjustment actions."},"line_items":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionLineItemParams"},"description":"For `create_line_items`: the variants to add and their quantities. Variants left out are removed."}}},"PromotionCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"code":{"type":"string","description":"Required for single-code coupon promotions. Ignored when `multi_codes` is true.","nullable":true},"path":{"type":"string","nullable":true},"starts_at":{"type":"string","format":"date-time","nullable":true},"expires_at":{"type":"string","format":"date-time","nullable":true},"usage_limit":{"type":"integer","nullable":true},"match_policy":{"type":"string","enum":["all","any"]},"kind":{"type":"string","enum":["coupon_code","automatic"],"description":"`coupon_code` needs a code (or `multi_codes`); `automatic` applies without one."},"multi_codes":{"type":"boolean","description":"Generates `number_of_codes` codes starting with `code_prefix`."},"number_of_codes":{"type":"integer","nullable":true},"code_prefix":{"type":"string","nullable":true},"promotion_category_id":{"type":"string","nullable":true},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PromotionRuleDraftParams"},"description":"The rules the promotion should have: entries with `id` update, entries without are created, and rules left out are removed."},"actions":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionDraftParams"},"description":"The actions the promotion should have, matched the same way as `rules`."}},"required":["name"]},"PromotionRuleCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"The rule kind, from `GET /promotion_rules/types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's settings schema, from `GET /promotion_rules/types`."},"product_ids":{"type":"array","items":{"type":"string"},"description":"For the `product` rule."},"category_ids":{"type":"array","items":{"type":"string"},"description":"For the `category` rule."},"customer_ids":{"type":"array","items":{"type":"string"},"description":"For the `user` rule: the customers who qualify."}},"required":["type"]},"PromotionRuleDraftParams":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","description":"The rule kind, from `GET /promotion_rules/types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's settings schema, from `GET /promotion_rules/types`."},"product_ids":{"type":"array","items":{"type":"string"},"description":"For the `product` rule."},"category_ids":{"type":"array","items":{"type":"string"},"description":"For the `category` rule."},"customer_ids":{"type":"array","items":{"type":"string"},"description":"For the `user` rule: the customers who qualify."}},"required":["type"]},"PromotionRuleUpdateParams":{"type":"object","properties":{"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's settings schema, from `GET /promotion_rules/types`."},"product_ids":{"type":"array","items":{"type":"string"},"description":"For the `product` rule."},"category_ids":{"type":"array","items":{"type":"string"},"description":"For the `category` rule."},"customer_ids":{"type":"array","items":{"type":"string"},"description":"For the `user` rule: the customers who qualify."}}},"PromotionUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"code":{"type":"string","description":"Required for single-code coupon promotions. Ignored when `multi_codes` is true.","nullable":true},"path":{"type":"string","nullable":true},"starts_at":{"type":"string","format":"date-time","nullable":true},"expires_at":{"type":"string","format":"date-time","nullable":true},"usage_limit":{"type":"integer","nullable":true},"match_policy":{"type":"string","enum":["all","any"]},"kind":{"type":"string","enum":["coupon_code","automatic"],"description":"`coupon_code` needs a code (or `multi_codes`); `automatic` applies without one."},"multi_codes":{"type":"boolean","description":"Generates `number_of_codes` codes starting with `code_prefix`."},"number_of_codes":{"type":"integer","nullable":true},"code_prefix":{"type":"string","nullable":true},"promotion_category_id":{"type":"string","nullable":true},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PromotionRuleDraftParams"},"description":"The rules the promotion should have: entries with `id` update, entries without are created, and rules left out are removed."},"actions":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionDraftParams"},"description":"The actions the promotion should have, matched the same way as `rules`."}}},"PurchaseOrderCancelParams":{"type":"object","properties":{"reason":{"type":"string","description":"Appended to the order's notes."}}},"PurchaseOrderCreateParams":{"type":"object","properties":{"supplier_id":{"type":"string"},"destination_location_id":{"type":"string"},"currency":{"type":"string","description":"Defaults to the store's currency; set it for a foreign-currency order.","nullable":true},"expected_at":{"type":"string","format":"date","description":"The day the supplier promised. `null` clears it.","nullable":true},"cancel_by":{"type":"string","format":"date","description":"The day after which the goods are no longer wanted. `null` clears it.","nullable":true},"reference":{"type":"string","description":"The supplier's own order number. `null` clears it.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/PurchaseOrderItemParams"},"description":"Sending the list replaces whatever the order currently holds."}},"required":["supplier_id","destination_location_id"]},"PurchaseOrderItemParams":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity_ordered":{"type":"integer"},"unit_cost":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"What the merchant agreed to pay per unit."}},"required":["variant_id","quantity_ordered"]},"PurchaseOrderUpdateParams":{"type":"object","properties":{"supplier_id":{"type":"string"},"destination_location_id":{"type":"string"},"currency":{"type":"string","description":"Defaults to the store's currency; set it for a foreign-currency order.","nullable":true},"expected_at":{"type":"string","format":"date","description":"The day the supplier promised. `null` clears it.","nullable":true},"cancel_by":{"type":"string","format":"date","description":"The day after which the goods are no longer wanted. `null` clears it.","nullable":true},"reference":{"type":"string","description":"The supplier's own order number. `null` clears it.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/PurchaseOrderItemParams"},"description":"Sending the list replaces whatever the order currently holds."},"metadata":{"type":"object","additionalProperties":true,"nullable":true}}},"ReasonCreateParams":{"type":"object","properties":{"name":{"type":"string"},"active":{"type":"boolean","description":"Whether the reason is offered on new records."}},"required":["name"]},"ReasonUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"active":{"type":"boolean","description":"Whether the reason is offered on new records."}}},"ReceivableCloseParams":{"type":"object","properties":{"reason":{"type":"string","description":"Why the balance is not coming.","nullable":true}}},"RefundCreateParams":{"type":"object","properties":{"payment_id":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"refund_reason_id":{"type":"string","description":"Defaults to the store's first refund reason."}},"required":["payment_id","amount"]},"ReportingQueryParams":{"type":"object","properties":{"metrics":{"type":"array","items":{"type":"string"},"description":"Registered metric names, from the reporting schema endpoint."},"dimensions":{"type":"array","items":{},"description":"Up to 2 dimensions to break the metrics down by. Each is a dimension name, or `{ name, grain, include_empty }`: `grain` (`hour`, `day`, `week`, `month`) buckets a time dimension, and `include_empty` lists members with no matching rows where the schema entry supports it."},"filters":{"type":"array","items":{"type":"object","properties":{"dimension":{"type":"string"},"op":{"type":"string","enum":["eq","in"]},"value":{"description":"One value for `eq`, a list for `in`."}},"required":["dimension","op","value"]},"description":"Narrows the rows by dimension value."},"metric_filters":{"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"op":{"type":"string","enum":["eq","gt","gte","lt","lte"]},"value":{"type":"number"}},"required":["metric","op","value"]},"description":"Filters on an aggregate, such as `units_sold = 0`. Narrows the rows only; the totals stay the period's real figure. The metric must also appear in `metrics`, and cannot be a derived one."},"time_range":{"type":"object","properties":{"preset":{"type":"string"},"since":{"type":"string"},"until":{"type":"string"}},"description":"A named preset (`last_month`, `week_to_date`, any `last_<n>_<days|weeks|months>`), or ISO 8601 dates or times in `since` and `until` (a bare date covers the store's whole day). Defaults to the last 30 days, in the store's time zone."},"compare":{"type":"string","enum":["previous_period","previous_year"]},"sort":{"type":"string","description":"A metric name; prefix it with `-` to sort descending."},"limit":{"type":"integer","description":"At most 1000."},"currency":{"type":"string"}},"required":["metrics"]},"ReturnCancelParams":{"type":"object","properties":{"reason":{"type":"string","description":"A note on why the return was canceled."}}},"ReturnCreateParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"fulfillment_item_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["fulfillment_item_id","quantity"]},"description":"Fulfilled units coming back, and how many of each."},"stock_location_id":{"type":"string","description":"Where the goods come back to. Defaults to the location that shipped them."},"reason_id":{"type":"string","description":"One of the store's return reasons."},"memo":{"type":"string"}},"required":["items"]},"ReturnReceiveParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"return_line_item_id":{"type":"string"},"quantity":{"type":"integer"},"resellable":{"type":"boolean","description":"Goods that cannot be resold are received but never restocked. Defaults to true."}},"required":["return_line_item_id","quantity"]},"description":"What actually arrived. Omit to receive everything as requested and resellable; send rows for a partial or damaged receipt."}}},"ReturnRefundParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Defaults to the value of what was actually received."},"refund_method":{"type":"string","enum":["original_payment","store_credit"],"description":"`store_credit` issues credit immediately; `original_payment` (the default) refunds through the gateway that took the money."}}},"ReturnUpdateParams":{"type":"object","properties":{"stock_location_id":{"type":"string","description":"Where the goods come back to. Defaults to the location that shipped them."},"reason_id":{"type":"string","description":"One of the store's return reasons."},"memo":{"type":"string"},"metadata":{"type":"object","additionalProperties":true}}},"RoleCreateParams":{"type":"object","properties":{"name":{"type":"string","description":"Unique role name, the machine identifier shown capitalized in the dashboard."},"description":{"type":"string","nullable":true},"permissions":{"type":"array","items":{"type":"string"},"description":"Permission keys (`read_orders`, `write_products`, ...) from the permissions endpoint. You can only grant keys you hold yourself."}},"required":["name"]},"RoleUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"Unique role name, the machine identifier shown capitalized in the dashboard."},"description":{"type":"string","nullable":true},"permissions":{"type":"array","items":{"type":"string"},"description":"Permission keys (`read_orders`, `write_products`, ...) from the permissions endpoint. You can only grant keys you hold yourself."}}},"SavedReportCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"query":{"type":"object","additionalProperties":true,"description":"A reporting query, validated against the reporting registry on save."}},"required":["name","query"]},"SavedReportUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"query":{"type":"object","additionalProperties":true,"description":"A reporting query, validated against the reporting registry on save."}}},"SellerAddressParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"company":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"phone":{"type":"string"},"label":{"type":"string"},"zipcode":{"type":"string","description":"Legacy spelling of `postal_code`; send only one of the two."},"country_code":{"type":"string","description":"ISO 3166-1 alpha-2 code, such as `US`."},"state_code":{"type":"string","description":"The state or province abbreviation, such as `NY`."},"state_name":{"type":"string","description":"For countries without states in the database."}}},"SellerApproveParams":{"type":"object","properties":{"override_requirements":{"type":"boolean","description":"Admits a seller whose onboarding checklist is unfinished: the operator's deliberate exception, which the `seller.approved` event records along with what was outstanding."}}},"SellerCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"slug":{"type":"string","description":"URL-safe slug, derived from the name when omitted."},"contact_email":{"type":"string","nullable":true},"billing_email":{"type":"string","nullable":true},"about":{"type":"string","description":"Sanitized HTML: the seller's public description.","nullable":true},"logo_signed_id":{"type":"string","description":"A `signed_id` from the files upload endpoint to set the image, `null` to remove it, or omit the key to leave it untouched. The same applies to `square_logo_signed_id` and `cover_photo_signed_id`.","nullable":true},"square_logo_signed_id":{"type":"string","nullable":true},"cover_photo_signed_id":{"type":"string","nullable":true},"tax_remittance":{"type":"string","enum":["seller","platform"]},"payouts_schedule_interval":{"type":"string","enum":["daily","weekly","biweekly","monthly","manual"],"nullable":true},"minimum_payout_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"holiday_mode_until":{"type":"string","format":"date-time","description":"Set while the seller is away: the catalog stays but stops selling.","nullable":true},"legal_name":{"type":"string","nullable":true},"registration_number":{"type":"string","nullable":true},"metadata":{"type":"object","additionalProperties":true},"billing_address":{"allOf":[{"$ref":"#/components/schemas/SellerAddressParams"}],"description":"The seller's own billing address, written inline. There is no `billing_address_id`: an address belongs to whoever it was created for, so it is never referenced by id."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}},"required":["name"]},"SellerInviteParams":{"type":"object","properties":{"email":{"type":"string"},"role_id":{"type":"string","description":"A role this seller owns; defaults to the seller's own admin role.","nullable":true}},"required":["email"]},"SellerPayoutCompleteParams":{"type":"object","properties":{"reference":{"type":"string","description":"The provider's own id for the settlement, when one made it."}}},"SellerRejectParams":{"type":"object","properties":{"reason":{"type":"string"}}},"SellerReopenOnboardingParams":{"type":"object","properties":{"note":{"type":"string","description":"What the seller has to fix."}}},"SellerRequirementCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"The kind, from the seller requirement types endpoint."},"name":{"type":"string","description":"What the seller sees. Required for kinds that can be added more than once, since the wording is the only thing telling them apart. Left blank on the others, the kind names itself."},"description":{"type":"string","description":"Instructions shown to the seller."},"position":{"type":"integer","description":"Place in the checklist."},"active":{"type":"boolean"},"required":{"type":"boolean","description":"Whether this blocks approval. Off means recommended."},"preferences":{"type":"object","additionalProperties":true,"description":"Configuration for this kind, per its type's `schema`."},"metadata":{"type":"object","additionalProperties":true},"custom_field_definition_ids":{"type":"array","items":{"type":"string"},"description":"Custom field definitions this requirement asks the seller to fill in (`required_custom_fields` kind)."}},"required":["type"]},"SellerRequirementReviewParams":{"type":"object","properties":{"review_note":{"type":"string","description":"Kept with the decision. On a rejection it is the reason sent back to the seller."}}},"SellerRequirementUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"What the seller sees. Required for kinds that can be added more than once, since the wording is the only thing telling them apart. Left blank on the others, the kind names itself."},"description":{"type":"string","description":"Instructions shown to the seller."},"position":{"type":"integer","description":"Place in the checklist."},"active":{"type":"boolean"},"required":{"type":"boolean","description":"Whether this blocks approval. Off means recommended."},"preferences":{"type":"object","additionalProperties":true,"description":"Configuration for this kind, per its type's `schema`."},"metadata":{"type":"object","additionalProperties":true},"custom_field_definition_ids":{"type":"array","items":{"type":"string"},"description":"Custom field definitions this requirement asks the seller to fill in (`required_custom_fields` kind)."}}},"SellerRequirementWaiveParams":{"type":"object","properties":{"requirement_id":{"type":"string","description":"The requirement the seller is excused from."},"review_note":{"type":"string","description":"Why the seller is excused. Kept with the decision."}},"required":["requirement_id"]},"SellerSuspendParams":{"type":"object","properties":{"reason":{"type":"string"}}},"SellerUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"slug":{"type":"string","description":"URL-safe slug, derived from the name when omitted."},"contact_email":{"type":"string","nullable":true},"billing_email":{"type":"string","nullable":true},"about":{"type":"string","description":"Sanitized HTML: the seller's public description.","nullable":true},"logo_signed_id":{"type":"string","description":"A `signed_id` from the files upload endpoint to set the image, `null` to remove it, or omit the key to leave it untouched. The same applies to `square_logo_signed_id` and `cover_photo_signed_id`.","nullable":true},"square_logo_signed_id":{"type":"string","nullable":true},"cover_photo_signed_id":{"type":"string","nullable":true},"tax_remittance":{"type":"string","enum":["seller","platform"]},"payouts_schedule_interval":{"type":"string","enum":["daily","weekly","biweekly","monthly","manual"],"nullable":true},"minimum_payout_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"holiday_mode_until":{"type":"string","format":"date-time","description":"Set while the seller is away: the catalog stays but stops selling.","nullable":true},"legal_name":{"type":"string","nullable":true},"registration_number":{"type":"string","nullable":true},"metadata":{"type":"object","additionalProperties":true},"billing_address":{"allOf":[{"$ref":"#/components/schemas/SellerAddressParams"}],"description":"The seller's own billing address, written inline. There is no `billing_address_id`: an address belongs to whoever it was created for, so it is never referenced by id."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}}},"SetupParams":{"type":"object","properties":{"setup_token":{"type":"string","description":"The one-time token from the install output."},"email":{"type":"string","format":"email"},"password":{"type":"string"},"password_confirmation":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"store_name":{"type":"string"},"country_code":{"type":"string","description":"ISO 3166-1 alpha-2 country the store sells from. It determines the default market, the warehouse, the delivery zones and the currency."},"locale":{"type":"string","description":"Storefront locale. Defaults to the country's own language."},"currency":{"type":"string","description":"ISO 4217 currency. Defaults to the country's own currency: pass one only when the store prices in something else."},"sample_data":{"type":"boolean","description":"Load the demo catalog, customers and orders in the background once the admin account exists. The load takes minutes, so the response does not wait for it."}},"required":["setup_token","email","password","country_code"]},"ShippingLabelCreateParams":{"type":"object","properties":{"file_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`. Its presence records a label bought elsewhere instead of buying one; without it the body is ignored and the label is bought through the carrier."},"tracking_number":{"type":"string","description":"The number printed on an uploaded label. Required with `file_signed_id`."},"carrier":{"type":"string","description":"Free text; a forwarder's name is as valid as a carrier slug. Detected from the number when omitted."},"service":{"type":"string","description":"Carrier service the label was bought at."},"cost":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"What the merchant paid the carrier. Accounting data only; it never touches the order's shipping charge."},"currency":{"type":"string","description":"Currency of the cost."},"file_format":{"type":"string","enum":["pdf","png","zpl"],"description":"Taken from the file when omitted."},"tracking_url":{"type":"string","description":"Tracking page for the consignment the label mints."}}},"StockLevelBulkUpsertParams":{"type":"object","properties":{"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevelBulkUpsertRowParams"},"description":"Send an empty list to change nothing."}},"required":["stock_levels"]},"StockLevelBulkUpsertRowParams":{"type":"object","properties":{"variant_id":{"type":"string"},"stock_location_id":{"type":"string"},"count_on_hand":{"type":"integer","description":"The absolute level the external system reports.","nullable":true},"adjustment":{"type":"integer","description":"A relative change, for feeds that report movements rather than levels. Each row needs `count_on_hand` or `adjustment`.","nullable":true},"backorderable":{"type":"boolean","nullable":true}},"required":["variant_id","stock_location_id"]},"StockLevelParams":{"type":"object","properties":{"id":{"type":"string"},"stock_location_id":{"type":"string","description":"The location holding the stock (`sloc_...`)."},"count_on_hand":{"type":"integer","description":"Units physically at the location, not units available to sell: stock promised to placed orders counts until it ships. Sent as the count the shelf should end at; the API records the difference as an adjustment in the stock history."},"backorderable":{"type":"boolean","description":"Whether this location sells the variant beyond what it holds."}},"required":["stock_location_id","count_on_hand"]},"StockLevelUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"count_on_hand":{"type":"integer","description":"The count the shelf should end at: a whole number of zero or more. The API records the difference as an `adjusted` movement, so the correction appears in the stock history."},"adjustment":{"type":"integer","description":"A signed change to the shelf instead of a target count, applied to the count the API holds at that moment and recorded the same way. Cannot be sent together with `count_on_hand`."},"backorderable":{"type":"boolean","description":"Whether this location sells the variant beyond what it holds."},"reason":{"type":"string","description":"Labels the correction in the stock history. Defaults to \"Manual adjustment\"."},"metadata":{"type":"object","additionalProperties":true}}},"StockLocationCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"admin_name":{"type":"string","description":"Internal name shown only in the admin.","nullable":true},"active":{"type":"boolean"},"default":{"type":"boolean","description":"Setting to true demotes the previous default."},"kind":{"anyOf":[{"type":"string","enum":["warehouse","store","fulfillment_center"]},{"type":"string"}],"description":"Categorizes the location. The values listed are the built-in ones; extensions may add more."},"propagate_all_variants":{"type":"boolean"},"backorderable_default":{"type":"boolean"},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"zipcode":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_code":{"type":"string","description":"ISO-3166 alpha-2 country code.","nullable":true},"state_code":{"type":"string","description":"State or province abbreviation, resolved against the selected country's states.","nullable":true},"state_name":{"type":"string","description":"Free-text state for countries that don't have a states list.","nullable":true},"pickup_enabled":{"type":"boolean"},"pickup_stock_policy":{"type":"string","enum":["local","any"],"description":"`local` collects only items at this location; `any` lets items transfer in from other locations (ship-to-store)."},"pickup_ready_in_minutes":{"type":"integer","nullable":true},"returns_enabled":{"type":"boolean","description":"Whether customers may send returns to this location."},"pickup_instructions":{"type":"string","nullable":true}},"required":["name"]},"StockLocationUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"admin_name":{"type":"string","description":"Internal name shown only in the admin.","nullable":true},"active":{"type":"boolean"},"default":{"type":"boolean","description":"Setting to true demotes the previous default."},"kind":{"anyOf":[{"type":"string","enum":["warehouse","store","fulfillment_center"]},{"type":"string"}],"description":"Categorizes the location. The values listed are the built-in ones; extensions may add more."},"propagate_all_variants":{"type":"boolean"},"backorderable_default":{"type":"boolean"},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"zipcode":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_code":{"type":"string","description":"ISO-3166 alpha-2 country code.","nullable":true},"state_code":{"type":"string","description":"State or province abbreviation, resolved against the selected country's states.","nullable":true},"state_name":{"type":"string","description":"Free-text state for countries that don't have a states list.","nullable":true},"pickup_enabled":{"type":"boolean"},"pickup_stock_policy":{"type":"string","enum":["local","any"],"description":"`local` collects only items at this location; `any` lets items transfer in from other locations (ship-to-store)."},"pickup_ready_in_minutes":{"type":"integer","nullable":true},"returns_enabled":{"type":"boolean","description":"Whether customers may send returns to this location."},"pickup_instructions":{"type":"string","nullable":true}}},"StockReceiptCreateParams":{"type":"object","properties":{"reference":{"type":"string","description":"The supplier's delivery note, or the carrier's reference.","nullable":true},"received_at":{"type":"string","format":"date-time","description":"When the goods were counted in. Defaults to now.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockReceiptItemParams"},"description":"Omit to book in everything still outstanding, intact. Naming lines, even none, records exactly what the dock counted: `quantity_accepted` reaches the shelf; `quantity_rejected` is refused, recorded with a `rejection_reason` and never stocked."}}},"StockReceiptItemParams":{"type":"object","properties":{"id":{"type":"string","description":"The purchase order or transfer line."},"quantity_accepted":{"type":"integer"},"quantity_rejected":{"type":"integer"},"rejection_reason":{"type":"string","enum":["damaged","wrong_item","expired","other"],"nullable":true},"notes":{"type":"string","nullable":true}},"required":["id"]},"StockTransferCancelParams":{"type":"object","properties":{"on_in_transit":{"type":"string","enum":["restock","write_off"],"description":"Required once the units have left the source: either they come back (`restock`) or they are written off as lost (`write_off`)."},"reason":{"type":"string","description":"Recorded against the written-off lines.","nullable":true}}},"StockTransferCreateParams":{"type":"object","properties":{"source_location_id":{"type":"string"},"destination_location_id":{"type":"string"},"reference":{"type":"string","description":"The merchant's own label for the trip. `null` clears it.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockTransferItemParams"},"description":"A draft may open empty and gain lines as the merchant packs. Sending the list replaces whatever the draft currently holds."}},"required":["source_location_id","destination_location_id"]},"StockTransferItemParams":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity_shipped":{"type":"integer"}},"required":["variant_id","quantity_shipped"]},"StockTransferMarkInTransitParams":{"type":"object","properties":{"force":{"type":"boolean","description":"Ship even if it drives the source below zero."}}},"StockTransferUpdateParams":{"type":"object","properties":{"source_location_id":{"type":"string"},"destination_location_id":{"type":"string"},"reference":{"type":"string","description":"The merchant's own label for the trip. `null` clears it.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockTransferItemParams"},"description":"A draft may open empty and gain lines as the merchant packs. Sending the list replaces whatever the draft currently holds."},"metadata":{"type":"object","additionalProperties":true,"nullable":true}}},"StoreCreditApplyParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Defaults to the customer's available store credit, up to the order total."}}},"StoreUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"admin_locale":{"type":"string"},"timezone":{"type":"string"},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"unit_system":{"type":"string","enum":["metric","imperial"]},"storefront_access":{"type":"string","enum":["public","prices_hidden","login_required"],"description":"The store-wide default for what anonymous visitors can see. Channels fall back to it when they don't set their own."},"storefront_url":{"type":"string","description":"The storefront's public URL, the base for links in customer emails. Saving it also completes the storefront setup task.","nullable":true},"guest_checkout":{"type":"boolean","description":"The store-wide default for guest checkout. Channels fall back to it."},"always_include_confirm_step":{"type":"boolean","description":"Always show a confirmation step in checkout, even when no payment method requires one."},"company_field_enabled":{"type":"boolean","description":"Shows a company field on address forms."},"address_requires_company":{"type":"boolean","description":"Makes a company name mandatory on addresses."},"address_requires_phone":{"type":"boolean","description":"Makes a phone number mandatory on customer addresses."},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"],"description":"The store-wide default for when a customer is charged rather than only authorized. A payment method's own setting wins when set."},"preferred_auto_capture":{"type":"boolean","description":"Deprecated: Use `capture_method`. Removed in 6.1.","deprecated":true},"preferred_auto_capture_on_dispatch":{"type":"boolean","description":"Deprecated: Use `capture_method`. Removed in 6.1.","deprecated":true},"track_inventory_levels":{"type":"boolean","description":"Counts on-hand quantities. Off means everything is treated as always available."},"stock_reservations_enabled":{"type":"boolean","description":"Holds stock for shoppers while they check out, so the same item can't be sold twice."},"low_stock_threshold":{"type":"integer","description":"On-hand units at or below which a tracked variant counts as low stock on the home screen; 0 turns the warning off."},"tax_using_ship_address":{"type":"boolean","description":"Calculates tax from the shipping address. When false, tax is calculated from the billing address."},"track_price_history":{"type":"boolean","description":"Records price changes for the EU Omnibus lowest-price-in-30-days display."},"show_products_without_price":{"type":"boolean","description":"Whether products with no price in the shopper's currency still appear in listings."},"disable_sku_validation":{"type":"boolean","description":"Lets more than one variant share the same SKU."},"order_routing_strategy":{"type":"string","description":"The store-wide order routing strategy shorthand. Channels fall back to it."},"pricing_provider":{"type":"string","description":"Where prices come from: a registered provider key, or `internal`."},"inventory_provider":{"type":"string","description":"Where stock levels come from: a registered provider key, or `internal`."},"pricing_provider_failure_policy":{"type":"string","enum":["fallback","strict"],"description":"`strict` refuses to price when the provider cannot answer; `fallback` uses the catalog."},"inventory_provider_failure_policy":{"type":"string","enum":["fallback","strict"],"description":"`fallback` sells on the local stock snapshot when the provider cannot answer; `strict` refuses."},"payout_provider":{"type":"string","description":"Blank means the built-in provider: the marketplace settles by hand."},"default_payouts_schedule_interval":{"type":"string","enum":["daily","weekly","biweekly","monthly","manual"]},"default_minimum_payout_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"In the store's currency."},"auto_approve_sellers":{"type":"boolean","description":"Admits a seller as soon as they finish onboarding, with no operator review."},"auto_approve_seller_products":{"type":"boolean","description":"Puts a seller product on sale the moment it is submitted, with no review."},"send_seller_transactional_emails":{"type":"boolean","description":"When false, transactional seller emails (approval, payouts and so on) are not sent."},"default_commission_tax_rate":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Tax charged on commission as a fraction (`\"0.23\"` is 23%), when neither the commission rate nor the tax provider names one."},"document_number_format":{"type":"string","description":"How document numbers are produced: `sequential` or `random`. Applies to every numbered document."},"order_number_prefix":{"type":"string","description":"Leads every order number. Uppercase letters, digits, dashes and # only."},"order_number_suffix":{"type":"string","description":"Ends every order number. Uppercase letters, digits, dashes and # only."},"order_number_sequence_start":{"type":"integer","description":"The first sequential order number. Only applies before the store's first order."},"limit_digital_download_count":{"type":"boolean","description":"Whether a digital download link stops working after a number of clicks."},"digital_asset_authorized_clicks":{"type":"integer","description":"How many clicks a download link allows, unless the file sets its own."},"limit_digital_download_days":{"type":"boolean","description":"Whether a digital download link expires after a number of days."},"digital_asset_authorized_days":{"type":"integer","description":"How many days a download link stays valid, unless the file sets its own."},"mail_from_address":{"type":"string","description":"Sender address of every transactional email."},"customer_support_email":{"type":"string","description":"Customer-facing reply-to address shown in the storefront and email footers.","nullable":true},"new_order_notifications_email":{"type":"string","description":"Recipient of \"new order placed\" staff notifications.","nullable":true},"send_consumer_transactional_emails":{"type":"boolean","description":"When false, transactional customer emails (order confirmation and so on) are not sent."},"email_accent_color":{"type":"string","description":"Customer email buttons and links, as `#RRGGBB`. Blank keeps the outlined buttons emails ship with.","nullable":true},"email_background_color":{"type":"string","description":"Customer email page background, as `#RRGGBB`.","nullable":true},"email_card_color":{"type":"string","description":"Customer email card behind the content, as `#RRGGBB`.","nullable":true},"email_text_color":{"type":"string","description":"Customer email body text, as `#RRGGBB`.","nullable":true},"email_heading_color":{"type":"string","description":"Customer email headings and emphasized text, as `#RRGGBB`.","nullable":true},"email_font":{"type":"string","description":"Customer email font: `inter`, `system`, `helvetica`, `georgia`, `roboto`, `lato` or `merriweather`.","nullable":true},"logo_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the store logo, or null to remove it.","nullable":true},"mailer_logo_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the logo in transactional emails, or null to remove it.","nullable":true}}},"SupplierCreateParams":{"type":"object","properties":{"name":{"type":"string"},"contact_name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true},"postal_code":{"type":"string","nullable":true},"metadata":{"type":"object","additionalProperties":true,"nullable":true}},"required":["name"]},"SupplierUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"contact_name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true},"postal_code":{"type":"string","nullable":true},"metadata":{"type":"object","additionalProperties":true,"nullable":true}}},"TaxCategoryCreateParams":{"type":"object","properties":{"name":{"type":"string"},"tax_code":{"type":"string","nullable":true},"description":{"type":"string","nullable":true},"is_default":{"type":"boolean"}},"required":["name"]},"TaxCategoryUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"tax_code":{"type":"string","nullable":true},"description":{"type":"string","nullable":true},"is_default":{"type":"boolean"}}},"TaxExemptionCertificateParams":{"type":"object","properties":{"certificate_number":{"type":"string","description":"Required when creating."},"reason_code":{"type":"string","description":"Becomes the tax provider's entity use code. Required when creating."},"issuing_authority":{"type":"string","nullable":true},"issued_at":{"type":"string","format":"date-time","nullable":true},"expires_at":{"type":"string","format":"date-time","nullable":true},"country_code":{"type":"string","description":"Where the certificate holds. Omit both for one valid everywhere.","nullable":true},"state_code":{"type":"string","description":"Where the certificate holds. Omit both for one valid everywhere.","nullable":true},"document_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` with `visibility: 'private'`."},"metadata":{"type":"object","additionalProperties":true}}},"TaxIdentifierParams":{"type":"object","properties":{"kind":{"type":"string","description":"The registration the number belongs to, such as `eu_vat` or `gb_vat`. Any kind is accepted; one with a registered validator is checked by it. Built-in: `eu_vat`. Extensions may register more. Required when creating."},"value":{"type":"string","description":"Required when creating."}}},"TaxRateParams":{"type":"object","properties":{"name":{"type":"string","description":"Customer-facing rate name."},"rate":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"The rate as a fraction. Send this or `rate_percent`."},"rate_percent":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"The rate as a percentage."},"included_in_price":{"type":"boolean"},"show_rate_in_label":{"type":"boolean"},"tax_category_id":{"type":"string"},"country_code":{"type":"string","description":"ISO country code. A rate naming no country taxes everywhere.","nullable":true},"state_code":{"type":"string","description":"State abbreviation within that country.","nullable":true},"metadata":{"type":"object","additionalProperties":true}}},"TranslationBatchEntryParams":{"type":"object","properties":{"resource_type":{"type":"string","description":"Translatable resource type token, e.g. `option_type`."},"resource_id":{"type":"string"},"values":{"type":"object","additionalProperties":true,"description":"Translated fields keyed by locale code, then by field name."}},"required":["resource_type","resource_id","values"]},"TranslationBatchParams":{"type":"object","properties":{"translations":{"type":"array","items":{"$ref":"#/components/schemas/TranslationBatchEntryParams"},"description":"At least one entry. All entries are saved, or none are."}},"required":["translations"]},"VariantCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"sku":{"type":"string"},"barcode":{"type":"string"},"cost_price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"cost_currency":{"type":"string"},"weight":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"depth":{"type":"number","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"hs_code":{"type":"string"},"country_of_origin":{"type":"string"},"customs_description":{"type":"string"},"minimum_order_quantity":{"type":"integer","nullable":true},"order_multiple":{"type":"integer","nullable":true},"purchase_unit":{"type":"string"},"units_per_carton":{"type":"integer","description":"How many units fill one carton.","nullable":true},"carton_package_type_id":{"type":"string","description":"The carton this variant is packed into: a package type of kind `carton`. Its dimensions are shared by every product packed the same way, so a corrected carton size fixes all of them at once.","nullable":true},"carton_weight":{"type":"number","description":"What one packed carton weighs, in the variant's weight unit.","nullable":true},"cartons_per_pallet":{"type":"integer","description":"How many cartons stack on one pallet.","nullable":true},"seller_id":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"track_inventory":{"type":"boolean"},"preorderable":{"type":"boolean","description":"Sell this variant before it's in stock. Adds the pre-order label and ships-by promise; the cap comes from `backorder_limit`, an incoming stock count, or backorder."},"preorder_ships_at":{"type":"string","format":"date-time","description":"The \"ships by\" date shown to customers while the variant is a pre-order. Once it passes, the variant is no longer a pre-order. Null clears it.","nullable":true},"backorder_limit":{"type":"integer","description":"Maximum units sellable beyond available stock, capping backorders and pre-orders. Null is unlimited.","nullable":true},"tax_category_id":{"type":"string"},"position":{"type":"integer"},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Per-currency prices. Upserted by currency."},"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevelParams"},"description":"Stock per location. Upserted by location; omitted locations are removed."},"options":{"type":"array","items":{"$ref":"#/components/schemas/VariantOptionParams"},"description":"One pair per option type the variant takes part in (size, color). Option types and values are created when missing. On update, omit to leave the option values untouched."}},"required":["options"]},"VariantOptionParams":{"type":"object","properties":{"name":{"type":"string"},"value":{"type":"string"}},"required":["name","value"]},"VariantUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"sku":{"type":"string"},"barcode":{"type":"string"},"cost_price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"cost_currency":{"type":"string"},"weight":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"depth":{"type":"number","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"hs_code":{"type":"string"},"country_of_origin":{"type":"string"},"customs_description":{"type":"string"},"minimum_order_quantity":{"type":"integer","nullable":true},"order_multiple":{"type":"integer","nullable":true},"purchase_unit":{"type":"string"},"units_per_carton":{"type":"integer","description":"How many units fill one carton.","nullable":true},"carton_package_type_id":{"type":"string","description":"The carton this variant is packed into: a package type of kind `carton`. Its dimensions are shared by every product packed the same way, so a corrected carton size fixes all of them at once.","nullable":true},"carton_weight":{"type":"number","description":"What one packed carton weighs, in the variant's weight unit.","nullable":true},"cartons_per_pallet":{"type":"integer","description":"How many cartons stack on one pallet.","nullable":true},"seller_id":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"track_inventory":{"type":"boolean"},"preorderable":{"type":"boolean","description":"Sell this variant before it's in stock. Adds the pre-order label and ships-by promise; the cap comes from `backorder_limit`, an incoming stock count, or backorder."},"preorder_ships_at":{"type":"string","format":"date-time","description":"The \"ships by\" date shown to customers while the variant is a pre-order. Once it passes, the variant is no longer a pre-order. Null clears it.","nullable":true},"backorder_limit":{"type":"integer","description":"Maximum units sellable beyond available stock, capping backorders and pre-orders. Null is unlimited.","nullable":true},"tax_category_id":{"type":"string"},"position":{"type":"integer"},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Per-currency prices. Upserted by currency."},"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevelParams"},"description":"Stock per location. Upserted by location; omitted locations are removed."},"options":{"type":"array","items":{"$ref":"#/components/schemas/VariantOptionParams"},"description":"One pair per option type the variant takes part in (size, color). Option types and values are created when missing. On update, omit to leave the option values untouched."}}},"WebhookEndpointCreateParams":{"type":"object","properties":{"name":{"type":"string","description":"A label shown in the dashboard list.","nullable":true},"url":{"type":"string","description":"HTTPS destination URL. It cannot resolve to a private IP address outside development."},"active":{"type":"boolean","description":"Defaults to true on create. Prefer the disable and enable endpoints to pause one."},"subscriptions":{"type":"array","items":{"type":"string"},"description":"Event names this endpoint receives. An empty list or `[\"*\"]` subscribes to every event; otherwise list exact names (`order.completed`) or patterns (`order.*`)."}},"required":["url"]},"WebhookEndpointDisableParams":{"type":"object","properties":{"reason":{"type":"string","description":"Shown next to the disabled indicator. Defaults to \"Manually disabled\"."}}},"WebhookEndpointUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"A label shown in the dashboard list.","nullable":true},"url":{"type":"string","description":"HTTPS destination URL. It cannot resolve to a private IP address outside development."},"active":{"type":"boolean","description":"Defaults to true on create. Prefer the disable and enable endpoints to pause one."},"subscriptions":{"type":"array","items":{"type":"string"},"description":"Event names this endpoint receives. An empty list or `[\"*\"]` subscribes to every event; otherwise list exact names (`order.completed`) or patterns (`order.*`)."}}}}}}\ No newline at end of file+{"info":{"title":"Admin API","contact":{"name":"Spree Commerce","url":"https://spreecommerce.org","email":"[email protected]"},"description":"Spree Admin API v3 - Administrative API for managing products, orders, and store settings.\n\n## Authentication\n\nThe Admin API requires a secret API key passed in the `x-spree-api-key` header.\nSecret API keys can be generated in the Spree admin dashboard.\n\n## Response Format\n\nAll responses are JSON. List endpoints return paginated responses with `data` and `meta` keys.\nSingle resource endpoints return a flat JSON object.\n\n## Resource IDs\n\nEvery resource is identified by an opaque string ID (e.g. `prod_86Rf07xd4z`,\n`variant_k5nR8xLq`, `or_UkLWZg9DAJ`). Use these IDs everywhere — URL paths,\nrequest bodies, and Ransack filters all accept them directly.\n\n## Error Handling\n\nErrors return a consistent format:\n```json\n{\n \"error\": {\n \"code\": \"validation_error\",\n \"message\": \"Validation failed\",\n \"details\": { \"name\": [\"can't be blank\"] }\n }\n}\n```\n","version":"v3"},"paths":{"/api/v3/admin/auth/login":{"post":{"summary":"Login","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Authenticates an admin user and returns a short-lived JWT access token.\nThe rotatable refresh token is set in an HttpOnly cookie — it is not\nincluded in the response body.\n\nThe `provider` field selects the authentication method. When omitted it\ndefaults to `email`, the built-in email/password login.\n\nTo authenticate against a third-party identity provider (Okta, Azure AD,\nGoogle Workspace SSO, a custom JWT issuer, SAML, etc.), send\n`{ \"provider\": \"<your_key>\", ... }` with the fields that provider\nrequires. The endpoint returns the same JWT regardless of which provider\nauthenticated the request. See\n[Custom API Authentication](https://spreecommerce.org/docs/developer/how-to/custom-api-authentication)\nfor the list of configured providers and their required fields.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"login successful","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthResponse"}}}},"401":{"description":"invalid credentials","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"oneOf":[{"title":"EmailPasswordLogin","description":"Built-in email/password authentication (default when `provider` is omitted).","type":"object","properties":{"provider":{"type":"string","enum":["email"],"default":"email"},"email":{"type":"string","format":"email"},"password":{"type":"string"}},"required":["email","password"]},{"title":"ProviderLogin","description":"Provider-dispatched login. The `provider` key selects a configured\nauthentication provider; the remaining fields are forwarded to it.\nRequired fields depend on the provider — see\n[Custom API Authentication](https://spreecommerce.org/docs/developer/how-to/custom-api-authentication).\n","type":"object","properties":{"provider":{"type":"string","description":"Registered provider key (anything other than `email`).","not":{"enum":["email"]}}},"required":["provider"],"additionalProperties":true}]}}}}}},"/api/v3/admin/auth/refresh":{"post":{"summary":"Refresh token","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Exchanges the HttpOnly refresh-token cookie for a new access JWT and a\nrotated refresh token cookie. No request body or Authorization header\nis required — the cookie alone authenticates the call.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"refresh successful","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthResponse"}}}},"401":{"description":"missing or invalid refresh-token cookie","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/auth/logout":{"post":{"summary":"Logout","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Revokes the refresh-token cookie, effectively logging the admin out.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"logout successful"}}}},"/api/v3/admin/auth/invitations/{id}/accept":{"parameters":[{"name":"id","in":"path","description":"Invitation ID from the emailed link","required":true,"schema":{"type":"string"}}],"post":{"summary":"Accept an invitation","tags":["Authentication"],"description":"Accepts a staff invitation and returns a signed-in admin session, so the\nnew member lands in the dashboard rather than on a login form.\n\nUnauthenticated — the ID and token in the emailed link are the\ncredential. The email is never taken from the request; it always comes\nfrom the invitation.\n\n`password` is required when no account exists for the invited address,\nin which case it sets one. When an account already exists, the same\nfield is how the person proves the account is theirs.\n","parameters":[{"name":"token","in":"query","required":true,"description":"The token from the emailed link","schema":{"type":"string"}}],"responses":{"200":{"description":"invitation accepted, session issued","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthResponse"}}}},"404":{"description":"wrong token, or an invitation that can no longer be accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationAcceptParams"}}},"required":true}}},"/api/v3/admin/me":{"get":{"summary":"Get current admin user and permissions","tags":["Authentication"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the current admin user profile and a serialized list of permissions (CanCanCan rules). The SPA uses these to drive UI permission checks.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"current admin user and permissions","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeResponse"}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update the current admin profile","tags":["Authentication"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Self-service update of the signed-in admin's own profile, such as their admin UI display language (`selected_locale`).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"profile updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeUpdateParams"}}},"required":true}}},"/api/v3/admin/auth/password_resets":{"post":{"summary":"Request password reset","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Requests a password reset email for an admin user. Always returns `202`\nwhether or not the email matches an account, to prevent enumeration.\n\n`redirect_url` is where the emailed link should point (the reset token\nis appended as a `token` query param). It is honoured only on the\ndashboard's origin and for an account that is staff of the store —\notherwise it is silently ignored and the link opens the dashboard's\nreset page. The email is delivered by Spree itself via the\n`admin_user.password_reset_requested` event; this event is never\nforwarded to webhook endpoints.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"202":{"description":"reset requested","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordResetRequestParams"}}},"required":true}}},"/api/v3/admin/auth/password_resets/{id}":{"patch":{"summary":"Reset password","tags":["Authentication"],"security":[{"api_key":[]}],"description":"Consumes a password reset token (the `token` query param from the\nemailed link), sets the new password, and signs the admin in: the\nresponse carries a JWT access token and the rotatable refresh token is\nset in an HttpOnly cookie. The token is single-use — it invalidates as\nsoon as the password changes.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","description":"The reset token from the emailed link","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"password reset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthResponse"}}}},"422":{"description":"invalid or expired token","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordResetParams"}}},"required":true}}},"/api/v3/admin/auth/setup":{"get":{"summary":"Check first-run setup availability","tags":["Authentication"],"description":"Reports whether first-run setup is still available — true only while\nthe installation has no admin user. Unauthenticated; the dashboard\nlogin page uses it to offer the setup screen.\n","responses":{"200":{"description":"setup status","content":{"application/json":{}}}}},"post":{"summary":"Complete first-run setup","tags":["Authentication"],"description":"Creates the first admin account and adopts the seeded store, authorized\nby the one-time setup token printed at install time (rotate it with\n`bin/rails spree:setup:token`). Issues a JWT access token and a\nrefresh-token cookie exactly like login. Returns 404 once any admin\nuser exists — the flow is closed permanently after setup.\n","parameters":[],"responses":{"200":{"description":"setup completed","content":{"application/json":{}}},"404":{"description":"setup not available","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetupParams"}}},"required":true}}},"/api/v3/admin/auth/setup/countries":{"get":{"summary":"List countries for first-run setup","tags":["Authentication"],"description":"Countries the store can be set up in, each with the currency and\nofficial languages derived from it. Unauthenticated, because the setup\nscreen runs before any credential exists. Returns 404 once any admin\nuser exists.\n","responses":{"200":{"description":"countries","content":{"application/json":{}}}}}},"/api/v3/admin/allowed_origins":{"get":{"summary":"List allowed origins","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the CORS allowlist for the current store. Each entry is a\nbare `scheme://host[:port]` permitted to call the admin API from a\nbrowser. Backs the `Rack::Cors` allowlist and the CSRF boundary of\nthe admin cookie session (see\n`docs/plans/5.5-admin-auth-cookie-refresh.md`).\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of origin (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[origin_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `origin` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `origin`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"AllowedOrigin","sortable":["created_at","id","origin","updated_at"]},"responses":{"200":{"description":"allowed origins found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/AllowedOrigin"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create an allowed origin","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds an origin to the admin CORS allowlist. The value must be a bare\n`scheme://host[:port]` (no path, query, or fragment) and use `http` or\n`https`.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"allowed origin created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOrigin"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOriginCreateParams"}}},"required":true}}},"/api/v3/admin/allowed_origins/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Allowed origin ID","schema":{"type":"string"}}],"get":{"summary":"Get an allowed origin","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single allowed origin by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"allowed origin found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOrigin"}}}},"404":{"description":"allowed origin not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update an allowed origin","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an existing allowed origin.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"allowed origin updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOrigin"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllowedOriginUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an allowed origin","tags":["Allowed Origins"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes an origin from the admin CORS allowlist. After deletion the\nadmin SPA running at that origin will no longer be able to call the\nadmin API from a browser.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"allowed origin deleted"}}}},"/api/v3/admin/api_keys":{"get":{"summary":"List API keys","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns publishable and secret API keys for the current store. Secret keys are listed by `token_prefix` only — the plaintext token is delivered exactly once on create.\n\n**Required scope:** `read_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ApiKey","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"API keys found","content":{"application/json":{}}}}},"post":{"summary":"Create an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a publishable or secret API key. The plaintext token is included in the response **once** for secret keys; publishable keys expose their token on every read since they are intended for client-side use.\n\n**Required scope:** `write_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"secret key created — plaintext token returned once","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyCreateParams"}}},"required":true}}},"/api/v3/admin/api_keys/{id}":{"get":{"summary":"Show an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"API key found","content":{"application/json":{}}}}},"patch":{"summary":"Update an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a key. `key_type` and `scopes` are fixed at creation — to change a key's authority, create a new key and revoke the old one.\n\n**Required scope:** `write_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"API key renamed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"API key deleted"}}}},"/api/v3/admin/api_keys/current":{"get":{"summary":"Describe the current API key","tags":["API Keys"],"security":[{"api_key":[]}],"description":"Returns the secret key that authenticated this request, including its live scopes. Useful to confirm a key's real, current authority. Only secret-key principals have a single key to describe.\n\n**Required scope:** none — any key can describe itself (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"current API key","content":{"application/json":{}}}}}},"/api/v3/admin/api_keys/{id}/revoke":{"patch":{"summary":"Revoke an API key","tags":["API Keys"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Marks the key revoked. Future requests using its token will fail; the row is preserved for audit.\n\n**Required scope:** `write_api_keys` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"API key revoked","content":{"application/json":{}}}}}},"/api/v3/admin/categories":{"get":{"summary":"List categories","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of the store's categories (manual hierarchical taxons; rule-based collections are excluded).\n\n**Required scope:** `read_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name and pretty name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., children, parent, ancestors).","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `automatic` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `children_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `depth` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `parent_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `permalink` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `pretty_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `products_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[parent_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Category","sortable":["automatic","children_count","created_at","depth","id","name","parent_id","permalink","position","pretty_name","products_count","updated_at"]},"responses":{"200":{"description":"categories found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a category. Nests under the parent when parent_id is given, otherwise creates a top-level category.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"category created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryCreateParams"}}},"required":true}}},"/api/v3/admin/categories/{id}":{"get":{"summary":"Get a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single category by ID.\n\n**Required scope:** `read_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., children, parent, ancestors).","schema":{"type":"string"}}],"responses":{"200":{"description":"category found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}},"404":{"description":"category not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a category.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"200":{"description":"category updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a category and its descendants.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"204":{"description":"category deleted"}}}},"/api/v3/admin/categories/{id}/reposition":{"patch":{"summary":"Reposition a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Moves a category to a new parent and/or index within the tree.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"200":{"description":"category repositioned","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Category"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryRepositionParams"}}},"required":true}}},"/api/v3/admin/categories/{category_id}/products":{"get":{"summary":"List category products","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Products classified under the category, ordered by their classification position.\n\n**Required scope:** `read_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","created_at","description","discontinue_on","id","name","price","seller_id","slug","status","updated_at"]},"responses":{"200":{"description":"products found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Add products to a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Classifies products under the category in bulk (appended to the end). Already-classified products are skipped; the count reports what was added.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"201":{"description":"products added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}},"delete":{"summary":"Remove products from a category","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes products from the category's manual classification in bulk. Ids that are not classified are ignored; the count reports what was removed.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}}],"responses":{"200":{"description":"products removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}}},"/api/v3/admin/categories/{category_id}/products/{id}/reposition":{"patch":{"summary":"Reposition a category product","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Moves a product to a new index among the category's products.\n\n**Required scope:** `write_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"description":"Category ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"204":{"description":"product repositioned"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipRepositionParams"}}},"required":true}}},"/api/v3/admin/categories/{category_id}/custom_fields":{"get":{"summary":"List category custom fields","tags":["Categories"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the category's custom field values.\n\n**Required scope:** `read_categories` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"category_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/channels":{"get":{"summary":"List channels","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the channels configured for the current store.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `default` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `store_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Channel","sortable":["active","code","created_at","default","id","name","store_id","updated_at"]},"responses":{"200":{"description":"channels found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Channel"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new channel on the current store. `code` is normalized to a\nURL-safe slug (`Point of Sale` → `point-of-sale`); when omitted it's\nderived from `name`.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"channel created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelCreateParams"}}},"required":true}}},"/api/v3/admin/channels/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"channel found","content":{"application/json":{}}}}},"patch":{"summary":"Update a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"channel updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"channel deleted"}}}},"/api/v3/admin/channels/{id}/add_products":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"post":{"summary":"Publish products on a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Publishes the listed products on this channel. Idempotent — re-publishing\nan already-published product updates its publication window. Products from\nsibling stores are silently dropped.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products published","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelAddProductsParams"}}},"required":true}}},"/api/v3/admin/channels/{id}/remove_products":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"post":{"summary":"Unpublish products from a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Unpublishes the listed products from this channel.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products unpublished","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChannelRemoveProductsParams"}}},"required":true}}},"/api/v3/admin/channels/{channel_id}/order_routing_rules":{"parameters":[{"name":"channel_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List order routing rules for a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the channel's routing rules in priority order. The rules engine walks them top-down; see the Order Routing guide.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[active_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `channel_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `store_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `channel_id`, `created_at`, `id`, `position`, `store_id`, `type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"OrderRoutingRule","sortable":["active","channel_id","created_at","id","position","store_id","type","updated_at"]},"responses":{"200":{"description":"rules found","content":{"application/json":{}}}}},"post":{"summary":"Create an order routing rule on a channel","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a rule to the channel's routing list. The `type` is the wire shorthand from `GET /order_routing_rules/types` (e.g. `preferred_location`). Omitting `position` appends the rule at the end of the list. Each rule kind can appear at most once per channel — a duplicate `type` is rejected with a validation error.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"rule created","content":{"application/json":{}}},"422":{"description":"unknown rule type","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderRoutingRuleCreateParams"}}},"required":true}}},"/api/v3/admin/channels/{channel_id}/order_routing_rules/{id}":{"parameters":[{"name":"channel_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update an order routing rule","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a rule's `active` flag, `position` (the list reorders around it), or `preferences`. The rule kind cannot be changed — delete and re-create instead.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rule updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderRoutingRuleUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an order routing rule","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"rule deleted"}}}},"/api/v3/admin/order_routing_rules/types":{"get":{"summary":"List available order routing rule types","tags":["Channels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Enumerates the registered rule kinds with their labels, descriptions and preference schemas — drives the \"Add rule\" picker in the admin dashboard. Plugins extend the list by registering `Spree::OrderRoutingRule` subclasses via `Spree.order_routing.rules`.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"types found","content":{"application/json":{}}}}}},"/api/v3/admin/custom_field_definitions":{"get":{"summary":"List custom field definitions","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all defined custom fields. Filter by `?q[resource_type_eq]=product` to narrow to one parent type.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of namespace, key, and label (partial, case-insensitive)."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,label,field_type). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[key_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `field_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `key` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `label` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `namespace` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `resource_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `searchable` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `sortable` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `storefront_visible` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `field_type`, `id`, `key`, `label`, `namespace`, `resource_type`, `searchable`, `sortable`, `storefront_visible`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomFieldDefinition","sortable":["created_at","field_type","id","key","label","namespace","resource_type","searchable","sortable","storefront_visible","updated_at"]},"responses":{"200":{"description":"definitions returned","content":{"application/json":{}}}}},"post":{"summary":"Create a custom field definition","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"definition created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomFieldDefinitionCreateParams"}}},"required":true}}},"/api/v3/admin/custom_field_definitions/{id}":{"get":{"summary":"Show a custom field definition","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,label,field_type). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"definition found","content":{"application/json":{}}}}},"patch":{"summary":"Update a custom field definition","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"definition updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomFieldDefinitionUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a custom field definition","tags":["Custom Fields"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes the definition and cascades to all custom field values referencing it.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"definition deleted"}}}},"/api/v3/admin/customer_groups":{"get":{"summary":"List customer groups","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer groups configured for the current store. Groups\nsegment customers for targeted promotions (see the `customer_group`\npromotion rule) and reporting. The list endpoint never embeds the\nmember list — fetch a single group with `?expand=customers` if you\nneed them inline, or query `/admin/customers?customer_group_id_in=…`\nfor paginated membership.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomerGroup","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"customer groups found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomerGroup"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a customer group","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a customer group in the current store. `customer_ids` is\noptional; when present, customers are attached at create time.\nPass prefixed IDs (e.g. `cus_…`) — the server decodes them\nautomatically.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"customer group created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroup"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroupCreateParams"}}},"required":true}}},"/api/v3/admin/customer_groups/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Customer group prefixed ID","schema":{"type":"string"}}],"get":{"summary":"Get a customer group","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single customer group. Pass `?expand=customers` to embed\nthe full member list inline (recommended only for single-record\nreads — embed cost scales with membership size).\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed. Supported: `customers`.","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"customer group with embedded customers","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroup"}}}},"404":{"description":"customer group not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a customer group","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates name, description, or membership. `customer_ids` is a\nfull-set replacement — the server reconciles the membership to\nmatch the array, adding new IDs and removing ones not present.\nSend `customer_ids: []` to clear all members.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customer group updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroup"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerGroupUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a customer group","tags":["Customer Groups"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the group. Member users are not deleted; their `customer_group_users` rows are dropped.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"customer group deleted"}}}},"/api/v3/admin/customers/{customer_id}/custom_fields":{"get":{"summary":"List customer custom fields","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer's custom field values.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/customers/{id}/export":{"get":{"summary":"Export a customer's personal data","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns everything the store holds about this customer, for answering a\nGDPR right-of-access request (Art. 15) that reached the merchant\ndirectly.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customer data","content":{"application/json":{"schema":{"type":"object","properties":{"account":{"type":"object"},"marketing_consent":{"type":"object"},"consent_records":{"type":"array","items":{"type":"object"}},"addresses":{"type":"array","items":{"type":"object"}},"orders":{"type":"array","items":{"type":"object"}},"exported_at":{"type":"string"}}}}}},"404":{"description":"not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/customers/{id}/anonymize":{"post":{"summary":"Erase a customer's personal data","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Carries out a GDPR right-to-erasure request (Art. 17). Personal data is\nreplaced across the account, its addresses, the address snapshots on\npast orders, saved cards, connected identities and live sessions.\n\nOrders, payments and tax records are kept — they carry their own\nretention obligation — with the personal details removed. The country,\nstate and a truncated postal code survive on order addresses so the tax\njurisdiction of a past sale stays provable.\n\nIrreversible.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customer anonymized","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"anonymized":{"type":"boolean"},"anonymized_at":{"type":"string","nullable":true}}}}}}}}},"/api/v3/admin/consent_records":{"get":{"summary":"List consent records","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the consents customers gave or withdrew, newest first, as evidence of what each one agreed to and when.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[email_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `accepted` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `purpose` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `recorded_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `source` | One of `checkout`, `registration`, `account`, `admin`, `newsletter`, `anonymization`, `unknown`, `import`, `storefront` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `accepted`, `created_at`, `email`, `id`, `purpose`, `recorded_at`, `source`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ConsentRecord","sortable":["accepted","created_at","email","id","purpose","recorded_at","source","updated_at"]},"responses":{"200":{"description":"consent records found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ConsentRecord"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/data_requests":{"get":{"summary":"List data requests","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the requests customers made to export or erase their personal data, newest first.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[access]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `access`."},{"name":"q[erasure]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `erasure`."},{"name":"q[in_progress]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_progress`."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `completed_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `access`, `erasure` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `requested_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `status` | One of `pending`, `processing`, `completed`, `failed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `completed_at`, `created_at`, `email`, `id`, `kind`, `number`, `requested_at`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DataRequest","sortable":["completed_at","created_at","email","id","kind","number","requested_at","status","updated_at"]},"responses":{"200":{"description":"data requests found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DataRequest"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Record a data request","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records a request a customer made to the merchant directly, to export\nor erase their personal data, and starts answering it. A request of the\nsame kind already in progress for the customer is returned instead of a\nsecond one.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"202":{"description":"data request recorded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DataRequest"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DataRequestCreateParams"}}},"required":true}}},"/api/v3/admin/customers/{customer_id}/addresses":{"get":{"summary":"List customer addresses","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer's saved addresses.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., country, state). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., first_name,last_name,address1,city). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[address1_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `address1` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `address2` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `city` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `company` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `first_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `last_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `phone` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `postal_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Address","sortable":["address1","address2","city","company","country_code","created_at","first_name","id","last_name","phone","postal_code","state_code","updated_at"]},"responses":{"200":{"description":"addresses found","content":{"application/json":{}}}}},"post":{"summary":"Create a customer address","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a new address to the customer's address book. Pass `is_default_billing: true` or `is_default_shipping: true` to set as the default — the previous default loses its flag in the same transaction.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"address created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerAddressParams"}}},"required":true}}},"/api/v3/admin/customers/{customer_id}/addresses/{id}":{"patch":{"summary":"Update a customer address","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a customer address.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"address updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerAddressParams"}}},"required":true}},"delete":{"summary":"Delete a customer address","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes the address. If it was a default, the customer loses that default (no auto-promotion).\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"address deleted"}}}},"/api/v3/admin/customers/{customer_id}/credit_cards":{"get":{"summary":"List customer credit cards","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer's saved credit cards. Useful for off-session admin charges via `POST /admin/orders/:id/payments { source_id }`.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment_method). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., brand,last4,month,year). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CreditCard","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"credit cards found","content":{"application/json":{}}}}}},"/api/v3/admin/customers/{customer_id}/credit_cards/{id}":{"get":{"summary":"Show a customer credit card","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a saved credit card by ID.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment_method). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., brand,last4,month,year). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"credit card found","content":{"application/json":{}}}}},"delete":{"summary":"Delete a customer credit card","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a saved credit card.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"credit card deleted"}}}},"/api/v3/admin/customers/{customer_id}/store_credits":{"get":{"summary":"List customer store credits","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns store credits issued to the customer.\n\n**Required scope:** `read_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of memo (partial, case-insensitive)."},{"name":"q[from_gift_card]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `from_gift_card`."},{"name":"q[outstanding]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `outstanding`."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., store, created_by). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., amount,amount_used,memo,currency). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `customer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `memo` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[created_by_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `created_by_` | `created_at`, `email`, `first_name`, `id`, `last_name`, `updated_at` |\n| `created_by_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customer_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `customer_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `created_by_id`, `currency`, `customer_id`, `id`, `memo`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StoreCredit","sortable":["amount","created_at","created_by_id","currency","customer_id","id","memo","updated_at"]},"responses":{"200":{"description":"store credits found","content":{"application/json":{}}}}},"post":{"summary":"Issue a store credit to a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"`created_by` is set automatically from the authenticated admin.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"store credit created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerStoreCreditCreateParams"}}},"required":true}}},"/api/v3/admin/customers/{customer_id}/store_credits/{id}":{"patch":{"summary":"Update a store credit","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Update memo / amount. The amount can only be changed if `amount_used == 0`.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"store credit updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerStoreCreditUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a store credit","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes an unused store credit (amount_used == 0). Returns 422 otherwise.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"store credit deleted"}}}},"/api/v3/admin/customers/{customer_id}/tax_identifiers":{"get":{"summary":"List customer tax registrations","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the customer's own tax registrations, one per kind.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"customer_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxIdentifier","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"registrations found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TaxIdentifier"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/customers":{"get":{"summary":"List customers","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of customers. Supports Ransack search/filters.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches email, first name, last name or full name (partial, case-insensitive)."},{"name":"q[anonymized]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `anonymized`."},{"name":"q[with_min_total_spent]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `with_min_total_spent` to the given value."},{"name":"q[with_standing_for_company][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_standing_for_company` to the given value."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., addresses, store_credits). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., email,first_name,last_name). id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[email_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `accepts_email_marketing` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `first_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `last_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `phone` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[addresses_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `orders_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `orders_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `orders_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `orders_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `orders_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `orders_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Customer","sortable":["accepts_email_marketing","created_at","email","first_name","id","last_name","phone","updated_at"]},"responses":{"200":{"description":"customers found","content":{"application/json":{}}}}},"post":{"summary":"Create a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a customer. No welcome email is sent automatically.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"customer created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerCreateParams"}}},"required":true}}},"/api/v3/admin/customers/{id}":{"get":{"summary":"Show a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns full customer details including computed order stats (orders_count, total_spent, last_order_completed_at).\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Customer ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations: addresses, orders, store_credits, default_billing_address, default_shipping_address","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., email,first_name,last_name). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"customer found","content":{"application/json":{}}}}},"patch":{"summary":"Update a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates customer attributes. `tags` replaces the full set.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customer updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a customer","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a customer. Returns 422 if the customer has any orders.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"customer deleted"}}}},"/api/v3/admin/customers/bulk_add_to_groups":{"post":{"summary":"Bulk-add customers to groups","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Attaches each customer in `ids` to every group in `customer_group_ids`.\nIdempotent — customers already in a group are skipped server-side.\nGroups from sibling stores are silently ignored. Returns counts of\ncustomers and groups that were processed (post store-scoping).\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customers added to groups","content":{"application/json":{"schema":{"type":"object","properties":{"customer_count":{"type":"integer"},"customer_group_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerBulkGroupsParams"}}},"required":true}}},"/api/v3/admin/customers/bulk_remove_from_groups":{"post":{"summary":"Bulk-remove customers from groups","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Detaches each customer in `ids` from every group in `customer_group_ids`.\nNo-op for non-members. Groups from sibling stores are silently ignored.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"customers removed from groups","content":{"application/json":{"schema":{"type":"object","properties":{"customer_count":{"type":"integer"},"customer_group_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerBulkGroupsParams"}}},"required":true}}},"/api/v3/admin/customers/bulk_add_tags":{"post":{"summary":"Bulk-add tags to customers","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds each tag name in `tags` to every customer in `ids`. Tags are\nupserted by name; re-adding an existing tag is a no-op.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"tags added","content":{"application/json":{"schema":{"type":"object","properties":{"customer_count":{"type":"integer"},"tag_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTagsParams"}}},"required":true}}},"/api/v3/admin/customers/bulk_remove_tags":{"post":{"summary":"Bulk-remove tags from customers","tags":["Customers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes each tag name in `tags` from every customer in `ids`. No-op\nfor customers that don't carry the tag.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"tags removed","content":{"application/json":{"schema":{"type":"object","properties":{"customer_count":{"type":"integer"},"tag_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTagsParams"}}},"required":true}}},"/api/v3/admin/email_templates":{"get":{"summary":"List email templates","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every email template merchants may edit: the emails customers\nreceive, the email layout and the shared partials. Each shows what\ncustomers receive now (the store's published version, else Spree's\ndefault) and any draft in progress. Staff emails are not editable.\n\n\n**Required scope:** `read_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default) for the version every language uses","schema":{"type":"string"}}],"responses":{"200":{"description":"email templates found","content":{"application/json":{}}}}}},"/api/v3/admin/email_templates/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"The template key with dots, e.g. `spree.order_mailer.confirm_email`","schema":{"type":"string"}}],"get":{"summary":"Get an email template","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the template for one language: what customers receive now,\nSpree's default, and the draft with its `lock_version`. When Spree's\ndefault changed since the store's version started from it,\n`default_changed` is true and `base_body` holds the default it\nstarted from, to compare with `default_body`.\n\n\n**Required scope:** `read_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default)","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (`draft.updated_by`)","schema":{"type":"string"}}],"responses":{"200":{"description":"email template found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}},"404":{"description":"not an editable template","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"delete":{"summary":"Revert an email template to Spree's default","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Goes back to Spree's default for one language and discards the draft.\nThe store's published versions are kept, so one can still be restored.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default)","schema":{"type":"string"}},{"name":"lock_version","in":"query","required":false,"description":"The draft's `lock_version` as last seen; a draft saved since is refused with 409","schema":{"type":"integer"}}],"responses":{"200":{"description":"email template reverted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}}}}},"/api/v3/admin/email_templates/{email_template_id}/draft":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"put":{"summary":"Save an email template draft","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Saves the draft, in any state; customers keep receiving the published\nversion until it is published. Send the `lock_version` the draft was\nloaded with: a save made from an older copy is refused with 409,\nnaming who saved last. The first save starts from what is published,\nelse Spree's default.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"draft saved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}},"409":{"description":"saved by someone else since it was loaded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateDraftParams"}}},"required":true}},"delete":{"summary":"Discard an email template draft","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default)","schema":{"type":"string"}},{"name":"lock_version","in":"query","required":false,"description":"The draft's `lock_version` as last seen; a draft saved since is refused with 409","schema":{"type":"integer"}}],"responses":{"200":{"description":"draft discarded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}}}}},"/api/v3/admin/email_templates/{email_template_id}/publication":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"post":{"summary":"Publish an email template draft","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Makes the draft what customers receive. The draft is first rendered\nwith sample data; one that does not render (for the layout or a\npartial: in any email using it) is refused with 422, listing each\nproblem with its email and line.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"draft published","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}},"422":{"description":"the draft does not render","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateVersionParams"}}}}}},"/api/v3/admin/email_templates/{email_template_id}/preview":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"post":{"summary":"Preview an email template","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renders the template with sample data built from the store's latest\nmatching record, or the one `record_id` names, and returns the email\nwith the variables it was rendered with. An unsaved `subject` and\n`body` take the place of the current version. The layout and partials\nrender inside an email, `email_key` or the first one. `branding`\npreviews colors and a font before they are saved to the store.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"email template rendered","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplatePreview"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplatePreviewParams"}}},"required":true}}},"/api/v3/admin/email_templates/{email_template_id}/test_email":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"post":{"summary":"Send a test email","tags":["Email Templates"],"security":[{"bearer_auth":[]}],"description":"Sends the template, rendered as the preview renders it, to the\nsigned-in admin, and never to another address: the sample data comes\nfrom a real customer's records. Takes the same body as the preview.\n","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"202":{"description":"test email queued","content":{"application/json":{"schema":{"type":"object","properties":{"sent_to":{"type":"string"}},"required":["sent_to"]}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplatePreviewParams"}}},"required":true}}},"/api/v3/admin/email_templates/{email_template_id}/sample_records":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"get":{"summary":"List records to preview an email template with","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The store's five latest records the template can be previewed with,\nnewest first, to pass as `record_id` to the preview. For the layout\nand partials, those of the email `email_key` names. Empty for an\nemail that needs no record.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"email_key","in":"query","required":false,"description":"For the layout or a partial, the email to show it in","schema":{"type":"string"}}],"responses":{"200":{"description":"records found","content":{"application/json":{}}}}}},"/api/v3/admin/email_templates/{email_template_id}/revisions":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}}],"get":{"summary":"List email template revisions","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every version of the template published in one language, newest\nfirst. Reverting to Spree's default keeps them.\n\n\n**Required scope:** `read_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"language","in":"query","required":false,"description":"A language code, or `any` (the default)","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (`published_by`)","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"EmailTemplateRevision","sortable":["created_at","id"]},"responses":{"200":{"description":"revisions found","content":{"application/json":{}}}}}},"/api/v3/admin/email_templates/{email_template_id}/revisions/{revision_id}/restoration":{"parameters":[{"name":"email_template_id","in":"path","required":true,"description":"The template key with dots","schema":{"type":"string"}},{"name":"revision_id","in":"path","required":true,"schema":{"type":"string"}}],"post":{"summary":"Restore an email template revision","tags":["Email Templates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Copies the revision into the draft, to be published like any change.\nSend the draft's `lock_version` when one is open, as when saving it.\n\n\n**Required scope:** `write_email_templates` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"revision copied into the draft","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplate"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateRestoreParams"}}}}}},"/api/v3/admin/exports":{"get":{"summary":"List exports","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns CSV exports queued or completed for the current store. Polled by the admin SPA to detect when an export finishes (`done: true`).\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `format` | One of `csv` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `format`, `id`, `number`, `seller_id`, `type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Export","sortable":["created_at","format","id","number","seller_id","type","updated_at"]},"responses":{"200":{"description":"exports found","content":{"application/json":{}}}}},"post":{"summary":"Create an export","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Queues a CSV export. The `type` selects the dataset; `search_params` is an\noptional Ransack query (same shape used by the `q[...]` params on list endpoints)\nthat filters which records are exported. Pass `record_selection: \"all\"` to\nclear the filter server-side and export everything in scope.\n\nGeneration is asynchronous. Poll `GET /admin/exports/{id}` until `done` is `true`,\nthen redirect the browser to `download_url` to fetch the file.\n\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"export queued","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExportCreateParams"}}},"required":true}}},"/api/v3/admin/exports/{id}":{"get":{"summary":"Show an export","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns export status. While `done` is `false`, the SPA continues polling.\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"export found","content":{"application/json":{}}}}},"delete":{"summary":"Delete an export","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes the export and purges its attachment.\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"export deleted"}}}},"/api/v3/admin/exports/{id}/download":{"get":{"summary":"Download an export","tags":["Exports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Streams the exported CSV with `Content-Disposition: attachment`. Returns 422 with `code: export_not_ready` while `done` is still `false`. The endpoint is JWT/API-key protected, so SPA clients must fetch it (with `Authorization` header) and trigger the browser download via a Blob URL — a top-level navigation cannot carry the JWT.\n\n**Required scope:** the read scope of the exported resource — `read_products` for product exports, `read_customers` for customer exports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"CSV file","content":{"application/json":{},"text/csv":{"schema":{"type":"string","format":"binary"}}}}}}},"/api/v3/admin/files":{"post":{"summary":"Upload a file","tags":["Files"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Accepts a file and returns a `signed_id` to send to the endpoint that\nuses it — `signed_id` on product media, `avatar_signed_id` on a\ncustomer, `attachment_signed_id` on an import, and so on.\n\nTwo ways to send the bytes, one response:\n\n- **Presigned** (JSON): send the file's metadata, then `PUT` the bytes\n to `upload.url` with exactly `upload.headers`. Use this for anything\n large — the bytes go straight to storage.\n- **Multipart**: send the bytes in a `file` part. The file is stored\n before the response, so `upload` is null. Limited to 10 MB by default.\n\n`signed_id` is opaque: pass it back unchanged and never parse it. It\nstops being attachable at `expires_at`, one day after the upload.\n\n`visibility` picks the storage: `public` (the default) for images and\nvideos customers see, `private` for documents, imports and digital\nproducts. Public uploads accept web images, videos and CSV; private\nuploads accept any type. `checksum` is the file's MD5 digest,\nbase64-encoded — the storage service verifies the bytes against it.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"presigned upload target created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FileUpload"}}}},"422":{"description":"content type not allowed for a public upload","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FileUploadCreateParams"}},"multipart/form-data":{"schema":{"$ref":"#/components/schemas/FileUploadCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments":{"get":{"summary":"List fulfillments","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all shipments for an order.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., inventory_units, stock_location, shipping_rates). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., number,status,tracking,cost). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Fulfillment","sortable":["created_at","id","number","updated_at"]},"responses":{"200":{"description":"fulfillments found","content":{"application/json":{}}}}},"post":{"summary":"Create a fulfillment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Manually creates a fulfillment on a completed order, bypassing order routing — for example to mirror a shipment handled by an external carrier or 3PL. Moves the requested line item quantities out of their current fulfillments; when `items` is omitted, every not-yet-shipped unit is moved. Exchange and claim replacements are moved only out of a named `source_fulfillment_id`, which is how a canceled replacement is sent again. Pass `status: 'shipped'` to register an already-shipped fulfillment (fires shipped webhooks and freezes cost/carrier). When `delivery_method_id` is omitted, the fulfillment inherits the delivery method and cost of the source fulfillment(s) it fully drains — keeping the order total unchanged; partially drained splits get no carrier when shipped, and pending fulfillments are otherwise (re)priced by the standard rate engine, which selects the lowest-cost available rate. Pass `cost` to set an explicit shipping cost instead (e.g. the 3PL price) — note this changes the order total and payment state, and is guaranteed to persist only with `status: 'shipped'` (pending fulfillments are re-priced by the rate engine).\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"fulfillment created","content":{"application/json":{}}},"422":{"description":"order not completed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}":{"get":{"summary":"Show a shipment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns details of a specific shipment.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., inventory_units, stock_location, shipping_rates). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., number,status,tracking,cost). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"shipment found","content":{"application/json":{}}}}},"patch":{"summary":"Update a shipment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a fulfillment (tracking, delivery rate).\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"shipment updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}/fulfill":{"patch":{"summary":"Fulfill a fulfillment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Marks a fulfillment as fulfilled.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fulfillment fulfilled","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentFulfillParams"}}}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}/mark_delivered":{"patch":{"summary":"Mark a fulfillment delivered","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records that the customer received the goods. Only a fulfilled shipment can be marked delivered.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fulfillment delivered","content":{"application/json":{}}},"422":{"description":"fulfillment has not shipped","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentMarkDeliveredParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}/cancel":{"patch":{"summary":"Cancel a fulfillment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Cancels a fulfillment.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fulfillment canceled","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{id}/split":{"patch":{"summary":"Split a fulfillment","tags":["Fulfillments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Transfers items from this shipment to a new shipment at a different stock location.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fulfillment split","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FulfillmentSplitParams"}}},"required":true}}},"/api/v3/admin/gift_card_batches":{"get":{"summary":"List gift card batches","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the gift card batches issued by the current store. Each batch\ngroups the cards generated together for a campaign or bulk-issuance\n— the cards themselves live under `/admin/gift_cards` and reference\nthe batch via `gift_card_batch_id`.\n\n\n**Required scope:** `read_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[prefix_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `prefix` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `prefix`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"GiftCardBatch","sortable":["created_at","id","prefix","updated_at"]},"responses":{"200":{"description":"gift card batches found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/GiftCardBatch"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a gift card batch","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Issues a batch of gift cards in a single call. The server generates\n`codes_count` cards inline for small batches (configurable via\n`Spree.config.gift_card_batch_web_limit`, default 500) or enqueues\na background job for larger ones. Each card's code is the batch\n`prefix` followed by random hex.\n\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"gift card batch created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardBatch"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardBatchCreateParams"}}},"required":true}}},"/api/v3/admin/gift_card_batches/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Gift card batch prefixed ID","schema":{"type":"string"}}],"get":{"summary":"Get a gift card batch","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single batch.\n\n**Required scope:** `read_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"gift card batch found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardBatch"}}}},"404":{"description":"gift card batch not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/gift_cards":{"get":{"summary":"List gift cards","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the gift cards issued by the current store. Filter by\n`q[code_cont]` for code search, `q[customer_id_eq]` for cards issued\nto a specific customer, or `q[status_eq]` for status filtering.\n\n\n**Required scope:** `read_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of code (partial, case-insensitive)."},{"name":"q[active]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `active`."},{"name":"q[expired]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `expired`."},{"name":"q[partially_redeemed]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `partially_redeemed`."},{"name":"q[redeemed]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `redeemed`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[code_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `customer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `expires_at` | Date | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `gift_card_batch_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `state` | One of `active`, `partially_redeemed`, `redeemed`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `active`, `partially_redeemed`, `redeemed`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[batch_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `batch_` | `created_at`, `id`, `prefix`, `updated_at` |\n| `customers_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customers_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customers_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customers_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customers_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `customers_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customers_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customers_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `orders_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `orders_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `orders_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `orders_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `orders_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `orders_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `orders_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `users_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `users_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `users_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `users_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `users_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `users_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `users_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `users_tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `code`, `created_at`, `created_by_id`, `currency`, `customer_id`, `expires_at`, `gift_card_batch_id`, `id`, `state`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"GiftCard","sortable":["code","created_at","created_by_id","currency","customer_id","expires_at","gift_card_batch_id","id","state","status","updated_at"]},"responses":{"200":{"description":"gift cards found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/GiftCard"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a gift card","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Issues a gift card scoped to the current store. The code is\nauto-generated when omitted. `currency` defaults to the store's\nconfigured currency. Pass `customer_id` (prefixed ID) to attach the\ncard to a specific customer.\n\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"gift card created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCard"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardCreateParams"}}},"required":true}}},"/api/v3/admin/gift_cards/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Gift card prefixed ID","schema":{"type":"string"}}],"get":{"summary":"Get a gift card","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single gift card.\n\n**Required scope:** `read_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"gift card found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCard"}}}},"404":{"description":"gift card not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a gift card","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an active gift card's editable attributes. Redeemed or\npartially-redeemed cards cannot be edited.\n\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"gift card updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCard"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a gift card","tags":["Gift Cards"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes an unused gift card. Cards that have been redeemed or\npartially redeemed cannot be deleted and return 422.\n\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"gift card deleted"},"422":{"description":"redeemed gift card cannot be deleted","content":{"application/json":{}}}}}},"/api/v3/admin/imports":{"get":{"summary":"List imports","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns CSV imports queued or completed for the current store.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `pending`, `mapping`, `completed_mapping`, `processing`, `completed`, `failed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `seller_id`, `status`, `type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Import","sortable":["created_at","id","number","seller_id","status","type","updated_at"]},"responses":{"200":{"description":"imports found","content":{"application/json":{}}}}},"post":{"summary":"Create an import","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Queues a CSV import. Upload the file first via `POST /api/v3/admin/files`\nand pass the returned `signed_id` as `attachment_signed_id`. On success the import is in the\n`mapping` state and the response carries the mapping payload: `schema_fields`\n(the canonical columns for the type), `csv_headers`, a `sample_row`, and the\nauto-assigned `mappings`.\n\nAdjust mappings if needed, then call `PATCH /admin/imports/{id}/complete_mapping`\nto start processing. Poll `GET /admin/imports/{id}` while `status` is\n`completed_mapping`/`processing`; terminal statuses are `completed` and `failed`.\n\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"import created in mapping state","content":{"application/json":{}}},"422":{"description":"unknown import type","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportCreateParams"}}},"required":true}}},"/api/v3/admin/imports/template":{"get":{"summary":"Download an import template","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a CSV header row for the given import type, including the custom field columns available for the model.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"type","in":"query","required":true,"description":"Registered import type, e.g. products.","schema":{"type":"string"}}],"responses":{"200":{"description":"CSV template","content":{"application/json":{},"text/csv":{"schema":{"type":"string","format":"binary"}}}}}}},"/api/v3/admin/imports/example":{"get":{"summary":"Download an example import file","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Redirects to a populated example CSV for the given import type — the same sample data `rake spree:load_sample_data` uses, pinned to the installed Spree version. Returns 404 for a type that ships no example file.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"type","in":"query","required":true,"description":"Registered import type, e.g. products.","schema":{"type":"string"}}],"responses":{"302":{"description":"Redirect to the example CSV"}}}},"/api/v3/admin/imports/{id}":{"get":{"summary":"Show an import","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns import status and row counters. The admin dashboard polls this endpoint while `status` is `completed_mapping` or `processing`; `rows_count`, `completed_rows_count` and `failed_rows_count` drive the progress bar. The mapping payload (`csv_headers`, `sample_row`) is only present while `status` is `mapping`.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"import found","content":{"application/json":{}}}}},"delete":{"summary":"Delete an import","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes the import, its rows and the uploaded file. Returns 422 while the import is being processed.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"import deleted"}}}},"/api/v3/admin/imports/{id}/download":{"get":{"summary":"Download the originally uploaded file","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Streams the CSV exactly as it was uploaded — the audit trail for what was imported. JWT/API-key protected; SPA clients fetch it with the Authorization header and trigger the browser download via a Blob URL.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"CSV file","content":{"application/json":{},"text/csv":{"schema":{"type":"string","format":"binary"}}}}}}},"/api/v3/admin/imports/{id}/complete_mapping":{"patch":{"summary":"Complete mapping and start processing","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Applies the submitted column mappings, then starts row processing. Omit `mappings`\nto accept the auto-assigned ones from the create response. Returns 422 when a\nrequired schema field is left unmapped (`details.missing_required_fields`) or a\nfile column is assigned twice.\n\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"mapping completed, processing queued","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportCompleteMappingParams"}}}}}},"/api/v3/admin/imports/{id}/retry_failed_rows":{"patch":{"summary":"Retry failed rows","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Re-processes the rows that failed. The import re-enters `processing`; poll `GET /admin/imports/{id}` until it completes again. Returns 422 when the import is not `completed` or has no failed rows.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"retry queued","content":{"application/json":{}}}}}},"/api/v3/admin/imports/{import_id}/rows":{"get":{"summary":"List import rows","tags":["Imports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Paginated rows of an import — the failure report. Filter with `q[status_eq]=failed` to list only rows that could not be imported; each row carries the raw CSV `data` and its `validation_errors`.\n\n**Required scope:** the write scope of the imported resource — `write_products` for product imports, `write_customers` for customer imports, etc. (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"import_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `row_number` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `status` | One of `pending`, `processing`, `completed`, `failed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `row_number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ImportRow","sortable":["created_at","id","row_number","status","updated_at"]},"responses":{"200":{"description":"rows found","content":{"application/json":{}}}}}},"/api/v3/admin/markets":{"get":{"summary":"List markets","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the markets configured for the current store. Markets are\nstore-scoped and ordered by `position` (an `acts_as_list` column —\nupdate the order via `PATCH /markets/{id}` with `position`).\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed. Supported: `countries`.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `default_locale` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `currency`, `default_locale`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Market","sortable":["created_at","currency","default_locale","id","name","position","updated_at"]},"responses":{"200":{"description":"markets found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Market"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a market","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new market for the current store.\n\n- `country_codes` accepts 2-letter ISO country codes (e.g. `[\"DE\", \"FR\"]`);\n the market must contain at least one country. Unknown codes are\n silently dropped.\n- `supported_locales` accepts an array of locale codes; the\n `default_locale` is always implicitly included.\n- Setting `default: true` automatically demotes the previous default\n market in the store.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"market created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Market"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketCreateParams"}}},"required":true}}},"/api/v3/admin/markets/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a market","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"market found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Market"}}}},"404":{"description":"market not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a market","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an existing market. Pass `country_codes` to replace the\nmarket's country list (full-set update), `supported_locales` to\nreplace the supported locales, or `position` to reorder the market\nwithin the store.\n\nSetting `default: true` automatically demotes the previous default.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"market updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Market"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MarketUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a market","tags":["Markets"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the market (sets `deleted_at`). The default market and\nthe last remaining market in a store cannot be deleted — both return\n422 with a `validation_error`.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"market deleted"},"422":{"description":"cannot delete default or last market","content":{"application/json":{}}}}}},"/api/v3/admin/option_types/{option_type_id}/custom_fields":{"get":{"summary":"List option type custom fields","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the option type's custom field values.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"option_type_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/option_types":{"get":{"summary":"List option types","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of option types.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name and label (partial, case-insensitive)."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., option_values). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,label,position). id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `dropdown`, `color_swatch`, `buttons` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `label` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"OptionType","sortable":["created_at","id","kind","label","name","position","updated_at"]},"responses":{"200":{"description":"option types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/OptionType"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create an option type","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new option type. Supports nested option values.\n\nOption values can be provided inline and will be created or updated by name.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"option type created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionType"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionTypeCreateParams"}}},"required":true}}},"/api/v3/admin/option_types/{id}":{"get":{"summary":"Get an option type","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single option type by ID, including its option values.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Option type ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., option_values). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,label,position). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"option type found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionType"}}}},"404":{"description":"option type not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update an option type","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an option type. Supports updating nested option values.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Option type ID","schema":{"type":"string"}}],"responses":{"200":{"description":"option type updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionType"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OptionTypeUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an option type","tags":["Option Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes an option type.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Option type ID","schema":{"type":"string"}}],"responses":{"204":{"description":"option type deleted"}}}},"/api/v3/admin/claims":{"get":{"summary":"List claims","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every damage or missing-item claim in the store, across all orders.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `open`, `approved`, `resolved`, `denied`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Claim","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"claims listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Claim"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/claims":{"get":{"summary":"List order claims","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The damage or missing-item claims opened on one order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `open`, `approved`, `resolved`, `denied`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Claim","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"claims listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Claim"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Opens a damage or missing-item claim on a completed order. Each item says how it should be made right: money back, a replacement, or both.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"claim opened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/claims/{id}":{"patch":{"summary":"Update a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the reason, memo or metadata of a claim. Its status moves only through the approve, resolve, deny and cancel actions.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Claim prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"claim updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/claims/{id}/resolve":{"patch":{"summary":"Resolve a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Settles an approved claim with money back, a replacement shipment, or both.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Claim prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"claim resolved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}},"422":{"description":"unknown resolution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimResolveParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/claims/{id}/deny":{"patch":{"summary":"Deny a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Turns down an open claim, recording why for the customer.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Claim prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"claim denied","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimDenyParams"}}}}}},"/api/v3/admin/orders/{order_id}/claims/{id}/cancel":{"patch":{"summary":"Cancel a claim","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Withdraws a claim that has not been resolved.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Claim prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"claim canceled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Claim"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClaimCancelParams"}}}}}},"/api/v3/admin/orders/{order_id}/custom_fields":{"get":{"summary":"List order custom fields","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the order's custom field values.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/digital_links":{"get":{"summary":"List digital links","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the download links issued for digital products bought in this store, newest first.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DigitalLink","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"digital links found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DigitalLink"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/exchanges":{"get":{"summary":"List exchanges","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every exchange in the store, across all orders.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `requested`, `approved`, `received`, `fulfilled`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Exchange","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"exchanges listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Exchange"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/exchanges":{"get":{"summary":"List order exchanges","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The exchanges opened on one order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `requested`, `approved`, `received`, `fulfilled`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Exchange","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"exchanges listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Exchange"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Opens an exchange on a completed order: items coming back, and the variant that goes out in place of each.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"exchange opened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/exchanges/{id}":{"patch":{"summary":"Update an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the warehouse, reason, memo or metadata of an exchange. Its status moves only through the approve, receive, fulfill and cancel actions.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Exchange prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"exchange updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/exchanges/{id}/receive":{"patch":{"summary":"Receive an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records the goods that came back on an approved exchange. Omit `items` to receive everything as requested and resellable.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Exchange prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"exchange received","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeReceiveParams"}}}}}},"/api/v3/admin/orders/{order_id}/exchanges/{id}/fulfill":{"patch":{"summary":"Fulfill an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Ships the replacements for a received exchange and settles any price difference.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Exchange prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"exchange fulfilled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeFulfillParams"}}}}}},"/api/v3/admin/orders/{order_id}/exchanges/{id}/cancel":{"patch":{"summary":"Cancel an exchange","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Withdraws an exchange whose goods have not been received.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Exchange prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"exchange canceled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Exchange"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeCancelParams"}}}}}},"/api/v3/admin/orders/{order_id}/tax_lines":{"get":{"summary":"List tax lines","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Typed tax rows on the order. Read-only — written exclusively by the tax provider.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[country_code_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `included` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `provider_id` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `taxability_reason` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `country_code`, `created_at`, `id`, `included`, `provider_id`, `state_code`, `taxability_reason`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxLine","sortable":["country_code","created_at","id","included","provider_id","state_code","taxability_reason","updated_at"]},"responses":{"200":{"description":"tax lines found","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{order_id}/discounts":{"get":{"summary":"List discounts","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Typed discount rows (promotion-sourced and manual) on the order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Discount","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"discounts found","content":{"application/json":{}}}}},"post":{"summary":"Create manual discount","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a manual discount. With line_item_id a single row is created; without it the amount is distributed across line items (largest remainder). This is the sanctioned post-placement discount path and works on completed orders.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"discount created","content":{"application/json":{}}},"422":{"description":"invalid discount","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscountCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/discounts/{id}":{"patch":{"summary":"Update manual discount","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the label or amount of a manual discount and re-sums the order totals. Promotion-sourced rows are owned by recalculation and respond 422.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Discount prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"discount updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscountUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fees":{"get":{"summary":"List fees","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the order's fees, such as surcharges, handling and gift wrap, on the whole order or on one item or delivery.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Fee","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"fees found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Fee"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create fee","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a fee (surcharge, handling, gift wrap, COD, payment fee). Order-level when no target is given. Works on completed orders.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"fee created","content":{"application/json":{}}},"422":{"description":"invalid fee","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeeCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fees/{id}":{"patch":{"summary":"Update fee","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the label, amount or kind of a fee and re-sums the order totals. Works on completed orders.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Fee prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"fee updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Fee"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeeUpdateParams"}}},"required":true}}},"/api/v3/admin/order_groups":{"get":{"summary":"List order groups","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns checkouts split into one order per seller, grouping the orders placed together.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[customer_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customer_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `customer_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `orders_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `orders_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `orders_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `orders_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `orders_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `orders_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `orders_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `orders_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `orders_tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `currency`, `email`, `id`, `number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"OrderGroup","sortable":["created_at","currency","email","id","number","updated_at"]},"responses":{"200":{"description":"order groups found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/OrderGroup"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/discount_codes":{"post":{"summary":"Apply a discount code","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Applies a discount code to a draft order and returns the order. A real code the order does not yet qualify for is kept and applies once it does. Completed orders refuse codes; change their discounts through manual discounts instead.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"discount code applied","content":{"application/json":{}}},"422":{"description":"unknown discount code","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiscountCodeApplyParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/gift_cards":{"post":{"summary":"Apply a gift card to an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Applies a gift card by code to the order. Returns the gift card.\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"gift card applied","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GiftCardApplyParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/gift_cards/{id}":{"delete":{"summary":"Remove a gift card from an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes the gift card from the order.\n\n**Required scope:** `write_gift_cards` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Gift card ID","schema":{"type":"string"}}],"responses":{"204":{"description":"gift card removed"}}}},"/api/v3/admin/orders/{order_id}/items":{"get":{"summary":"List order items","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all line items for an order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., variant, variant.product). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., quantity,price,total). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[additional_tax_total_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `additional_tax_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `adjustment_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cost_price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `discount_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `included_tax_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `non_taxable_adjustment_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `pre_tax_amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `tax_category_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `taxable_adjustment_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `variant_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variant_product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"LineItem","sortable":["additional_tax_total","adjustment_total","cost_price","created_at","discount_total","id","included_tax_total","non_taxable_adjustment_total","order_id","pre_tax_amount","price","quantity","tax_category_id","taxable_adjustment_total","updated_at","variant_id"]},"responses":{"200":{"description":"items found","content":{"application/json":{}}}}},"post":{"summary":"Add an item","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a new line item to the order.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"item added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LineItemCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/items/{id}":{"get":{"summary":"Show an item","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns details of a specific line item.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Item ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., variant, variant.product). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., quantity,price,total). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"item found","content":{"application/json":{}}}}},"patch":{"summary":"Update an item","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an order item quantity or metadata.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Item ID","schema":{"type":"string"}}],"responses":{"200":{"description":"item updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LineItemUpdateParams"}}},"required":true}},"delete":{"summary":"Remove an item","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes an item from the order.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Item ID","schema":{"type":"string"}}],"responses":{"204":{"description":"line item removed"}}}},"/api/v3/admin/orders/{order_id}/store_credits":{"post":{"summary":"Apply customer's store credit to an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Applies the order customer's available store credit. When `amount` is omitted, applies up to the order outstanding balance.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"store credit applied","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoreCreditApplyParams"}}},"required":true}},"delete":{"summary":"Remove store credit from an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes any applied store credit from the order.\n\n**Required scope:** `write_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"204":{"description":"store credit removed"}}}},"/api/v3/admin/orders":{"get":{"summary":"List orders","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of orders for the current store.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches order number or purchase order number (partial), the billing first or last name, or the exact email."},{"name":"q[complete]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `complete`."},{"name":"q[incomplete]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `incomplete`."},{"name":"q[partially_refunded]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `partially_refunded`."},{"name":"q[refunded]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `refunded`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"sort","in":"query","required":false,"description":"Sort field (e.g., created_at, -created_at, completed_at)","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., items, fulfillments, payments, customer, discounts, billing_address, shipping_address). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., number,total,status,completed_at). id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `channel_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `completed_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `considered_risky` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `coupon_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `customer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `delivery_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `fulfillment_status` | One of `backorder`, `canceled`, `partial`, `unfulfilled`, `fulfilled`, `delivered`, `pending`, `ready`, `shipped` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `item_total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `order_group_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `payment_status` | One of `none`, `authorized`, `partially_paid`, `paid`, `partially_refunded`, `refunded`, `overcharged`, `voided`, `balance_due`, `credit_owed`, `failed`, `void` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `po_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `draft`, `placed`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `total_quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[bill_address_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customer_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `line_items_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `line_items_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_group_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `promotions_coupon_codes_` | `code`, `created_at`, `id`, `promotion_id`, `state`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Order","sortable":["channel_id","completed_at","considered_risky","coupon_code","created_at","currency","customer_id","delivery_total","email","fulfillment_status","id","item_total","number","order_group_id","payment_state","payment_status","po_number","seller_id","shipment_state","status","total","total_quantity","updated_at"]},"responses":{"200":{"description":"orders found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a draft order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new draft order in one shot. Customer, items, addresses, currency,\nmarket, channel, locale, notes, metadata, and a coupon code can all be\nprovided inline.\n\nSetting `preferred_stock_location_id` pins the order's preferred fulfillment\nlocation — Order Routing's built-in `PreferredLocation` rule consumes it\nwhen picking which stock location ships each shipment.\n\nInvalid coupon codes are non-fatal — the order is created and the failure\nis reported on the service result (not in the API response body for now).\n\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"order created with preferred_stock_location_id","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{id}":{"get":{"summary":"Show an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns full order details including admin-only fields.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID (e.g., or_xxx)","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., items, fulfillments, payments, customer, discounts, billing_address, shipping_address). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., number,total,status,completed_at). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"order found","content":{"application/json":{}}},"404":{"description":"order not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an order. Supports updating email, addresses, special instructions, and line items.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"order updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a draft order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a draft order. Completed orders cannot be deleted.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"204":{"description":"order deleted"}}}},"/api/v3/admin/orders/{id}/complete":{"patch":{"summary":"Complete an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Completes an order in the `confirm` state, marking it as placed.\n\nSet `notify_customer: true` to send the order confirmation email.\n\nOn a marketplace, an order holding several sellers' goods becomes one\norder per seller, and the response is the order group they belong to\nwith those orders nested inside it.\n\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"order completed","content":{"application/json":{}}},"422":{"description":"order cannot be completed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCompleteParams"}}},"required":true}}},"/api/v3/admin/orders/{id}/cancel":{"patch":{"summary":"Cancel an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Cancels a completed order.\n\n`cancel_reason_id` records why, from the store's own cancellation-reason\nvocabulary (`/admin/order_cancellation_reasons`), and `cancel_note` is a\nstaff-facing note; both are shown on the order afterwards.\n\nStock is always released — the goods are not going out either way — and\nevery payment is settled at the gateway, which releases an\nauthorization it never drew on and refunds a charge it cannot release.\n\n`refund_payments` and `refund_amount` govern the shared payment of a\nsplit checkout, where one payment covers several orders: they decide\nwhether this order's share comes back, and how much of it. A\n`refund_amount` on an ordinary order is refused with a 422.\n\nSet `notify_customer: true` to send the order cancellation email.\n\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"order canceled","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderCancelParams"}}},"required":true}}},"/api/v3/admin/orders/{id}/approve":{"patch":{"summary":"Approve an order","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Approves an order (e.g., for fraud review).\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"order approved","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{id}/resend_confirmation":{"post":{"summary":"Resend confirmation email","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Publishes the order.completed event to trigger confirmation email delivery.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"200":{"description":"confirmation resent","content":{"application/json":{}}}}}},"/api/v3/admin/returns":{"get":{"summary":"List returns","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every return in the store, across all orders.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `requested`, `approved`, `received`, `refunded`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Return","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"returns listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Return"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/returns":{"get":{"summary":"List order returns","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The returns opened on one order.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `requested`, `approved`, `received`, `refunded`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `reason_` | `active`, `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `number`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Return","sortable":["created_at","id","number","status","updated_at"]},"responses":{"200":{"description":"returns listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Return"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Opens a return on a completed order for fulfilled units the customer is sending back.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}}],"responses":{"201":{"description":"return opened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}},"422":{"description":"more returned than was fulfilled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/returns/{id}":{"patch":{"summary":"Update a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits the warehouse, reason, memo or metadata of a return. Its status moves only through the approve, receive, refund and cancel actions.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"return updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/returns/{id}/receive":{"patch":{"summary":"Receive a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records what arrived on an approved return. Omit `items` to receive everything as requested and resellable; send rows for a partial or damaged receipt.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"return received","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnReceiveParams"}}}}}},"/api/v3/admin/orders/{order_id}/returns/{id}/refund":{"patch":{"summary":"Refund a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Pays the customer back for a received return, to store credit or through the original payment.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"return refunded","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnRefundParams"}}}}}},"/api/v3/admin/orders/{order_id}/returns/{id}/cancel":{"patch":{"summary":"Cancel a return","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Withdraws a return whose goods have not been received.\n\n**Required scope:** `write_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}}],"responses":{"200":{"description":"return canceled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnCancelParams"}}}}}},"/api/v3/admin/orders/{order_id}/returns/{return_id}/labels":{"get":{"summary":"List return labels","tags":["Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The shipping labels issued for sending one return back to the store.\n\n**Required scope:** `read_orders` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order prefixed ID","schema":{"type":"string"}},{"name":"return_id","in":"path","required":true,"description":"Return prefixed ID","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[carrier_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carrier` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `source` | One of `purchased`, `uploaded` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `purchased`, `refund_requested`, `refunded` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `tracking_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `carrier`, `created_at`, `id`, `source`, `status`, `tracking_number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ShippingLabel","sortable":["carrier","created_at","id","source","status","tracking_number","updated_at"]},"responses":{"200":{"description":"labels listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ShippingLabel"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/payment_methods":{"get":{"summary":"List payment methods","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's configured payment methods. Use `source_required: true` to know which methods need a saved source.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,type,active). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `storefront_visible` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `position`, `storefront_visible`, `type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PaymentMethod","sortable":["active","created_at","id","name","position","storefront_visible","type","updated_at"]},"responses":{"200":{"description":"payment methods found","content":{"application/json":{}}}}},"post":{"summary":"Create a payment method","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a payment method to the store. `type` is a shorthand from the\npayment method types endpoint, and `preferences` takes the values its\npreference schema declares (gateway credentials among them).\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"payment method created","content":{"application/json":{}}},"422":{"description":"unknown payment method type","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentMethodCreateParams"}}},"required":true}}},"/api/v3/admin/payment_methods/types":{"get":{"summary":"List available payment provider types","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every registered payment provider with the JSON Schema of its `preferences`. `installed` marks a provider the store already has, which a \"Provider\" picker leaves out.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"provider types found","content":{"application/json":{}}}}}},"/api/v3/admin/payment_methods/{id}":{"get":{"summary":"Show a payment method","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a payment method by ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand. Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,type,active). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"payment method found","content":{"application/json":{}}}}},"patch":{"summary":"Update a payment method","tags":["Payment Methods"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a payment method. Its `type` is fixed once created.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"payment method updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentMethodUpdateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/payments":{"get":{"summary":"List payments","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all payments for an order.\n\n**Required scope:** `read_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment_method, source). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., amount,status,number,response_code). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[avs_response_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `avs_response` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cvv_response_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `cvv_response_message` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `response_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state` | One of `checkout`, `processing`, `pending`, `completed`, `failed`, `void`, `invalid` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `checkout`, `processing`, `pending`, `completed`, `failed`, `void`, `invalid` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[order_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `payment_method_` | `active`, `created_at`, `id`, `name`, `position`, `storefront_visible`, `type`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `avs_response`, `created_at`, `cvv_response_code`, `cvv_response_message`, `id`, `response_code`, `state`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Payment","sortable":["amount","avs_response","created_at","cvv_response_code","cvv_response_message","id","response_code","state","status","updated_at"]},"responses":{"200":{"description":"payments found","content":{"application/json":{}}}}},"post":{"summary":"Create a payment","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new payment for the order.\n\n**Required scope:** `write_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"payment created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/payments/{id}":{"get":{"summary":"Show a payment","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns details of a specific payment.\n\n**Required scope:** `read_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Payment ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment_method, source). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., amount,status,number,response_code). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"payment found","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{order_id}/payments/{id}/capture":{"patch":{"summary":"Capture a payment","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Captures a pending payment, in full or for part of the authorized amount.\n\n**Required scope:** `write_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Payment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"payment captured","content":{"application/json":{}}},"422":{"description":"capture failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentCaptureParams"}}}}}},"/api/v3/admin/orders/{order_id}/payments/{id}/void":{"patch":{"summary":"Void a payment","tags":["Payments"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Voids a payment.\n\n**Required scope:** `write_payments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Payment ID","schema":{"type":"string"}}],"responses":{"200":{"description":"payment voided","content":{"application/json":{}}}}}},"/api/v3/admin/price_lists":{"get":{"summary":"List price lists","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the price lists configured for the current store.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed. Supported: `price_rules`.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `catalog_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `ends_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `match_policy` | One of `all`, `any` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `starts_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `status` | One of `draft`, `active`, `inactive`, `scheduled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `catalog_id`, `created_at`, `ends_at`, `id`, `match_policy`, `name`, `position`, `starts_at`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PriceList","sortable":["catalog_id","created_at","ends_at","id","match_policy","name","position","starts_at","status","updated_at"]},"responses":{"200":{"description":"price lists found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PriceList"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new draft price list.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"price list created (server-to-server — rules + prices)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceListCreateParams"}}},"required":true}}},"/api/v3/admin/price_lists/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"price list found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}},"404":{"description":"price list not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a price list. The optional `rules:` array reconciles nested\nSTI-typed price rules in a single round-trip — existing rules update\nby `id`, new rules build, missing rules destroy. Mirrors the\npromotion editor's \"save the whole thing on Save\" pattern.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price list updated with nested rules","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceListUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the price list. Associated prices are removed asynchronously.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"price list deleted"}}}},"/api/v3/admin/price_lists/{id}/activate":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Activate a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Transitions a draft / inactive list to `active`. If `starts_at` is\nin the future the list is marked `scheduled` instead, matching the\nlegacy admin behaviour.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price list activated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}}}}},"/api/v3/admin/price_lists/{id}/deactivate":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Deactivate a price list","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price list deactivated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceList"}}}}}}},"/api/v3/admin/prices":{"get":{"summary":"List prices","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Generic prices endpoint covering both base prices and price-list\noverrides. Filter with Ransack: `q[price_list_id_eq]=…`,\n`q[currency_eq]=USD`, `q[price_list_id_null]=true` (base prices only).\n\nThe admin spreadsheet uses this with server-side pagination so it\nscales past the metadata-PATCH path on `/price_lists/:id`.\n\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches the variant's SKU, option value or product name, as variant search does."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Comma-separated sort keys. Supports e.g. `variant_product_name,variant_id`.","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed. Supported: `variant`.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `compare_at_amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `min_quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `price_list_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `variant_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[price_list_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `price_list_` | `catalog_id`, `created_at`, `ends_at`, `id`, `match_policy`, `name`, `position`, `starts_at`, `status`, `updated_at` |\n| `variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variant_product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Price","sortable":["amount","compare_at_amount","created_at","currency","id","min_quantity","price_list_id","updated_at","variant_id"]},"responses":{"200":{"description":"prices found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Price"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a price","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a single price. Omit `price_list_id` to create a base price.\nFor more than a handful of rows, prefer `POST /admin/prices/bulk_upsert`.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"price created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Price"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceCreateParams"}}},"required":true}}},"/api/v3/admin/prices/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a price","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Price"}}}},"404":{"description":"price not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a price","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"price updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Price"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a price","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the price (acts_as_paranoid).\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"price deleted"}}}},"/api/v3/admin/prices/bulk_upsert":{"post":{"summary":"Bulk-upsert prices","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Upserts a batch of prices in a single SQL round trip.\n\nEach row either:\n* targets an existing price by `id`, OR\n* matches on the unique key `(variant_id, currency, price_list_id)` —\n updating the existing row if one exists, creating one otherwise.\n\nModel callbacks (e.g. PriceHistory) are bypassed; this is a\nbulk-write fast path for the admin spreadsheet. The response\ncarries `price_count` — the number of rows touched.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"prices upserted","content":{"application/json":{"schema":{"type":"object","properties":{"price_count":{"type":"integer"}}}}}},"422":{"description":"missing prices key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceBulkUpsertParams"}}},"required":true}}},"/api/v3/admin/prices/bulk_destroy":{"delete":{"summary":"Bulk-delete prices","tags":["Pricing"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes each price in `ids`. Returns the count actually destroyed.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"prices deleted","content":{"application/json":{"schema":{"type":"object","properties":{"price_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceBulkDestroyParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/custom_fields":{"get":{"summary":"List product custom fields","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the product's custom field values.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{}}}}},"post":{"summary":"Create a product custom field","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sets a custom field value on the product. Requires an existing CustomFieldDefinition; pass its prefixed `cfdef_…` id.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"custom field created","content":{"application/json":{}}},"422":{"description":"duplicate definition for the same product","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomFieldCreateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/custom_fields/{id}":{"get":{"summary":"Show a product custom field","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"custom field found","content":{"application/json":{}}}}},"patch":{"summary":"Update a product custom field","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates the custom field's `value`. The linked definition cannot be changed — delete and recreate to switch.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"custom field updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomFieldUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a product custom field","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"custom field deleted"}}}},"/api/v3/admin/products/{product_id}/digital_assets":{"parameters":[{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"get":{"summary":"List product digital assets","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the downloadable files attached to the product's variants, oldest first.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DigitalAsset","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"digital assets found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DigitalAsset"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a product digital asset","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Attaches a downloadable file to one of the product's variants (the\ndefault variant when `variant_id` is omitted). Upload the file first\nthrough `POST /api/v3/admin/files` with `visibility: 'private'`, then\nsend its `signed_id` here. A provider-backed asset sends\n`provider_type` and `provider_settings` instead of a file.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"digital asset created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigitalAsset"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigitalAssetCreateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/digital_assets/{id}":{"parameters":[{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Digital asset ID","schema":{"type":"string"}}],"patch":{"summary":"Update a product digital asset","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes an asset's download limits, or replaces its file with a new\nprivate `signed_id`. Links customers already received keep working and\nserve the new file.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"digital asset updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigitalAsset"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigitalAssetUpdateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/translations":{"get":{"summary":"List product translations","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the full translation matrix for the product: the source value and content type per translatable field, plus the translated value for every supported locale.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"translations found","content":{"application/json":{}}}}}},"/api/v3/admin/products":{"get":{"summary":"List products","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of products for the current store.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"sort","in":"query","required":false,"description":"Sort field (e.g., name, -name, price, -price, best_selling)","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., variants, media, option_types, categories). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,slug,price,status). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\nAlso filters and sorts on the store's searchable custom fields, as `q[cf_<namespace>_<key>_<predicate>]` and `sort=cf_<namespace>_<key>`.\n\n**Sort by:** `available_on`, `best_selling`, `created_at`, `description`, `discontinue_on`, `id`, `manual`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","best_selling","created_at","description","discontinue_on","id","manual","name","price","seller_id","slug","status","updated_at"],"custom_fields":true},"responses":{"200":{"description":"products found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new product. Supports nested variants with prices and option types.\n\nOption types and values are auto-created if they don't exist.\nPrices are upserted by currency. Stock items are upserted by stock location.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"product created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Product"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductCreateParams"}}},"required":true}}},"/api/v3/admin/products/{id}":{"get":{"summary":"Get a product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single product by ID.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID (e.g., prod_xxx)","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., variants, media, option_types, categories). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., name,slug,price,status). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"product found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Product"}}}},"404":{"description":"product not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a product. Only provided fields are updated.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"200":{"description":"product updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Product"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes a product.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"204":{"description":"product deleted"},"422":{"description":"deletion refused by a store rule","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/products/bulk_status_update":{"post":{"summary":"Bulk-update product status","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sets `status` on each product in `ids`. Reindexes the affected products\nfor search. Cross-store IDs are silently dropped. Returns counts.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"cross-store products silently dropped","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"status":{"type":"string"}}}}}},"422":{"description":"invalid status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkStatusParams"}}},"required":true}}},"/api/v3/admin/products/bulk_add_to_categories":{"post":{"summary":"Bulk-add products to categories","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Attaches each product in `ids` to every category (category) in `category_ids`.\nCategories from sibling stores are silently ignored.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products added to categories","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"category_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkCategoriesParams"}}},"required":true}}},"/api/v3/admin/products/bulk_remove_from_categories":{"post":{"summary":"Bulk-remove products from categories","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Detaches each product in `ids` from every category in `category_ids`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products removed from categories","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkCategoriesParams"}}},"required":true}}},"/api/v3/admin/products/bulk_add_to_collections":{"post":{"summary":"Bulk-add products to collections","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Attaches each product in `ids` to every manual collection in `collection_ids`.\nAutomatic (rule-based) and sibling-store collections are silently ignored.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products added to collections","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"collection_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkCollectionsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_remove_from_collections":{"post":{"summary":"Bulk-remove products from collections","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Detaches each product in `ids` from every collection in `collection_ids`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products removed from collections","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkCollectionsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_add_to_channels":{"post":{"summary":"Bulk-add products to channels","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Publishes each product in `ids` on every channel in `channel_ids`. Idempotent —\nre-publishing on an existing channel is a no-op. Channels from sibling stores\nare silently ignored.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products published on channels","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"channel_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkChannelsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_remove_from_channels":{"post":{"summary":"Bulk-remove products from channels","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Unpublishes each product in `ids` from every channel in `channel_ids`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products unpublished from channels","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"channel_count":{"type":"integer"},"removed":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkChannelsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_add_tags":{"post":{"summary":"Bulk-add tags to products","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds each tag name in `tags` to every product in `ids`. Tags are upserted by name.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"tags added","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"},"tag_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTagsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_remove_tags":{"post":{"summary":"Bulk-remove tags from products","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes each tag in `tags` from every product in `ids`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"tags removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTagsParams"}}},"required":true}}},"/api/v3/admin/products/bulk_destroy":{"delete":{"summary":"Bulk-delete products","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes each product in `ids`. Returns the count actually destroyed.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products deleted","content":{"application/json":{"schema":{"type":"object","properties":{"product_count":{"type":"integer"}}}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductBulkDestroyParams"}}},"required":true}}},"/api/v3/admin/products/{id}/reject":{"parameters":[{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"patch":{"summary":"Reject a submitted product","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Turns down a product a seller submitted for review. The `reason` is\nsent back to the seller, who can fix the product and submit it again.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"product rejected","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Product"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductRejectParams"}}},"required":true}}},"/api/v3/admin/translations":{"get":{"summary":"Translation coverage for a resource type","tags":["Products"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Reports how much of each record is translated into each of the store's non-default locales, plus per-locale totals. A record counts as covered for a locale only when every one of its translatable fields is filled in.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"resource_type","in":"query","required":true,"description":"A translatable resource type, e.g. `product`, `category`, `option_type`.","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"search","in":"query","required":false,"description":"Free-text term, applied through whichever predicate the resource type whitelists (reported back as `search_field`).","schema":{"type":"string"}}],"responses":{"200":{"description":"coverage found","content":{"application/json":{}}},"404":{"description":"resource type is not translatable","content":{"application/json":{}}}}}},"/api/v3/admin/policies":{"get":{"summary":"List policies","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's policy documents — terms of service, privacy\npolicy, returns policy, shipping policy, and any others the merchant\nhas written. Every store is created with the four standard policies,\nnamed but empty.\n\nA marketplace seller's own policies are managed by the seller and are\nnot listed here.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `owner_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `owner_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `owner_id`, `owner_type`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Policy","sortable":["created_at","id","name","owner_id","owner_type","updated_at"]},"responses":{"200":{"description":"policies listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Policy"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a policy","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a policy. `body` accepts HTML and is sanitized before it is\nstored; the stored markup is returned as `body_html`, and `body` reads\nback as plain text.\n\nThe slug is derived from the name when one is not given, and is what\nthe storefront addresses the policy by.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"policy created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Policy"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PolicyCreateParams"}}},"required":true}}},"/api/v3/admin/policies/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Policy prefixed ID or slug","schema":{"type":"string"}}],"get":{"summary":"Get a policy","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single policy, addressed by prefixed ID or by slug.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"policy found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Policy"}}}},"404":{"description":"policy not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a policy","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a policy. `body` accepts HTML and is sanitized before it is stored.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"policy updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Policy"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PolicyUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a policy","tags":["Policies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a policy. The four policies a store is created with can be\ndeleted like any other — they are conventions, not fixtures.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"policy deleted"}}}},"/api/v3/admin/claim_reasons":{"get":{"summary":"List claim reasons","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Why a customer raised a claim — what the merchant got wrong, rather than a change of mind.\n\nThe vocabulary is the merchant's own — seeded with a starting set and\nedited from the dashboard. Inactive rows stay for the records that\nalready reference them, but are not offered on new ones.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ClaimReason","sortable":["active","created_at","id","name","updated_at"]},"responses":{"200":{"description":"claim reasons found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a claim reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a claim reason to this store. Names are unique per store, ignoring case.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"claim reason created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonCreateParams"}}},"required":true}}},"/api/v3/admin/claim_reasons/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Claim reason ID","schema":{"type":"string"}}],"get":{"summary":"Get a claim reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single claim reason by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"claim reason found","content":{"application/json":{}}},"404":{"description":"claim reason not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a claim reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a claim reason or retires it. Deactivating keeps it on the records\nthat already carry it while removing it from the pickers.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"claim reason updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a claim reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a claim reason the store no longer uses. A reason already recorded\non a document is refused — deactivate it instead, so the history it\nexplains stays readable.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"claim reason deleted"}}}},"/api/v3/admin/order_cancellation_reasons":{"get":{"summary":"List order cancellation reasons","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Why an order was called off before it shipped. Staff pick one when canceling.\n\nThe vocabulary is the merchant's own — seeded with a starting set and\nedited from the dashboard. Inactive rows stay for the records that\nalready reference them, but are not offered on new ones.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"OrderCancellationReason","sortable":["active","created_at","id","name","updated_at"]},"responses":{"200":{"description":"order cancellation reasons found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a order cancellation reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a order cancellation reason to this store. Names are unique per store, ignoring case.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"order cancellation reason created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonCreateParams"}}},"required":true}}},"/api/v3/admin/order_cancellation_reasons/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Order cancellation reason ID","schema":{"type":"string"}}],"get":{"summary":"Get a order cancellation reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single order cancellation reason by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"order cancellation reason found","content":{"application/json":{}}},"404":{"description":"order cancellation reason not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a order cancellation reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a order cancellation reason or retires it. Deactivating keeps it on the records\nthat already carry it while removing it from the pickers.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"order cancellation reason updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a order cancellation reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a order cancellation reason the store no longer uses. A reason already recorded\non a document is refused — deactivate it instead, so the history it\nexplains stays readable.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"order cancellation reason deleted"}}}},"/api/v3/admin/refund_reasons":{"get":{"summary":"List refund reasons","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Why money went back. Some rows are seeded and looked up by name, so they refuse renaming and deletion.\n\nThe vocabulary is the merchant's own — seeded with a starting set and\nedited from the dashboard. Inactive rows stay for the records that\nalready reference them, but are not offered on new ones.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"RefundReason","sortable":["active","created_at","id","name","updated_at"]},"responses":{"200":{"description":"refund reasons found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a refund reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a refund reason to this store. Names are unique per store, ignoring case.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"refund reason created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonCreateParams"}}},"required":true}}},"/api/v3/admin/refund_reasons/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Refund reason ID","schema":{"type":"string"}}],"get":{"summary":"Get a refund reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single refund reason by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"refund reason found","content":{"application/json":{}}},"404":{"description":"refund reason not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a refund reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a refund reason or retires it. Deactivating keeps it on the records\nthat already carry it while removing it from the pickers.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"refund reason updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a refund reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a refund reason the store no longer uses. A reason already recorded\non a document is refused — deactivate it instead, so the history it\nexplains stays readable.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"refund reason deleted"}}}},"/api/v3/admin/return_reasons":{"get":{"summary":"List return reasons","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Why a customer is sending items back. Shared by returns and exchanges.\n\nThe vocabulary is the merchant's own — seeded with a starting set and\nedited from the dashboard. Inactive rows stay for the records that\nalready reference them, but are not offered on new ones.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ReturnReason","sortable":["active","created_at","id","name","updated_at"]},"responses":{"200":{"description":"return reasons found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a return reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a return reason to this store. Names are unique per store, ignoring case.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"return reason created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonCreateParams"}}},"required":true}}},"/api/v3/admin/return_reasons/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Return reason ID","schema":{"type":"string"}}],"get":{"summary":"Get a return reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single return reason by prefixed ID.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"return reason found","content":{"application/json":{}}},"404":{"description":"return reason not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a return reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Renames a return reason or retires it. Deactivating keeps it on the records\nthat already carry it while removing it from the pickers.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"return reason updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReasonUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a return reason","tags":["Reasons"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a return reason the store no longer uses. A reason already recorded\non a document is refused — deactivate it instead, so the history it\nexplains stays readable.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"return reason deleted"}}}},"/api/v3/admin/promotions/{promotion_id}/coupon_codes":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List coupon codes for a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the auto-generated coupon codes for a multi-code promotion. Single-code promotions store the code on the promotion itself; this endpoint returns an empty list for them.\n\n**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[code_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `promotion_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `state` | One of `unused`, `used` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[promotion_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `promotion_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `code`, `created_at`, `id`, `promotion_id`, `state`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CouponCode","sortable":["code","created_at","id","promotion_id","state","updated_at"]},"responses":{"200":{"description":"coupon codes found","content":{"application/json":{}}}}}},"/api/v3/admin/promotions/{promotion_id}/promotion_actions":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List actions for a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PromotionAction","sortable":["created_at","id","position","updated_at"]},"responses":{"200":{"description":"actions found","content":{"application/json":{}}}}},"post":{"summary":"Create an action on a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a new action to a promotion. The `type` is the wire shorthand from `GET /promotion_actions/types` (e.g. `free_shipping`, `create_item_adjustments`).\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"action created","content":{"application/json":{}}},"422":{"description":"unknown action type","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionActionCreateParams"}}},"required":true}}},"/api/v3/admin/promotions/{promotion_id}/promotion_actions/{id}":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update an action on a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes an action's settings. For adjustment actions, `calculator`\nsets the calculator and its preferences; sending a different\ncalculator `type` swaps it. The action's own `type` is fixed once\ncreated.\n\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"action updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionActionUpdateParams"}}},"required":true}},"delete":{"summary":"Delete an action from a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"action deleted"}}}},"/api/v3/admin/promotions/{promotion_id}/promotion_rules":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List rules for a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PromotionRule","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"rules found","content":{"application/json":{}}}}},"post":{"summary":"Create a rule on a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a new rule to a promotion. The `type` is the wire shorthand from `GET /promotion_rules/types` (e.g. `currency`, `item_total`, `product`).\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"rule created with preferences","content":{"application/json":{}}},"422":{"description":"unknown rule type","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionRuleCreateParams"}}},"required":true}}},"/api/v3/admin/promotions/{promotion_id}/promotion_rules/{id}":{"parameters":[{"name":"promotion_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a rule's preferences","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rule updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionRuleUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a rule from a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"rule deleted"}}}},"/api/v3/admin/promotions":{"get":{"summary":"List promotions","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's promotions, including manual coupon and automatic promotions.\n\n**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name and code (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `expires_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `coupon_code`, `automatic` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `path` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `promotion_category_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `starts_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[coupon_codes_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `coupon_codes_` | `code`, `created_at`, `id`, `promotion_id`, `state`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Promotion","sortable":["code","created_at","expires_at","id","kind","name","path","promotion_category_id","starts_at","updated_at"]},"responses":{"200":{"description":"promotions found","content":{"application/json":{}}}}},"post":{"summary":"Create a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new promotion. `code` is required for single-code coupon promotions;\npass `multi_codes: true` with `number_of_codes` to auto-generate a batch.\n\nRules and actions can be created in the same request by passing arrays of\n`{ type, preferences, ... }` rows. The server reconciles to the desired set:\nnew rows are built, existing rows (by `id`) are updated, omitted rows are removed.\n\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"promotion created with rules and actions","content":{"application/json":{}}},"422":{"description":"invalid params","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionCreateParams"}}},"required":true}}},"/api/v3/admin/promotions/{id}":{"get":{"summary":"Show a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"promotion found","content":{"application/json":{}}}}},"patch":{"summary":"Update a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a promotion. The `rules` and `actions` arrays are treated as\na *desired set* — rows with `id` update in place, rows without `id` are\nbuilt fresh, and any existing row not present in the array is destroyed.\nPass `rules: []` or `actions: []` to clear them.\n\n\n**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rules and actions cleared with empty arrays","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromotionUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a promotion","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"promotion deleted"}}}},"/api/v3/admin/promotion_actions/types":{"get":{"summary":"List available promotion action types","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the registered Spree::PromotionAction subclasses with their preference schemas. Used by admin UIs to populate the \"Add action\" picker and render generic preference forms.\n\n**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"action types found","content":{"application/json":{}}}}}},"/api/v3/admin/promotion_rules/types":{"get":{"summary":"List available promotion rule types","tags":["Promotions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the registered Spree::PromotionRule subclasses with their preference schemas.\n\n**Required scope:** `read_promotions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rule types found","content":{"application/json":{}}}}}},"/api/v3/admin/orders/{order_id}/refunds":{"get":{"summary":"List refunds","tags":["Refunds"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all refunds for an order.\n\n**Required scope:** `read_refunds` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., payment, refund_reason). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., amount,reason,transaction_id). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Refund","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"refunds found","content":{"application/json":{}}}}},"post":{"summary":"Create a refund","tags":["Refunds"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a refund for a payment on the order. The refund is automatically processed via the payment gateway.\n\n**Required scope:** `write_refunds` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}}],"responses":{"201":{"description":"refund created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefundCreateParams"}}},"required":true}}},"/api/v3/admin/locales":{"get":{"summary":"List supported locales","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the locales a merchant can translate content into for the current store, with the default and right-to-left flags.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"locales found","content":{"application/json":{}}}}}},"/api/v3/admin/store":{"get":{"summary":"Get the current store","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the current store configuration. The store is resolved from the request context (host or admin selection); there is no `id` parameter.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"current store","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Store"}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update the current store","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates the current store configuration.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"store updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Store"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoreUpdateParams"}}},"required":true}}},"/api/v3/admin/tags":{"get":{"summary":"List tags","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns tag names for a given taggable type. Used for autocomplete in tag inputs on products, orders, and customers.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"taggable_type","in":"query","required":true,"description":"Shorthand of the tagged resource: `product`, `order` or `customer`","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"description":"Optional case-insensitive substring filter","schema":{"type":"string"}}],"responses":{"200":{"description":"tags found","content":{"application/json":{}}},"422":{"description":"invalid taggable type","content":{"application/json":{}}}}}},"/api/v3/admin/tax_categories":{"get":{"summary":"List tax categories","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the tax categories products and delivery methods can be assigned to, which tax rates then apply to.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `is_default` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `tax_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxCategory","sortable":["created_at","id","is_default","name","tax_code","updated_at"]},"responses":{"200":{"description":"tax categories found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TaxCategory"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a tax category","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a tax category. `tax_code` is the code a tax provider uses to classify the goods in it.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"tax category created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxCategory"}}}},"422":{"description":"validation failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxCategoryCreateParams"}}},"required":true}}},"/api/v3/admin/tax_categories/{id}":{"parameters":[{"name":"id","in":"path","description":"Tax category ID","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a tax category","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"tax category updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxCategory"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxCategoryUpdateParams"}}},"required":true}}},"/api/v3/admin/tax_rates":{"get":{"summary":"List tax rates","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's tax rates. Rates are the entire configuration of\nthe built-in tax provider: each pairs a tax category with a jurisdiction\n(a country, optionally narrowed to one state) and a percentage, and\ndecides whether the tax is already included in the product price\n(VAT-style) or added on top (US-style).\n\nMarkets using an external tax provider ignore these rows — that\nprovider carries its own jurisdiction data.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `included_in_price` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `tax_category_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `amount`, `country_code`, `created_at`, `id`, `included_in_price`, `name`, `state_code`, `tax_category_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxRate","sortable":["amount","country_code","created_at","id","included_in_price","name","rate","state_code","tax_category_id","updated_at"]},"responses":{"200":{"description":"tax rates found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TaxRate"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a tax rate","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a tax rate for the current store. Give either `rate` as a\ndecimal string (`\"0.19\"`) or `rate_percent` as a percentage string (`\"19\"`).\n\nName the jurisdiction with `country_code` (and `state_code` for a\nstate-level rate). Omitting the country makes the rate apply everywhere.\n\nSet `included_in_price` for VAT-style pricing, where the rate is backed\nout of the displayed price rather than added to it.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"tax rate created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRate"}}}},"422":{"description":"validation failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRateParams"}}},"required":true}}},"/api/v3/admin/tax_rates/{id}":{"parameters":[{"name":"id","in":"path","description":"Tax rate ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a tax rate","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"tax rate found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRate"}}}}}},"patch":{"summary":"Update a tax rate","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"tax rate updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRate"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxRateParams"}}},"required":true}},"delete":{"summary":"Delete a tax rate","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the rate. Tax lines it already produced keep their own rate snapshot.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"tax rate deleted"}}}},"/api/v3/admin/translatable_resources":{"get":{"summary":"List translatable resources","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every translatable resource type and its translatable fields (key + content type), so clients can render translation editors generically.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"translatable resources found","content":{"application/json":{}}}}}},"/api/v3/admin/translations/batch":{"post":{"summary":"Batch upsert translations","tags":["Settings"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Atomically upserts translations across many records of (possibly) different translatable resource types in one request — e.g. an option type and all its option values in one save. A flat list of independent registry writes; all entries succeed or none do.\n\n**Required scope:** `write_<resource>` for every resource type in the batch (for API-key authentication) (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"translations upserted","content":{"application/json":{}}},"422":{"description":"unsupported locale rolls back the whole batch","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslationBatchParams"}}},"required":true}}},"/api/v3/admin/admin_users":{"get":{"summary":"List staff","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns admin users with at least one role assignment on the current store.\n\n**Required scope:** `read_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[email_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `first_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `last_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[spree_roles_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `email`, `first_name`, `id`, `last_name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"AdminUser","sortable":["created_at","email","first_name","id","last_name","updated_at"]},"responses":{"200":{"description":"staff found","content":{"application/json":{}}}}}},"/api/v3/admin/admin_users/{id}":{"get":{"summary":"Show a staff member","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"staff member found","content":{"application/json":{}}}}},"patch":{"summary":"Update a staff member","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates name fields and reassigns roles for the current store. `role_ids` is a complete replacement — roles not in the array are removed for this store.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"staff member updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminUserUpdateParams"}}},"required":true}},"delete":{"summary":"Remove a staff member from this store","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes the user's role assignments on the current store. The account is preserved — the user keeps access to any other stores. Removing a role needs the same rights as granting it, and the store always keeps at least one admin.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"staff removed from store"}}}},"/api/v3/admin/invitations":{"get":{"summary":"List invitations","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns invitations for the current store, including pending and accepted.\n\n**Required scope:** `read_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Invitation","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"invitations found","content":{"application/json":{}}}}},"post":{"summary":"Create an invitation","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Invites a teammate by email. The invitation is scoped to the current store and carries the chosen role; on accept, a `RoleUser` is created via the invitation's `after_accept` callback.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"invitation created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationCreateParams"}}},"required":true}}},"/api/v3/admin/invitations/{id}":{"delete":{"summary":"Revoke an invitation","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"invitation revoked"}}}},"/api/v3/admin/invitations/{invitation_id}/acceptance_link":{"get":{"summary":"Get an invitation acceptance link","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the link the invitee opens to accept a pending invitation. The link carries the invitation token, so it needs write access to staff and the right to grant the invitation's role; invitation listings never include it.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"invitation_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"acceptance link found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationAcceptanceLink"}}}}}}},"/api/v3/admin/invitations/{id}/resend":{"patch":{"summary":"Resend an invitation","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Issues a fresh token and dispatches the invitation email again.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"invitation resent","content":{"application/json":{}}}}}},"/api/v3/admin/permissions":{"get":{"summary":"List the permission catalog","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the permission catalog — the grant vocabulary shared by staff role permissions and secret API key scopes. Entries are grouped for permission pickers; labels and descriptions are localized. Readable by any authenticated admin credential.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"catalog returned","content":{"application/json":{}}}}}},"/api/v3/admin/roles":{"get":{"summary":"List roles","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns staff roles with their catalog permissions. Roles are global, not per-store; `mutable: false` marks the protected admin role and host-locked rows.\n\n**Required scope:** `read_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Role","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"roles found","content":{"application/json":{}}}}},"post":{"summary":"Create a role","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a staff role. `permissions` holds catalog keys (see GET /admin/permissions); a caller may only grant keys they effectively hold.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"role created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleCreateParams"}}},"required":true}}},"/api/v3/admin/roles/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a role","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a role name, description or permissions. The admin role and host-locked roles (`mutable: false`) reject changes.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"role updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a role","tags":["Staff"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a role. Fails with 422 while the role is protected or still referenced by staff members or pending invitations.\n\n**Required scope:** `write_staff` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"role deleted"},"422":{"description":"role cannot be deleted","content":{"application/json":{}}}}}},"/api/v3/admin/stock_locations":{"get":{"summary":"List stock locations","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the configured stock locations. Stock locations are global\n(shared across stores). Filter with Ransack predicates such as\n`q[active_eq]`, `q[kind_eq]`, `q[pickup_enabled_eq]`, or\n`q[name_cont]`.\n\nPickup-related attributes (`kind`, `pickup_enabled`,\n`pickup_stock_policy`, `pickup_ready_in_minutes`,\n`pickup_instructions`) drive merchant pickup support at checkout —\ncustomers can collect orders from any active location with\n`pickup_enabled: true`.\n\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `default` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `pickup_enabled` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `returns_enabled` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockLocation","sortable":["active","country_code","created_at","default","id","kind","name","pickup_enabled","returns_enabled","seller_id","state_code","updated_at"]},"responses":{"200":{"description":"stock locations found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockLocation"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a stock location","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new stock location.\n\nSetting `default: true` automatically demotes the previous default\nlocation.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"stock location created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocation"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocationCreateParams"}}},"required":true}}},"/api/v3/admin/stock_locations/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock location ID","schema":{"type":"string"}}],"get":{"summary":"Get a stock location","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single stock location by prefixed ID.\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"stock location found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocation"}}}},"404":{"description":"stock location not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a stock location","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates an existing stock location. Same address-field conventions as\nthe create endpoint.\n\nSetting `default: true` automatically demotes the previous default.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"stock location updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocation"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLocationUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a stock location","tags":["Stock Locations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the stock location (sets `deleted_at`). Existing\nfulfillments that referenced it keep the historical record via\n`Spree::StockLocation.with_deleted`.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"stock location deleted"}}}},"/api/v3/admin/store_credits":{"get":{"summary":"List store credits","tags":["Store Credits"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every store credit in the current store, across all customers.\nRead-only: issuing, editing and deleting a credit stays nested under\nthe customer that holds it.\n\n`meta.totals` carries the outstanding balance as one row per currency,\nsummed over the same filter this request used — so filtering by a\ncustomer answers that customer's balance and no filter answers the\nstore's liability.\n\n\n**Required scope:** `read_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of memo (partial, case-insensitive)."},{"name":"q[from_gift_card]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `from_gift_card`."},{"name":"q[outstanding]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `outstanding`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (customer, created_by).","schema":{"type":"string"}},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `customer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `memo` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[created_by_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `created_by_` | `created_at`, `email`, `first_name`, `id`, `last_name`, `updated_at` |\n| `created_by_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `customer_addresses_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_customer_groups_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_orders_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `customer_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `customer_spree_roles_` | `created_at`, `id`, `name`, `updated_at` |\n| `customer_tags_` | `created_at`, `id`, `name`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `created_by_id`, `currency`, `customer_id`, `id`, `memo`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StoreCredit","sortable":["amount","created_at","created_by_id","currency","customer_id","id","memo","updated_at"]},"responses":{"200":{"description":"store credits found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StoreCredit"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/store_credits/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Retrieve a store credit","tags":["Store Credits"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (customer, created_by).","schema":{"type":"string"}}],"responses":{"200":{"description":"store credit found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoreCredit"}}}},"404":{"description":"not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/store_credits/{store_credit_id}/events":{"parameters":[{"name":"store_credit_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List a store credit's ledger","tags":["Store Credits"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every movement of the credit's balance, newest first: allocated when\nissued, authorized when a checkout starts against it, captured when\nthat order is paid, and voided or credited back if it is cancelled.\n\n\n**Required scope:** `read_store_credits` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StoreCreditEvent","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"events found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StoreCreditEvent"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/variants/{variant_id}/custom_fields":{"get":{"summary":"List variant custom fields","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the variant's custom field values.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"variant_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/products/{product_id}/variants":{"get":{"summary":"List product variants","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of variants for a product, including the default variant.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches SKU, option value or product name (partial, case-insensitive; at least three characters)."},{"name":"q[available_at_stock_location]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `available_at_stock_location` to the given value."},{"name":"q[product_name_or_sku_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `product_name_or_sku_cont` to the given value."},{"name":"q[search_by_product_name_or_sku]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_product_name_or_sku` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., images, prices, stock_levels, option_values). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., sku,price,stock). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[cost_currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carton_package_type_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `carton_weight` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cartons_per_pallet` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cost_currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `cost_price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `country_of_origin` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `deleted_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `depth` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `height` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `hs_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `minimum_order_quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `order_multiple` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `product_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `purchase_unit` | One of `unit`, `carton` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `sku` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `track_inventory` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `units_per_carton` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `weight` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `width` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[option_values_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `prices_price_list_` | `catalog_id`, `created_at`, `ends_at`, `id`, `match_policy`, `name`, `position`, `starts_at`, `status`, `updated_at` |\n| `product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `product_categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `product_channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `product_collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `product_labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `product_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Variant","sortable":["carton_package_type_id","carton_weight","cartons_per_pallet","cost_currency","cost_price","country_of_origin","created_at","deleted_at","depth","discontinue_on","height","hs_code","id","minimum_order_quantity","order_multiple","position","product_id","purchase_unit","sku","track_inventory","units_per_carton","updated_at","weight","width"]},"responses":{"200":{"description":"variants found","content":{"application/json":{}}}}},"post":{"summary":"Create a variant","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new variant for a product. Supports nested prices and stock items.\n\nOption types and values are auto-created if they don't exist.\nPrices are upserted by currency. Stock items are upserted by stock location.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"201":{"description":"variant created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariantCreateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/variants/{id}":{"get":{"summary":"Get a variant","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single variant by ID.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Variant ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., images, prices, stock_levels, option_values). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., sku,price,stock). id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"variant found","content":{"application/json":{}}},"404":{"description":"variant not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a variant","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a variant. Only provided fields are updated.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Variant ID","schema":{"type":"string"}}],"responses":{"200":{"description":"variant updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariantUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a variant","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes a variant.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"product_id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Variant ID","schema":{"type":"string"}}],"responses":{"204":{"description":"variant deleted"}}}},"/api/v3/admin/variants":{"get":{"summary":"List variants","tags":["Variants"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every variant in the store across all products, for pickers and stock views that are not tied to one product.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches SKU, option value or product name (partial, case-insensitive; at least three characters)."},{"name":"q[available_at_stock_location]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `available_at_stock_location` to the given value."},{"name":"q[product_name_or_sku_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `product_name_or_sku_cont` to the given value."},{"name":"q[search_by_product_name_or_sku]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_product_name_or_sku` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[cost_currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carton_package_type_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `carton_weight` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cartons_per_pallet` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `cost_currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `cost_price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `country_of_origin` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `deleted_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `depth` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `height` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `hs_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `minimum_order_quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `order_multiple` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `product_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `purchase_unit` | One of `unit`, `carton` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `sku` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `track_inventory` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `units_per_carton` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `weight` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `width` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[option_values_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `prices_price_list_` | `catalog_id`, `created_at`, `ends_at`, `id`, `match_policy`, `name`, `position`, `starts_at`, `status`, `updated_at` |\n| `product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `product_categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `product_channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `product_collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `product_labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `product_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Variant","sortable":["carton_package_type_id","carton_weight","cartons_per_pallet","cost_currency","cost_price","country_of_origin","created_at","deleted_at","depth","discontinue_on","height","hs_code","id","minimum_order_quantity","order_multiple","position","product_id","purchase_unit","sku","track_inventory","units_per_carton","updated_at","weight","width"]},"responses":{"200":{"description":"variants found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Variant"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/webhook_endpoints/{webhook_endpoint_id}/deliveries":{"parameters":[{"name":"webhook_endpoint_id","in":"path","required":true,"description":"Parent webhook endpoint ID","schema":{"type":"string"}}],"get":{"summary":"List webhook deliveries","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns delivery attempts for the given endpoint, most recent first.\nEach row carries the original request payload, the response code\n(when the receiver replied), the execution time, and any transport\nerror — everything needed to audit failures and decide whether to\nredeliver.\n\n\n**Required scope:** `read_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of event name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-delivered_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[event_name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `delivered_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `event_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `execution_time` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `response_code` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `success` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `delivered_at`, `event_name`, `execution_time`, `id`, `response_code`, `success`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"WebhookDelivery","sortable":["created_at","delivered_at","event_name","execution_time","id","response_code","success","updated_at"]},"responses":{"200":{"description":"deliveries found","content":{"application/json":{}}},"404":{"description":"parent webhook endpoint not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/webhook_endpoints/{webhook_endpoint_id}/deliveries/{id}":{"parameters":[{"name":"webhook_endpoint_id","in":"path","required":true,"description":"Parent webhook endpoint ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook delivery ID","schema":{"type":"string"}}],"get":{"summary":"Get a webhook delivery","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single delivery attempt with the full request payload and\nthe response body the receiver returned. Use this for ad-hoc debug\nof failed deliveries.\n\n\n**Required scope:** `read_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"delivery found","content":{"application/json":{}}},"404":{"description":"delivery not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/webhook_endpoints/{webhook_endpoint_id}/deliveries/{id}/redeliver":{"parameters":[{"name":"webhook_endpoint_id","in":"path","required":true,"description":"Parent webhook endpoint ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Webhook delivery ID to redeliver","schema":{"type":"string"}}],"post":{"summary":"Redeliver a webhook delivery","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new delivery row with the same payload + event_name and\nqueues it. The original row is preserved for audit history.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"redelivery queued","content":{"application/json":{}}}}}},"/api/v3/admin/webhook_endpoints":{"get":{"summary":"List webhook endpoints","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns outbound webhook subscriptions for the current store. Each\nendpoint receives a signed POST when any subscribed event fires.\n`secret_key` is `null` on list reads — the plaintext is delivered\nexactly once on create.\n\n\n**Required scope:** `read_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of url (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `url` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `updated_at`, `url`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"WebhookEndpoint","sortable":["active","created_at","id","name","updated_at","url"]},"responses":{"200":{"description":"webhook endpoints found","content":{"application/json":{}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a new outbound webhook subscription. The plaintext\n`secret_key` is returned **once** in this response — persist it\nimmediately to verify incoming webhook signatures. Subsequent reads\nreturn `null` for the secret. Pass an empty `subscriptions` array or\nomit it to receive every event.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"webhook endpoint created — secret_key returned once","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointCreateParams"}}},"required":true}}},"/api/v3/admin/webhook_endpoints/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Webhook endpoint ID","schema":{"type":"string"}}],"get":{"summary":"Get a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single webhook endpoint by prefixed ID.\n\n**Required scope:** `read_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"webhook endpoint found","content":{"application/json":{}}},"404":{"description":"webhook endpoint not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates name, URL, active flag, or the event subscription list.\nToggling `active` here is equivalent to calling `disable`/`enable`\nwithout an audit reason.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"webhook endpoint updated","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the endpoint and stops future deliveries.\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"webhook endpoint deleted"}}}},"/api/v3/admin/webhook_endpoints/{id}/send_test":{"parameters":[{"name":"id","in":"path","required":true,"description":"Webhook endpoint ID","schema":{"type":"string"}}],"post":{"summary":"Send a test delivery","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a `webhook.test` delivery record and queues it. Use this to\nverify the endpoint is reachable and your signature verification\naccepts Spree's payloads.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"test delivery queued","content":{"application/json":{}}}}}},"/api/v3/admin/webhook_endpoints/{id}/enable":{"parameters":[{"name":"id","in":"path","required":true,"description":"Webhook endpoint ID","schema":{"type":"string"}}],"patch":{"summary":"Re-enable a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Re-enables an endpoint that was manually or automatically disabled.\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"webhook endpoint enabled","content":{"application/json":{}}}}}},"/api/v3/admin/webhook_endpoints/{id}/disable":{"parameters":[{"name":"id","in":"path","required":true,"description":"Webhook endpoint ID","schema":{"type":"string"}}],"patch":{"summary":"Disable a webhook endpoint","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Manually pauses an endpoint. Unlike auto-disable (triggered after\nrepeated delivery failures), no notification email is sent.\n\n\n**Required scope:** `write_webhooks` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"webhook endpoint disabled","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointDisableParams"}}},"required":true}}},"/api/v3/admin/webhook_events":{"get":{"summary":"List webhook events","tags":["Webhooks"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every event a webhook endpoint can subscribe to, including those installed extensions declare. Credential events reach only endpoints that name them, and subscribing to one needs the permission listed; deprecated events name their replacement.","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"events returned","content":{"application/json":{}}}}}},"/api/v3/admin/catalogs":{"get":{"summary":"List catalogs","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store catalogs — product assortments with an optional price list, shown to audiences through assignments.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `active` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `active`, `created_at`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Catalog","sortable":["active","created_at","id","name","position","updated_at"]},"responses":{"200":{"description":"catalogs found","content":{"application/json":{}}}}},"post":{"summary":"Create a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a catalog. Add products and assign audiences (customer group, or company subtree) afterwards.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"catalog created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogParams"}}},"required":true}}},"/api/v3/admin/catalogs/{id}/assign":{"post":{"summary":"Assign a catalog to an audience","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Shows the catalog to an audience. A company assignment covers the node and its whole subtree.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"catalog assigned","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogAssignParams"}}},"required":true}}},"/api/v3/admin/catalogs/{catalog_id}/products":{"get":{"summary":"List catalog products","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The catalog's curated assortment, listed by product name — membership\ncarries no order.\n\n`expand=catalog_price` adds what a buyer on this agreement pays for\neach row and where the amount comes from: `explicit` (an amount\nentered on the catalog's own price list), `automatic` (that list's\npercentage applied to the shop price) or `base` (the shop price\nitself — this agreement does not price the product).\n\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"expand","in":"query","required":false,"description":"Comma-separated. `catalog_price` adds the resolved price to every row.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","created_at","description","discontinue_on","id","name","price","seller_id","slug","status","updated_at"]},"responses":{"200":{"description":"products found, with what the agreement charges","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CatalogProduct"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Add products to a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Curates products into the assortment in bulk. Already-present products are skipped; the count reports what was added.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"products added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}},"delete":{"summary":"Remove products from a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes products from the assortment in bulk. Ids that are not members are ignored; the count reports what was removed.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}}},"/api/v3/admin/catalogs/{catalog_id}/order_minimums":{"get":{"summary":"List catalog order minimums","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The least a whole order must come to under this agreement. One row per currency — Spree holds no exchange rates, so a threshold is never stated once and converted.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CatalogOrderMinimum","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"order minimums found","content":{"application/json":{}}}}},"post":{"summary":"Create a catalog order minimum","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Requires orders in one currency to reach an amount. The buyer sees the shortfall on the cart while they can still act on it; completion is refused below it.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"order minimum created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogOrderMinimumParams"}}},"required":true}}},"/api/v3/admin/catalogs/{catalog_id}/order_minimums/{id}":{"patch":{"summary":"Update a catalog order minimum","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Restates one currency's threshold.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"order minimum updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogOrderMinimumParams"}}},"required":true}},"delete":{"summary":"Delete a catalog order minimum","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Lifts the threshold for one currency, so orders in it may come to any total.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"order minimum deleted"}}}},"/api/v3/admin/catalogs/{catalog_id}/quantity_rules":{"put":{"summary":"Set catalog quantity rules","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Writes the given products' quantity terms in one request, keyed by prefixed product id. The stated pair is written to every variant of the product, which is the grain the database keeps them at. Both fields null clears that product's terms; a product not yet in the assortment is added, since a term with nothing to apply to is not a reachable state. Products absent from the payload are left alone — an agreement may name terms for thousands of SKUs. Read them back on the assortment rows: `GET /catalogs/{id}/products?expand=quantity_rule`.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"catalog_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"quantity rules set"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CatalogProductTermsParams"}}},"required":true}}},"/api/v3/admin/catalogs/{id}/activate":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Activate a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Puts the agreement into effect: its audience starts seeing its\nassortment and paying its prices. Refused for a catalog nobody is\nassigned to, since activating it would reach no buyer — a channel's\ndefault catalog is reached through the channel instead, so it needs\nno assignment.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"catalog activated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Catalog"}}}}}}},"/api/v3/admin/catalogs/{id}/deactivate":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Deactivate a catalog","tags":["Catalogs"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Takes the agreement out of effect. Everything it holds — assignments,\ncommercial terms, its price list — survives, so activating again\nresumes exactly what was there.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"catalog deactivated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Catalog"}}}}}}},"/api/v3/admin/collections":{"get":{"summary":"List collections","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of the store's collections.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., rules, custom_fields, translations).","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `automatic` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `permalink` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `products_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `sort_order` | One of `manual`, `best_selling`, `price asc`, `price desc`, `available_on desc`, `available_on asc`, `name asc`, `name desc` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Collection","sortable":["automatic","created_at","id","name","permalink","position","products_count","sort_order","updated_at"]},"responses":{"200":{"description":"collections found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Collection"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a manual or automatic (rule-based) collection. For automatic collections, send the full desired rule set under `rules`.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"collection created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Collection"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionCreateParams"}}},"required":true}}},"/api/v3/admin/collections/{id}":{"get":{"summary":"Get a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single collection by ID, including its rules.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., rules, custom_fields, translations).","schema":{"type":"string"}}],"responses":{"200":{"description":"collection found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Collection"}}}},"404":{"description":"collection not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a collection. Send `position` to reorder it within the flat list; send the full `rules` set to sync automatic rules.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}}],"responses":{"200":{"description":"collection updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Collection"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CollectionUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a collection.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}}],"responses":{"204":{"description":"collection deleted"}}}},"/api/v3/admin/collections/{collection_id}/products":{"get":{"summary":"List collection products","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Products curated in the collection, ordered by their membership position.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","created_at","description","discontinue_on","id","name","price","seller_id","slug","status","updated_at"]},"responses":{"200":{"description":"products found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Add products to a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Curates products into the collection in bulk (appended to the end). Already-curated products are skipped; the count reports what was added.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}}],"responses":{"201":{"description":"products added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}},"delete":{"summary":"Remove products from a collection","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes products from the collection's manual curation in bulk. Ids that are not curated are ignored; the count reports what was removed.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}}],"responses":{"200":{"description":"products removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}}},"/api/v3/admin/collections/{collection_id}/products/{id}/reposition":{"patch":{"summary":"Reposition a collection product","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Moves a product to a new index among the collection's products.\n\n**Required scope:** `write_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"description":"Collection ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Product ID","schema":{"type":"string"}}],"responses":{"204":{"description":"product repositioned"}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipRepositionParams"}}},"required":true}}},"/api/v3/admin/collection_rules/types":{"get":{"summary":"List available collection rule types","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Enumerates the registered rule kinds with their labels and descriptions — drives the rule picker on an automatic collection. Plugins extend the list by registering `Spree::CollectionRule` subclasses via `config.spree.collection_rules`. The `type` returned here is the wire shorthand accepted when writing a collection's `rules`.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"types found","content":{"application/json":{}}}}}},"/api/v3/admin/commission_lines":{"get":{"summary":"List commission lines","tags":["Commission Lines"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"What each sale actually earned the marketplace, frozen when the order\nwas placed. A later change to a commission rate never reaches these.\n\n`amount` is the fee charged to the seller and `tax_amount` is the VAT on\nthat fee — the marketplace's own service to the seller, a supply\nseparate from the sale itself, which is why the two are not folded\ntogether. `total` is their sum.\n\nOne line per commissioned item, plus one per delivery when the rate that\napplied charges shipping too — read `line_item_id` and `fulfillment_id`\nto tell them apart.\n\nRead-only: correcting a charge is a reversal, not an edit.\n\n\n**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed (e.g., `commission_rate`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `percentage`, `fixed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `rate` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `tax_amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `total` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[commission_rate_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `commission_rate_` | `code`, `created_at`, `enabled`, `id`, `include_shipping`, `kind`, `name`, `position`, `tax_inclusive`, `updated_at`, `value` |\n| `commission_rate_commission_rules_` | `created_at`, `id`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `currency`, `id`, `kind`, `order_id`, `rate`, `tax_amount`, `total`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CommissionLine","sortable":["amount","created_at","currency","id","kind","order_id","rate","tax_amount","total","updated_at"]},"responses":{"200":{"description":"commission lines found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CommissionLine"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/commission_lines/{id}":{"parameters":[{"name":"id","in":"path","description":"Commission line ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a commission line","tags":["Commission Lines"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"commission line found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionLine"}}}},"404":{"description":"commission line not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/commission_rates":{"get":{"summary":"List commission rates","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"What the marketplace charges its sellers.\n\nRates are returned in resolution order: the list is walked top-down and\nthe first rate whose targeting matches the sale wins, so the order you\nsee is the precedence. Move a rate with `position` on update.\n\nA rate carrying no rules matches every sale — `global` says so — which\nis how a marketplace expresses a single default. Because resolution\nstops at the first match, a global rate makes everything below it\nunreachable, so it belongs at the bottom.\n\n\n**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-position`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `enabled` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `include_shipping` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `kind` | One of `percentage`, `fixed` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `tax_inclusive` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `value` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[commission_rules_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `commission_rules_` | `created_at`, `id`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `code`, `created_at`, `enabled`, `id`, `include_shipping`, `kind`, `name`, `position`, `tax_inclusive`, `updated_at`, `value`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CommissionRate","sortable":["code","created_at","enabled","id","include_shipping","kind","name","position","tax_inclusive","updated_at","value"]},"responses":{"200":{"description":"commission rates found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CommissionRate"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a commission rate","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sets what the marketplace charges, and which sales it applies to.\n\n`rules` is the rate's whole targeting, sent inline. Every rule has to\nhold, and a rule naming several records means any of them — so\n\"(Cameras OR Audio) AND that seller\" is a category rule holding two ids\nbeside a seller rule holding one. Send no rules to charge every sale.\n\nRule kinds come from `GET /commission_rates/rule_types`, which also\ndescribes the configuration each one takes. A marketplace that adds its\nown kind sees it there without this endpoint changing.\n\n`commission_tax_rate` is VAT on the commission itself — the\nmarketplace's own service to the seller, a separate supply from the\nsale. Leave it null to let the store's tax engine answer for wherever\nthe seller's business sits.\n\n\n**Required scope:** `write_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"commission rate created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRate"}}}},"422":{"description":"validation failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRateCreateParams"}}},"required":true}}},"/api/v3/admin/commission_rates/rule_types":{"get":{"summary":"List the commission rule kinds","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every rule kind a rate can be narrowed by, with the schema describing\nthe configuration it takes — so a client builds its editor from what\nthis marketplace has rather than a list hardcoded to match core's.\n\n`association_fields` names any catalog-scale reference a kind keeps\noutside its preferences, so an editor knows to render a picker for it.\n\n\n**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"subject types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"schema":{"type":"object","description":"JSON Schema of the type's `preferences`"},"association_fields":{"type":"array","items":{"type":"string"}}}}}}}}}}}}},"/api/v3/admin/commission_rates/{id}":{"parameters":[{"name":"id","in":"path","description":"Commission rate ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Get a commission rate","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"commission rate found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRate"}}}},"404":{"description":"commission rate not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a commission rate","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Editing a rate changes what the next sale is charged, never what a past\none was: commission lines keep their own snapshot of the rate that\napplied.\n\n\n**Required scope:** `write_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"commission rate updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRate"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CommissionRateUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a commission rate","tags":["Commission Rates"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_commissions` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"commission rate deleted"}}}},"/api/v3/admin/companies/{company_id}/addresses":{"get":{"summary":"List company addresses","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the business's addresses: its sites, billing address and delivery points.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[address1_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `address1` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `address2` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `city` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `company` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `first_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `last_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `phone` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `postal_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `state_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Address","sortable":["address1","address2","city","company","country_code","created_at","first_name","id","last_name","phone","postal_code","state_code","updated_at"]},"responses":{"200":{"description":"addresses found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Address"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a company address","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds an address to the business. Pass `default_billing: true` or `default_shipping: true` to make it the default of that kind.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"address created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Address"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyAddressParams"}}},"required":true}}},"/api/v3/admin/companies/{company_id}/invitations":{"get":{"summary":"List company invitations","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the invitations into this business that are still waiting to be accepted.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[email_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `email`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CompanyInvitation","sortable":["created_at","email","id","updated_at"]},"responses":{"200":{"description":"invitations found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CompanyInvitation"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/companies/{company_id}/memberships":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List company members","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the people with standing over this node. Standing covers the node and everything below it in the tree.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CompanyMembership","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"members found","content":{"application/json":{}}}}},"post":{"summary":"Add a member by email","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a person to the node by email. An email matching an existing customer becomes a\nmembership immediately (a `cmem_…` id); an unknown email becomes an invitation\n(a `cinv_…` id) and the invite email goes out.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[],"responses":{"201":{"description":"member added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyMembershipCreateParams"}}},"required":true}}},"/api/v3/admin/companies/{company_id}/tax_exemption_certificates":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List tax exemption certificates","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a business's exemption evidence. `active` is the field that decides whether a certificate\nexempts a sale: a verified certificate stops counting once its expiry date passes, so the status\nalone does not answer it.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[certificate_number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `certificate_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `expires_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `reason_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `pending`, `verified`, `expired`, `revoked` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `certificate_number`, `created_at`, `expires_at`, `id`, `reason_code`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxExemptionCertificate","sortable":["certificate_number","created_at","expires_at","id","reason_code","status","updated_at"]},"responses":{"200":{"description":"certificates found","content":{"application/json":{}}}}},"post":{"summary":"Create a tax exemption certificate","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records exemption evidence against a business. Certificates start `pending` and exempt nothing\nuntil verified.\n\n`country_code` and `state_code` say where the certificate holds — omit both for one valid\neverywhere, give only the country for one valid throughout it. `document_signed_id` takes the\n`signed_id` returned by `POST /api/v3/admin/files`.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[],"responses":{"201":{"description":"certificate created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxExemptionCertificateParams"}}},"required":true}}},"/api/v3/admin/companies/{company_id}/tax_exemption_certificates/{id}/verify":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Verify a tax exemption certificate","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Accepts the certificate as evidence, which is what makes it exempt sales. Only a pending\ncertificate can be accepted — re-accepting a revoked one would restore evidence that was\ndeliberately withdrawn. An installation that checks numbers against a registry, or requires a\nsecond approval, can refuse here, and the refusal is returned as a validation error.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","responses":{"200":{"description":"certificate verified","content":{"application/json":{}}}}}},"/api/v3/admin/companies/{company_id}/tax_exemption_certificates/{id}/revoke":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Revoke a tax exemption certificate","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Withdraws accepted evidence. A verified certificate cannot be deleted — how a sale was taxed has to remain explainable — so revoking is the way out.\n\n**Required scope:** `write_customers` (for API-key authentication).","responses":{"200":{"description":"certificate revoked","content":{"application/json":{}}}}}},"/api/v3/admin/companies/{company_id}/tax_exemption_certificates/{id}/download":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"Download a certificate document","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Streams the uploaded document. Deliberately not a storage link: the bytes come through the API so\nthe same credentials apply to every read of a confidential document. Requires only read access.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","responses":{"200":{"description":"document streamed","content":{"application/json":{}}},"422":{"description":"no document attached","content":{"application/json":{}}}}}},"/api/v3/admin/companies/{company_id}/tax_identifiers":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List company tax registrations","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the business's tax registrations, one per kind. A business registration takes precedence\nover the buyer's own when a sale is for that business, because the invoice is addressed to the\nentity rather than the person who placed the order.\n\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"TaxIdentifier","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"registrations found","content":{"application/json":{}}}}},"post":{"summary":"Create a company tax registration","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Registers a tax number against the business. Verification against the relevant registry runs in\nthe background where a validator is installed for the kind; a stock installation registers none,\nleaving the status unattempted.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[],"responses":{"201":{"description":"registration created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaxIdentifierParams"}}},"required":true}}},"/api/v3/admin/companies/{company_id}/tax_identifiers/{id}/validate":{"parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"company_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"post":{"summary":"Re-check a company tax registration","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Asks the registry again. Manual because a registry answers only \"valid now\" — a number verified\nlast year may have been deregistered since — and because a check that came back unavailable\ncannot otherwise be retried without editing the number.\n\n\n**Required scope:** `write_customers` (for API-key authentication).","responses":{"422":{"description":"no validator installed for this kind","content":{"application/json":{}}}}}},"/api/v3/admin/companies":{"get":{"summary":"List companies","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the business customers of the current store.\n\n**Required scope:** `read_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `company`, `division` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `parent_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `po_number_required` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[children_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `children_` | `created_at`, `id`, `kind`, `name`, `parent_id`, `po_number_required`, `updated_at` |\n| `children_external_references_` | `created_at`, `external_id`, `id`, `resource_type`, `system`, `updated_at` |\n| `children_memberships_` | `created_at`, `id`, `updated_at` |\n| `external_references_` | `created_at`, `external_id`, `id`, `resource_type`, `system`, `updated_at` |\n| `memberships_` | `created_at`, `id`, `updated_at` |\n| `parent_` | `created_at`, `id`, `kind`, `name`, `parent_id`, `po_number_required`, `updated_at` |\n| `parent_external_references_` | `created_at`, `external_id`, `id`, `resource_type`, `system`, `updated_at` |\n| `parent_memberships_` | `created_at`, `id`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `kind`, `name`, `parent_id`, `po_number_required`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Company","sortable":["created_at","id","kind","name","parent_id","po_number_required","updated_at"]},"responses":{"200":{"description":"companies found","content":{"application/json":{}}}}},"post":{"summary":"Create a company","tags":["Companies"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a company node. A root node is a legal entity; pass parent_id and kind to build the organization tree. Exemption certificates and tax registrations hang off legal-entity nodes.\n\n**Required scope:** `write_customers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"company created","content":{"application/json":{}}},"422":{"description":"invalid request","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CompanyParams"}}},"required":true}}},"/api/v3/admin/custom_field_definitions/resource_types":{"get":{"summary":"List what custom fields can be attached to","tags":["Custom Field Definitions"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The resources a definition can describe, from the server's own\nregistry (`Spree.custom_fields.enabled_resources`).\n\nRead this rather than carrying a list: a resource an extension\nregisters appears here without a client release, and a `resource_type`\nthat is not listed is refused on create.\n\n`resource_type` is the value to send; `name` is what a merchant calls\nit — send the value back verbatim rather than deriving it from the name.\n\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"resource types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"resource_type":{"type":"string"},"name":{"type":"string"}}}}}}}}}}}},"/api/v3/admin/collections/{collection_id}/custom_fields":{"get":{"summary":"List collection custom fields","tags":["Collections"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the collection's custom field values.\n\n**Required scope:** `read_collections` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"collection_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/sellers/{seller_id}/custom_fields":{"get":{"summary":"List seller custom fields","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the seller's custom field values.\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"seller_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to expand (e.g., custom_field_definition). Use dot notation for nested expand (max 4 levels).","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include (e.g., key,value,namespace). id is always included.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"CustomField","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"custom fields found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/delivery_profiles":{"get":{"summary":"List delivery profiles","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Fulfillment profiles group products with the stock locations, delivery zones and delivery methods that fulfill them. Every store has exactly one default profile.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryProfile","sortable":["created_at","id","name","position","updated_at"]},"responses":{"200":{"description":"delivery profiles found","content":{"application/json":{}}}}},"post":{"summary":"Create a delivery profile","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a delivery profile. `kind` selects the registered profile kind (shipping, digital, extension kinds); `stock_location_ids` limits fulfillment to those locations — empty means every store location.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"delivery profile created","content":{"application/json":{}}},"422":{"description":"validation error","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryProfileParams"}}},"required":true}}},"/api/v3/admin/delivery_profiles/{delivery_profile_id}/origin_groups":{"parameters":[{"name":"delivery_profile_id","in":"path","required":true,"schema":{"type":"string"}}],"get":{"summary":"List origin groups","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the profile's origin groups: the sets of warehouses that each quote their own delivery rates.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryOriginGroup","sortable":["created_at","id","name","position","updated_at"]},"responses":{"200":{"description":"origin groups found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryOriginGroup"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create an origin group","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Origin groups partition a profile's fulfillment origins: zones and methods belong to a group, so the same products can quote different rate tables per warehouse. `stock_location_ids` replaces the full membership; empty means every store location.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"origin group created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryOriginGroupParams"}}},"required":true}}},"/api/v3/admin/delivery_profiles/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a delivery profile","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"delivery profile updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryProfileParams"}}},"required":true}},"delete":{"summary":"Delete a delivery profile","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The default profile and profiles still referenced by products cannot be deleted.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"delivery profile deleted"}}}},"/api/v3/admin/delivery_methods":{"get":{"summary":"List delivery methods","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns all delivery methods with calculator and zone configuration.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_to_sellers` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `storefront_visible` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_to_sellers`, `created_at`, `id`, `name`, `seller_id`, `storefront_visible`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryMethod","sortable":["available_to_sellers","created_at","id","name","seller_id","storefront_visible","updated_at"]},"responses":{"200":{"description":"delivery methods found","content":{"application/json":{}}}}},"post":{"summary":"Create delivery method","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a delivery method inside a delivery profile (defaults to the store default profile). Delivery behavior comes from the fulfillment provider.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"delivery method created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodParams"}}},"required":true}}},"/api/v3/admin/delivery_methods/calculators":{"get":{"summary":"List delivery calculators","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Registered delivery calculator classes with preference schemas for building configuration forms.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"calculators found","content":{"application/json":{}}}}}},"/api/v3/admin/delivery_zones":{"get":{"summary":"List delivery zones","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the areas delivery methods ship to, each made of countries, states or postal code ranges.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `delivery_profile_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `delivery_profile_id`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryZone","sortable":["created_at","delivery_profile_id","id","name","updated_at"]},"responses":{"200":{"description":"delivery zones found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryZone"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create delivery zone","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a delivery zone with typed members: country, state, or postal_code (prefix or from/to range).\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed, e.g. `members`","schema":{"type":"string"}}],"responses":{"201":{"description":"delivery zone created","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryZoneParams"}}},"required":true}}},"/api/v3/admin/delivery_methods/{delivery_method_id}/rules":{"get":{"summary":"List delivery method rules","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the conditions a delivery method must meet to be offered at checkout, such as an order total or weight range.\n\n**Required scope:** `read_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"delivery_method_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"DeliveryMethodRule","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"rules found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryMethodRule"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a delivery method rule","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a condition to a delivery method. `type` is a rule kind from the\ndelivery method rule types endpoint, and `preferences` takes the\nvalues its schema declares.\n\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"delivery_method_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"rule created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodRule"}}}},"422":{"description":"unknown rule type","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodRuleCreateParams"}}},"required":true}}},"/api/v3/admin/delivery_methods/{delivery_method_id}/rules/{id}":{"patch":{"summary":"Update a delivery method rule","tags":["Delivery"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes a rule's settings or turns it off. Its `type` is fixed once created.\n\n**Required scope:** `write_settings` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"delivery_method_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"rule updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodRule"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMethodRuleUpdateParams"}}},"required":true}}},"/api/v3/admin/integrations":{"get":{"summary":"List integrations","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the integrations connected to the current store. Secret preference values are masked.\n\n**Required scope:** `read_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Integration","sortable":["created_at","id","updated_at"]},"responses":{"200":{"description":"integrations found","content":{"application/json":{}}}}},"post":{"summary":"Connect integration","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Connects an integration type to the current store. Setting active: true verifies the connection and fails with 422 when it cannot connect. Submitting a masked secret value back keeps the stored secret.\n\n**Required scope:** `write_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"integration connected","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationCreateParams"}}},"required":true}}},"/api/v3/admin/integrations/types":{"get":{"summary":"List integration types","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every registered integration type with its gallery metadata and configuration schema. Pure registry discovery — read live connection state from GET /integrations.\n\n**Required scope:** `read_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"integration types found","content":{"application/json":{}}}}}},"/api/v3/admin/integrations/{id}":{"patch":{"summary":"Update integration","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes an integration's credentials or turns it on or off. Setting active: true verifies the connection and fails with 422 when it cannot connect. Submitting a masked secret value back keeps the stored secret.\n\n**Required scope:** `write_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"integration updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationUpdateParams"}}},"required":true}}},"/api/v3/admin/integrations/{id}/test":{"post":{"summary":"Test integration connection","tags":["Integrations"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Runs a live connection check against the provider. Nothing is persisted; a failed check reports the seller error message.\n\n**Required scope:** `write_integrations` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"connection checked","content":{"application/json":{}}}}}},"/api/v3/admin/media":{"get":{"summary":"List media","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns every file in the store's media library, whether or not it has\nbeen placed on a product. Filter with `q[unattached]=true` for files not\nyet in use, `q[media_type_eq]` for images or video, and\n`q[filename_cont]` to search by file name.\n\n\n**Required scope:** `read_media` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[attached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `attached`."},{"name":"q[filename_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `filename_cont` to the given value."},{"name":"q[unattached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `unattached`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[alt_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `alt` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `media_type` | One of `image`, `video`, `external_video` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `alt`, `created_at`, `id`, `media_type`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Media","sortable":["alt","created_at","id","media_type","position","updated_at"]},"responses":{"200":{"description":"media found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Upload a file to the library","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a file to the library without placing it on anything. Upload the\nfile first through `POST /api/v3/admin/files`, then send the signed id\nhere. Put the file on a product by posting to that product's media with\nthis record's id as `source_media_id`.\n\n\n**Required scope:** `write_media` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"file added","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Media"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaLibraryCreateParams"}}},"required":true}}},"/api/v3/admin/media/{id}":{"parameters":[{"name":"id","in":"path","description":"Media ID","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a library file","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits a file in the library, such as its alt text.\n\n**Required scope:** `write_media` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"file updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Media"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaLibraryUpdateParams"}}},"required":true}}},"/api/v3/admin/media/{id}/usage":{"parameters":[{"name":"id","in":"path","description":"Media ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Where a file is used","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Lists everywhere this file appears: products it is placed on, image\nfields that picked it, and descriptions embedding it. Reusing a file\nshares it rather than copying it, so deleting one placement can leave\nothers pointing at the same file — check this first.\n\nDescription matches are best-effort: an embedded image is a plain URL\nwith nothing recording it, so treat an empty result as \"nothing found\",\nnot proof the file is unused.\n\n\n**Required scope:** `read_media` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"usage found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["media","attachment","rich_text"]},"name":{"type":"string","nullable":true},"owner_type":{"type":"string"},"owner_id":{"type":"string","nullable":true},"field":{"type":"string","nullable":true}}}}}}}}}}}},"/api/v3/admin/products/{product_id}/media":{"parameters":[{"name":"product_id","in":"path","description":"Product ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"List product media","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the files placed on a product, in their display order.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[attached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `attached`."},{"name":"q[filename_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `filename_cont` to the given value."},{"name":"q[unattached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `unattached`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[alt_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `alt` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `media_type` | One of `image`, `video`, `external_video` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `alt`, `created_at`, `id`, `media_type`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Media","sortable":["alt","created_at","id","media_type","position","updated_at"]},"responses":{"200":{"description":"media found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Place a library file on a product","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Puts a file that is already in the library onto this product. The new\nrecord shares the source's file rather than copying it, so nothing is\nuploaded and no image is reprocessed; it carries its own alt text,\nposition and variant links from here on.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"file placed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Media"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaCreateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/media/{id}":{"parameters":[{"name":"product_id","in":"path","description":"Product ID","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","description":"Media ID","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update product media","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits a file placed on a product: its alt text, position and focal\npoint, and which of the product's variants it shows for\n(`variant_ids`).\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"media updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Media"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaUpdateParams"}}},"required":true}}},"/api/v3/admin/products/{product_id}/variants/{variant_id}/media":{"parameters":[{"name":"product_id","in":"path","description":"Product ID","required":true,"schema":{"type":"string"}},{"name":"variant_id","in":"path","description":"Variant ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"List variant media","tags":["Media"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the files placed on one of a product's variants, in their display order.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[attached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `attached`."},{"name":"q[filename_cont]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `filename_cont` to the given value."},{"name":"q[unattached]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `unattached`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[alt_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `alt` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `media_type` | One of `image`, `video`, `external_video` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `alt`, `created_at`, `id`, `media_type`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Media","sortable":["alt","created_at","id","media_type","position","updated_at"]},"responses":{"200":{"description":"media found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/deliveries":{"get":{"summary":"List deliveries","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The consignments of a parcel — one per tracking number, each with the carrier status last reported.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[carrier_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carrier` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `pending`, `pre_transit`, `in_transit`, `out_for_delivery`, `available_for_pickup`, `delivered`, `return_to_sender`, `failure`, `unknown` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `tracking_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `carrier`, `created_at`, `id`, `status`, `tracking_number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Delivery","sortable":["carrier","created_at","id","status","tracking_number","updated_at"]},"responses":{"200":{"description":"deliveries found","content":{"application/json":{}}}}},"post":{"summary":"Record a delivery","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a tracked consignment to a parcel — a second box, or a freight PRO number covering several pallets. The carrier is free text.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"201":{"description":"delivery recorded","content":{"application/json":{}}},"422":{"description":"tracking number already recorded on this parcel","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/deliveries/{id}":{"patch":{"summary":"Correct a delivery","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Corrects the tracking number, carrier or link. A corrected number starts the carrier journey over.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Delivery ID","schema":{"type":"string"}}],"responses":{"200":{"description":"delivery updated","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a delivery","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a hand-entered consignment. One a label minted is refused — refund the label instead.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Delivery ID","schema":{"type":"string"}}],"responses":{"204":{"description":"delivery deleted"}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/deliveries/{id}/mark_delivered":{"patch":{"summary":"Mark a delivery delivered","tags":["Deliveries"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Staff confirming one consignment arrived. The parcel becomes delivered once every one of its consignments has.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Delivery ID","schema":{"type":"string"}}],"responses":{"200":{"description":"delivery marked delivered","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryMarkDeliveredParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/labels":{"get":{"summary":"List shipping labels","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Every label bought or uploaded for a parcel, refunded ones included.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[carrier_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `carrier` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `source` | One of `purchased`, `uploaded` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `purchased`, `refund_requested`, `refunded` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `tracking_number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `carrier`, `created_at`, `id`, `source`, `status`, `tracking_number`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ShippingLabel","sortable":["carrier","created_at","id","source","status","tracking_number","updated_at"]},"responses":{"200":{"description":"labels found","content":{"application/json":{}}}}},"post":{"summary":"Buy or record a shipping label","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"With no body, buys the label through the parcel's carrier account. With a `file`, records a label bought elsewhere. Either way the tracking number becomes a delivery on the parcel.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}}],"responses":{"201":{"description":"label purchased","content":{"application/json":{}}},"422":{"description":"provider does not produce labels","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingLabelCreateParams"}}},"required":true}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/labels/{id}":{"get":{"summary":"Get a shipping label","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"One label, with what it cost and where to print it from.\n\n**Required scope:** `read_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Shipping label ID","schema":{"type":"string"}}],"responses":{"200":{"description":"label found","content":{"application/json":{}}}}},"delete":{"summary":"Delete an uploaded label","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes an uploaded label. A purchased label is refunded instead, so the postage history stays honest.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Shipping label ID","schema":{"type":"string"}}],"responses":{"204":{"description":"label deleted"}}}},"/api/v3/admin/orders/{order_id}/fulfillments/{fulfillment_id}/labels/{id}/refund":{"patch":{"summary":"Refund a shipping label","tags":["Shipping Labels"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Asks the carrier to refund a purchased label. The consignment it minted is removed when the parcel never shipped.\n\n**Required scope:** `write_fulfillments` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"order_id","in":"path","required":true,"description":"Order ID","schema":{"type":"string"}},{"name":"fulfillment_id","in":"path","required":true,"description":"Fulfillment ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Shipping label ID","schema":{"type":"string"}}],"responses":{"200":{"description":"refund filed","content":{"application/json":{}}},"422":{"description":"uploaded labels cannot be refunded","content":{"application/json":{}}}}}},"/api/v3/admin/package_types":{"get":{"summary":"List package types","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's packaging vocabulary: the box it ships parcels in\nand the cartons, pallets and containers a wholesale order leaves on.\n\n`volume` is the cubic meters the package occupies, converted from\nwhatever unit its dimensions were recorded in — the figure freight\nvolume rules compare against. It is null until all three sides are\nmeasured.\n\n\n**Required scope:** `read_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `default` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `box`, `envelope`, `carton`, `pallet`, `container` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `default`, `id`, `kind`, `name`, `seller_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PackageType","sortable":["created_at","default","id","kind","name","seller_id","updated_at"]},"responses":{"200":{"description":"package types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PackageType"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a package type","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a kind of packaging to the store.\n\n`weight` is the empty package's own weight, added to content weight on\nevery quote; `max_weight` is what it can hold. Setting `default` makes\nthis the box every parcel quote is built on, and demotes whichever row\nheld that before.\n\nA variant references a `carton`-kind row to say what it is packed\ninto; other kinds are the merchant's own vocabulary.\n\n\n**Required scope:** `write_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"package type created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageType"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageTypeCreateParams"}}},"required":true}}},"/api/v3/admin/package_types/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Package type ID","schema":{"type":"string"}}],"get":{"summary":"Get a package type","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single package type by prefixed ID.\n\n**Required scope:** `read_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"package type found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageType"}}}},"404":{"description":"package type not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a package type","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a package type. Every product packed in it follows the new geometry.\n\n**Required scope:** `write_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"package type updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageType"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PackageTypeUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a package type","tags":["Package Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes a kind of packaging. Refused while any variant is packed into\nit — repack those products first.\n\n\n**Required scope:** `write_package_types` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"package type deleted"}}}},"/api/v3/admin/price_lists/{price_list_id}/products":{"get":{"summary":"List price list products","tags":["Price Lists"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The products the list prices, listed by name — membership is derived from the price rows.\n`expand=price_list_price` adds what the list charges for each variant, with its quantity\nbreaks as tiers, the same reading a catalog's products carry.\n\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"price_list_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches product name or variant SKU (partial, case-insensitive), and the store's searchable custom fields."},{"name":"q[ascend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `ascend_by_price`."},{"name":"q[descend_by_price]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `descend_by_price`."},{"name":"q[in_categories][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `in_categories` to the given value."},{"name":"q[in_category]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_category` to the given value."},{"name":"q[in_collection]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_collection` to the given value."},{"name":"q[in_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `in_stock`."},{"name":"q[in_taxon]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `in_taxon` to the given value."},{"name":"q[not_discontinued]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `not_discontinued`."},{"name":"q[out_of_stock]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `out_of_stock`."},{"name":"q[price_between][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":2},"description":"Applies `price_between` to the given value."},{"name":"q[price_gte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_gte` to the given value."},{"name":"q[price_lte]","in":"query","required":false,"schema":{"type":"number"},"description":"Applies `price_lte` to the given value."},{"name":"q[search_by_name]","in":"query","required":false,"schema":{"type":"string"},"description":"Applies `search_by_name` to the given value."},{"name":"q[with_option_value_ids][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_option_value_ids` to the given value."},{"name":"expand","in":"query","required":false,"description":"Comma-separated. `price_list_price` adds the resolved price to every row.","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `available_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `description` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `discontinue_on` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `price` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `slug` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `active`, `archived`, `proposed`, `rejected` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[categories_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `categories_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `categories_parent_` | `automatic`, `children_count`, `created_at`, `depth`, `id`, `name`, `parent_id`, `permalink`, `position`, `pretty_name`, `products_count`, `updated_at` |\n| `channels_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `collections_` | `automatic`, `created_at`, `id`, `name`, `permalink`, `position`, `products_count`, `sort_order`, `updated_at` |\n| `default_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `default_variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `default_variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `default_variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `default_variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `labels_` | `created_at`, `id`, `name`, `updated_at` |\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `product_categories_` | `category_id`, `created_at`, `id`, `position`, `product_id`, `updated_at` |\n| `product_type_` | `created_at`, `id`, `name`, `updated_at` |\n| `product_type_option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `store_` | `created_at`, `id`, `name`, `updated_at` |\n| `tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `variants_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variants_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variants_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variants_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variants_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Product","sortable":["available_on","created_at","description","discontinue_on","id","name","price","seller_id","slug","status","updated_at"]},"responses":{"200":{"description":"products found, with what the list charges","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PriceListProduct"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Add products to a price list","tags":["Price Lists"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds products to the list in bulk, materializing a placeholder price per variant and store currency. Already-present products are skipped.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"price_list_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"products added","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}},"delete":{"summary":"Remove products from a price list","tags":["Price Lists"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Removes products from the list in bulk, hard-deleting their price rows. Ids that are not members are ignored.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"price_list_id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"products removed","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductMembershipParams"}}},"required":true}}},"/api/v3/admin/product_types":{"get":{"summary":"List product types","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a paginated list of product types.\n\nA product type is a back-office template: it seeds option types and\ncategories onto products created with it, and defines which custom\nfields those products' forms show. It is not exposed on the Store API.\n\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[option_types_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `option_types_` | `created_at`, `id`, `kind`, `label`, `name`, `position`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `name`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"ProductType","sortable":["created_at","id","name","updated_at"]},"responses":{"200":{"description":"product types found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ProductType"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a product type","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Creates a product type.\n\n`option_type_ids` and `category_ids` seed products created with this\ntype. `custom_field_definitions` is a replace-set of the definitions the\nproduct form renders, in `sort_order`. `required` is advisory — the\ndashboard marks the field, but a blank value is never rejected.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"product type created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductType"}}}},"422":{"description":"unprocessable entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductTypeCreateParams"}}},"required":true}}},"/api/v3/admin/product_types/{id}":{"parameters":[{"name":"id","in":"path","description":"Product type ID","required":true,"schema":{"type":"string"}}],"get":{"summary":"Retrieve a product type","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single product type with its option types, categories and custom fields.\n\n**Required scope:** `read_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"product type found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductType"}}}},"404":{"description":"product type not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a product type","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates a product type.\n\nChanges never modify products that already carry the type — use\n`apply_to_products` to backfill those.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"product type updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductType"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductTypeUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a product type","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Deletes a product type. Types still used by products cannot be deleted.\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"product type deleted"}}}},"/api/v3/admin/product_types/{id}/apply_to_products":{"parameters":[{"name":"id","in":"path","description":"Product type ID","required":true,"schema":{"type":"string"}}],"post":{"summary":"Apply a product type to its existing products","tags":["Product Types"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Backfills the type's option types and categories onto the products that\nalready carry it. Additive and idempotent — nothing is removed, and\nre-running is safe.\n\nRuns in the background; the response reports how many products the type\ncurrently has.\n\n\n**Required scope:** `write_products` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"202":{"description":"backfill accepted","content":{"application/json":{"schema":{"type":"object","properties":{"products_count":{"type":"integer"}}}}}}}}},"/api/v3/admin/purchase_orders":{"get":{"summary":"List purchase orders","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Stock bought from suppliers. A purchase order carries what a purchase\nhas and a stock transfer does not: a supplier, a unit cost per line and\nan expected arrival date.\n\nOrdered units never count toward availability. Nothing here changes\n`count_on_hand` until `receive` runs, because a merchant who has\nordered stock does not have it.\n\nStatuses are `draft`, `ordered`, `partially_received`, `received`, `over_received` and\n`canceled`. Each move between them is its own endpoint, not a `PATCH`\nthat writes `status`.\n\nFilter with Ransack predicates such as `q[status_eq]`,\n`q[supplier_id_eq]` or `q[expected_at_lteq]`. Expand `items`,\n`supplier` and `destination_location`.\n\n\n**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number and reference (partial, case-insensitive)."},{"name":"q[closed]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `closed`."},{"name":"q[open]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `open`."},{"name":"q[overdue]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `overdue`."},{"name":"q[past_cancel_by]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `past_cancel_by`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed: items, supplier, destination_location","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `cancel_by` | Date | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `closed_short_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `destination_location_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `expected_at` | Date | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `ordered_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `received_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `draft`, `ordered`, `partially_received`, `received`, `over_received`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `supplier_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[destination_location_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `destination_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `destination_location_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `items_` | `created_at`, `id`, `quantity_ordered`, `quantity_received`, `quantity_rejected`, `unit_cost`, `updated_at`, `variant_id` |\n| `items_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `supplier_` | `city`, `contact_name`, `country_code`, `created_at`, `email`, `id`, `name`, `phone`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `cancel_by`, `closed_short_at`, `created_at`, `currency`, `destination_location_id`, `expected_at`, `id`, `number`, `ordered_at`, `received_at`, `reference`, `status`, `supplier_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"PurchaseOrder","sortable":["cancel_by","closed_short_at","created_at","currency","destination_location_id","expected_at","id","number","ordered_at","received_at","reference","status","supplier_id","updated_at"]},"responses":{"200":{"description":"purchase orders found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PurchaseOrder"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a purchase order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Drafts an order. Nothing is on order and nothing touches availability\nuntil the order is marked as ordered and then received.\n\n`currency` defaults to the store's; set it for a foreign-currency\norder. `expected_at` is a calendar date (`yyyy-mm-dd`) — the day the\nsupplier promised means the same day in every timezone.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"purchase order created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}},"404":{"description":"supplier belongs to another store","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrderCreateParams"}}},"required":true}}},"/api/v3/admin/purchase_orders/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"get":{"summary":"Get a purchase order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed: items, supplier, destination_location","schema":{"type":"string"}}],"responses":{"200":{"description":"purchase order found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}},"404":{"description":"purchase order not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a purchase order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits a draft: its supplier, destination, dates, reference, notes and\nlines. Sending `items` replaces every line the order holds. Status\nmoves through the order's own actions, never through this endpoint.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"purchase order updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrderUpdateParams"}}},"required":true}}},"/api/v3/admin/purchase_orders/{id}/mark_ordered":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"patch":{"summary":"Place the order with the supplier","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Moves a `draft` to `ordered`: the lines are frozen and `ordered_at` is\nstamped. Availability is still untouched — ordered stock is not stock\nthe merchant has.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"purchase order placed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}}}},"/api/v3/admin/purchase_orders/{purchase_order_id}/stock_receipts":{"parameters":[{"name":"purchase_order_id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"get":{"summary":"List the deliveries booked against an order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Each delivery the dock counted in, newest first — with its packing-slip reference and what it accepted and refused.\n\n**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `receivable_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `receivable_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `received_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `received_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `received_by_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `number`, `receivable_id`, `receivable_type`, `received_at`, `received_by_id`, `received_by_type`, `reference`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockReceipt","sortable":["created_at","id","number","receivable_id","receivable_type","received_at","received_by_id","received_by_type","reference","updated_at"]},"responses":{"200":{"description":"deliveries found","content":{"application/json":{}}}}},"post":{"summary":"Book in a delivery","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The moment purchased goods first count toward availability. Records\none delivery as a stock receipt: what this delivery brought, per line,\nnot a running total — a second delivery adds to the first.\n\n`quantity_accepted` reaches the shelf; `quantity_rejected` is refused\nand recorded with a `rejection_reason` (`damaged`, `wrong_item`,\n`expired` or `other`), never stocked. Omit `items` to book in\neverything still outstanding, intact.\n\nEach `received` stock movement carries the line's `unit_cost` and\nnames the receipt, so a delivery can be reconciled against the ledger.\n\nThe order stays `partially_received` while any line is still owed,\nsettles in `received` once every line has what it expected, and in\n`over_received` once any line has more.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"delivery booked in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockReceipt"}}}},"422":{"description":"order has not been placed yet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockReceiptCreateParams"}}},"required":true}}},"/api/v3/admin/purchase_orders/{id}/mark_draft":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"patch":{"summary":"Take an order back to draft","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Reopens a placed order for editing. Only while no delivery has been booked against it; `ordered_at` is cleared.\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"order back in draft","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}}}},"/api/v3/admin/purchase_orders/{id}/close":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"patch":{"summary":"Close an order short","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Ends a partially received order whose balance the supplier will not\ndeliver. Nothing moves: what arrived stays on the shelf, the\noutstanding count stays on each line, and the order settles in\n`received` with `closed_short_at` and the `reason` recorded.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"order closed short","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReceivableCloseParams"}}},"required":true}}},"/api/v3/admin/purchase_orders/{id}/cancel":{"parameters":[{"name":"id","in":"path","required":true,"description":"Purchase order ID","schema":{"type":"string"}}],"patch":{"summary":"Cancel a purchase order","tags":["Purchase Orders"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Closes what is still outstanding. Nothing is unwound: a purchase order\nnever moved stock until units were received, and units already received\nstay on the shelf because the merchant has them.\n\nA `reason` is appended to the order's notes.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"purchase order cancelled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrder"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurchaseOrderCancelParams"}}},"required":true}}},"/api/v3/admin/reporting/saved_reports":{"get":{"summary":"List saved reports","tags":["Reports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the store's saved reports, each a named query staff can run again.\n\n**Required scope:** `read_reports` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seeded` | True or false | `eq` `not_eq` `in` `not_in` `true` `false` `null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `seeded`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SavedReport","sortable":["created_at","id","name","seeded","updated_at"]},"responses":{"200":{"description":"saved reports found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SavedReport"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Create a saved report","tags":["Reports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Saves a reporting query under a name so staff can run it again. The query is validated against the reporting registry.\n\n**Required scope:** `write_reports` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"saved report created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavedReport"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavedReportCreateParams"}}},"required":true}}},"/api/v3/admin/reporting/saved_reports/{id}":{"parameters":[{"name":"id","in":"path","description":"Saved report ID","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a saved report","tags":["Reports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_reports` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"saved report updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavedReport"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavedReportUpdateParams"}}},"required":true}}},"/api/v3/admin/reporting/query":{"post":{"summary":"Run a reporting query","tags":["Reports"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Runs a query against the store's registered metrics and dimensions, in\nthe store's time zone. A metric or dimension the registry does not know\nis refused with the names that are valid, and an API key needs the read\nscope of every resource the query touches.\n\n\n**Required scope:** `read_reports` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"query results","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportingQueryParams"}}},"required":true}}},"/api/v3/admin/seller_requirements":{"get":{"summary":"List seller requirements","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"What this marketplace asks of a seller before it will let them trade,\nin the order sellers work through it.\n\nEach row is one configured requirement. `required` says whether it\nstands between the seller and approval — the others are shown as\nrecommended and counted in their progress, but never block. `active`\nswitches one off without losing how it was worded.\n\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `position` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `name`, `position`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SellerRequirement","sortable":["created_at","id","name","position","updated_at"]},"responses":{"200":{"description":"seller requirements found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerRequirement"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}}}}}}}},"post":{"summary":"Add a seller requirement","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds something the marketplace asks of its sellers.\n\n`type` comes from `GET /seller_requirements/types`, which also\ndescribes the configuration each kind takes. Most kinds answer one\nquestion and can be added once; the open-ended ones — a seller\nconfirmation, a manual check, a document — carry the question in your\nown `name` and `description`, so a store may add as many as it needs.\n\nA kind that reads the seller's own data (their addresses, their\nproducts, whether they accepted the terms) needs nothing from the\nseller beyond doing it. The others wait for the seller to submit\nsomething, and the ones you review wait for you.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"seller requirement created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirement"}}}},"422":{"description":"kind is not registered","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementCreateParams"}}},"required":true}}},"/api/v3/admin/seller_requirements/types":{"get":{"summary":"List seller requirement kinds","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The kinds you can add, and the shape of each one's configuration form.\n\n`configured` says the store already has this kind — meaningful only\nwhere `allow_multiple` is false. `accepts_submissions` says the seller\nrecords having done it rather than it being read from their data, and\n`reviewed_by_operator` says what they send waits for you.\n\nA marketplace that registers its own kind server-side sees it here\nwithout this endpoint changing.\n\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"kinds found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"allow_multiple":{"type":"boolean"},"accepts_submissions":{"type":"boolean"},"reviewed_by_operator":{"type":"boolean"},"configured":{"type":"boolean"},"addable":{"type":"boolean","description":"Whether the operator may add one now. The uniqueness rule is the server's, so clients filter on this rather than deriving it."},"schema":{"type":"object","description":"JSON Schema of the type's `preferences`"}}}}}}}}}}}},"/api/v3/admin/seller_requirements/{id}":{"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"patch":{"summary":"Update a seller requirement","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Changes how a requirement is worded, what it asks for, where it sits in\nthe checklist, and whether it blocks approval.\n\n`type` is not accepted: a saved row's kind never changes, because\nanything a seller already submitted answered the old one.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller requirement updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirement"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a seller requirement","tags":["Seller Requirements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Stops asking for this. Anything sellers already submitted against it\ngoes too — to keep the record while pausing the ask, set `active` to\nfalse instead.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"seller requirement deleted"}}}},"/api/v3/admin/sellers":{"get":{"summary":"List sellers","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the sellers on this marketplace. `status` says where each one\nis in its life on the marketplace, and `sellable` answers the question\nthe status alone cannot: an approved seller who is away cannot be\nbought from either.\n\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"sort","in":"query","required":false,"description":"Sort by field. Prefix with `-` for descending (e.g., `-created_at`).","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `contact_email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `status` | One of `pending`, `invited`, `canceled`, `onboarding`, `ready_for_review`, `approved`, `rejected`, `suspended` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Seller","sortable":["contact_email","created_at","id","name","status","updated_at"]},"responses":{"200":{"description":"sellers found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Seller"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Opens a seller record. The seller starts as `pending` and has no team\nyet — invite someone to run it with the `invite` action below.\n\n`status` is deliberately not writable here or on update: every move\nthrough the lifecycle is its own action, because each one does more\nthan set a column.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"seller created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerCreateParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"get":{"summary":"Get a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single seller, including its settlement and tax configuration.\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}},"404":{"description":"seller not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Updates the seller's profile and the settlement configuration the\noperator owns. A `status` sent here is ignored — use the lifecycle\nactions.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller address written inline","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the seller. Their products are kept and left without a\nseller rather than deleted — what happens to a departed seller's\ncatalog is the operator's decision.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"seller deleted"}}}},"/api/v3/admin/sellers/{id}/invite":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"post":{"summary":"Invite someone to run a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sends an invitation to the seller's own team and moves the seller to\n`invited`. The person becomes a member when they accept, and can then\nsign in to the seller panel.\n\n`role_id` must name a role this seller owns; omit it for the seller's\nown admin role. Re-inviting is allowed — an invitation expires, or the\nfirst one goes to the wrong address.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"invitation sent","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerInviteParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}/approve":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Approve a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Lets the seller sell. This is also the way back for one that was\nsuspended or turned down, and it clears any holiday along with the\nsuspension.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller approved","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}},"422":{"description":"seller cannot be approved from its current status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerApproveParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}/reopen_onboarding":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Send a seller back to onboarding","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a seller waiting for review to onboarding, with a `note`\nsaying what they have to fix. Unlike `reject`, this expects them back.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"onboarding reopened","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerReopenOnboardingParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}/suspend":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Suspend a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Stops a trading seller from selling. Their catalog and history stay,\nand approving reinstates them. Use this rather than `reject` for a\nseller already on the marketplace — it says something different, and\nit can be undone.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller suspended","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerSuspendParams"}}},"required":true}}},"/api/v3/admin/sellers/{id}/reject":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Reject a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Turns down an applicant who never traded. A seller already selling is\nsuspended instead; rejecting one is refused.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"seller rejected","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Seller"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRejectParams"}}},"required":true}}},"/api/v3/admin/sellers/{seller_id}/balances":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"get":{"summary":"List a seller's balances","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Where one seller stands with the marketplace, one row per currency:\nwhat they have earned (completed transfers, refund reversals\nincluded), what has been paid to them, what is still owed, and\nearnings the payout provider has not yet confirmed.\n\nComputed from the ledger rather than stored, so the rows carry no id.\n\n\n**Required scope:** `read_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"balances listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerBalance"}}},"required":["data"]}}}},"404":{"description":"seller not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/sellers/{seller_id}/payouts":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"post":{"summary":"Settle a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sweeps everything this seller is owed into a payout — one per currency,\nsince nothing is ever converted between them.\n\nThis is what the `manual` payout interval means: the scheduled sweep\nruns on each seller's own interval and skips anyone set to `manual`,\nleaving the operator to decide when. It also settles any other seller\nearly.\n\nIt records the settlement rather than sending money: the built-in\nprovider waits to be told the bank transfer went out, which is\n`PATCH /api/v3/admin/seller_payouts/{id}/complete`.\n\nAnswers `422` when there is nothing to settle — no payout account,\nnothing unsettled, or a balance below the seller's minimum.\n\n\n**Required scope:** `write_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"seller settled","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerPayout"}}},"required":["data"]}}}},"422":{"description":"nothing to settle","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/sellers/{seller_id}/requirement_submissions":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}}],"get":{"summary":"List a seller's requirement submissions","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"What this seller submitted against the marketplace requirements, with the review decision on each.\n\n**Required scope:** `read_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Records per page (max 100)","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `reviewed_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `status` | One of `pending`, `accepted`, `rejected`, `waived` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[requirement_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `requirement_` | `created_at`, `id`, `name`, `position`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `id`, `reviewed_at`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SellerRequirementSubmission","sortable":["created_at","id","reviewed_at","status","updated_at"]},"responses":{"200":{"description":"submissions listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerRequirementSubmission"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}},"post":{"summary":"Waive a requirement for a seller","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Excuses this one seller from a requirement the marketplace asks of\neveryone, recorded as a `waived` submission. The operator never\nsubmits on the seller's behalf: this endpoint only waives.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"requirement waived","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementSubmission"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementWaiveParams"}}},"required":true}}},"/api/v3/admin/sellers/{seller_id}/requirement_submissions/{id}/accept":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Requirement submission ID","schema":{"type":"string"}}],"patch":{"summary":"Accept a seller's submission","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Marks what the seller submitted as meeting the requirement.\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"submission accepted","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementSubmission"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementReviewParams"}}}}}},"/api/v3/admin/sellers/{seller_id}/requirement_submissions/{id}/reject":{"parameters":[{"name":"seller_id","in":"path","required":true,"description":"Seller prefixed ID","schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Requirement submission ID","schema":{"type":"string"}}],"patch":{"summary":"Reject a seller's submission","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Turns down what the seller submitted. `review_note` is the reason sent\nback to the seller, who can then submit again.\n\n\n**Required scope:** `write_sellers` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"submission rejected","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementSubmission"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerRequirementReviewParams"}}}}}},"/api/v3/admin/seller_transfers":{"get":{"summary":"List seller transfers","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The fund ledger: what each seller earned from an order, and any\nreversals. Read-only, since fulfilment and refunds write it.\n\n\n**Required scope:** `read_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of reference (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Records per page (max 100)","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `earning`, `refund_reversal` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `payout_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `provider` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `pending`, `processing`, `completed`, `failed`, `unresolved` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[payout_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `payout_` | `amount`, `created_at`, `currency`, `id`, `period_end`, `period_start`, `provider`, `reference`, `seller_id`, `status`, `updated_at` |\n| `payout_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `refund_` | `created_at`, `id`, `updated_at` |\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `currency`, `id`, `kind`, `order_id`, `payout_id`, `provider`, `reference`, `seller_id`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SellerTransfer","sortable":["amount","created_at","currency","id","kind","order_id","payout_id","provider","reference","seller_id","status","updated_at"]},"responses":{"200":{"description":"transfers listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerTransfer"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/seller_payouts":{"get":{"summary":"List seller payouts","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Settlements to sellers, each batching the transfers that had\naccumulated since the last. `pending` and `processing` payouts are\nstill owed; `completed` ones reached the seller.\n\n\n**Required scope:** `read_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of reference (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Records per page (max 100)","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[currency_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `amount` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `currency` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `period_end` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `period_start` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `provider` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `seller_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `pending`, `processing`, `completed`, `failed`, `unresolved` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[seller_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `amount`, `created_at`, `currency`, `id`, `period_end`, `period_start`, `provider`, `reference`, `seller_id`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"SellerPayout","sortable":["amount","created_at","currency","id","period_end","period_start","provider","reference","seller_id","status","updated_at"]},"responses":{"200":{"description":"payouts listed","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SellerPayout"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/seller_payouts/{id}/complete":{"parameters":[{"name":"id","in":"path","required":true,"description":"Seller payout prefixed ID","schema":{"type":"string"}}],"patch":{"summary":"Mark a payout paid","tags":["Sellers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records that the money reached the seller, which is what debits their\nbalance — a balance is earnings less *completed* settlements.\n\nThis is the step the built-in provider waits for: it files the\nsettlement when the payout is created and expects an operator to say\nthe bank transfer went out. A connected provider marks its own payouts\npaid when its webhook reports the money landed.\n\nSend the provider's own id for the transfer as `reference` when there\nis one. Completing a payout that is already complete answers `200`\nwithout recording it twice, so a redelivered webhook or a double click\nis safe.\n\n\n**Required scope:** `write_payouts` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"payout completed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerPayout"}}}},"404":{"description":"payout not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SellerPayoutCompleteParams"}}},"required":true}}},"/api/v3/admin/stock_levels":{"get":{"summary":"List stock levels","tags":["Stock"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"One row per variant per stock location, carrying every figure the\nInventory page shows: `count_on_hand` (on hand), `allocated_count`\n(committed to placed orders), `reserved_count` (held by checkouts in\nprogress), `available_count` (on hand minus committed) and\n`incoming_count` (on its way on an open purchase order or a transfer\nin transit). The variant and location are named flat on the row\n(`variant_name`, `variant_sku`, `stock_location_name`, `thumbnail_url`)\nso a list needs no expansion.\n\nFilter with `q[stock_location_id_eq]`, `q[variant_id_eq]` or\n`q[variant_sku_or_variant_product_name_cont]`.\n\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of variant sku and variant product name (partial, case-insensitive)."},{"name":"q[with_stock_status][]","in":"query","required":false,"schema":{"type":"array","items":{"type":"string"}},"description":"Applies `with_stock_status` to the given value."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[allocated_count_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `allocated_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `count_on_hand` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `incoming_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `reserved_count` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `stock_location_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `variant_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[stock_location_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `stock_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `stock_location_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `variant_option_values_` | `created_at`, `id`, `label`, `name`, `position`, `updated_at` |\n| `variant_prices_` | `amount`, `compare_at_amount`, `created_at`, `currency`, `id`, `min_quantity`, `price_list_id`, `updated_at`, `variant_id` |\n| `variant_product_` | `available_on`, `created_at`, `description`, `discontinue_on`, `id`, `name`, `price`, `seller_id`, `slug`, `status`, `updated_at` |\n| `variant_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `variant_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `allocated_count`, `count_on_hand`, `created_at`, `id`, `incoming_count`, `reserved_count`, `stock_location_id`, `updated_at`, `variant_id`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockLevel","sortable":["allocated_count","count_on_hand","created_at","id","incoming_count","reserved_count","stock_location_id","updated_at","variant_id"]},"responses":{"200":{"description":"stock levels found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockLevel"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/stock_levels/bulk_upsert":{"post":{"summary":"Bulk-upsert stock levels","tags":["Stock"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Sets stock levels for many (variant, location) pairs at once — what a\nwarehouse or ERP feed posts on a schedule.\n\nEach row names its variant and stock location by Spree id\n(`variant_id`, `stock_location_id`).\n\nA row carries either `count_on_hand` — the absolute level the external\nsystem reports — or `adjustment`, a relative change for feeds that\nreport movements instead. Every change is written as a stock movement,\nso a merchant can still see why a figure moved.\n\nThe response carries `stock_level_count`: how many rows moved a shelf.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"stock levels updated","content":{"application/json":{}}},"422":{"description":"row is missing a level","content":{"application/json":{}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLevelBulkUpsertParams"}}},"required":true}}},"/api/v3/admin/stock_levels/{id}":{"patch":{"summary":"Update a stock level","tags":["Stock"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Corrects one shelf. Send `count_on_hand` for the count the shelf should\nend at, or `adjustment` for a signed change; either is recorded as a\nstock movement labelled with `reason`.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"description":"Stock level ID","schema":{"type":"string"}}],"responses":{"200":{"description":"stock level updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLevel"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockLevelUpdateParams"}}},"required":true}}},"/api/v3/admin/stock_movements":{"get":{"summary":"List stock movements","tags":["Stock Movements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the stock ledger, newest first. Every row says what happened to\nstock (`kind`) and carries a direct reference to what caused it, so a\nmerchant can answer \"why is this number what it is?\" from the data.\n\nKinds are `received` (goods arrived), `allocated` (stock promised to a\nplaced order), `shipped` (promised stock left), `released` (a promise\nwithdrawn) and `adjusted` (a manual correction, which always carries a\n`reason`).\n\nMovements are immutable — reversing one means writing its counterpart\nthrough the resource that caused it, which is why there is no create,\nupdate or delete here.\n\nFilter with Ransack predicates such as `q[kind_eq]`,\n`q[stock_level_id_eq]`, `q[order_id_eq]`, `q[fulfillment_id_eq]` or\n`q[created_at_gteq]`.\n\n`kind` is null on rows written before Spree 6.0 until\n`spree:migrate_stock_movements_to_typed_rows` has run.\n\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[reason_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `exchange_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `fulfillment_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `kind` | One of `received`, `allocated`, `shipped`, `released`, `adjusted` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `purchase_order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `reason` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `return_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `stock_level_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `stock_receipt_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `stock_transfer_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `unit_cost` | Amount | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[stock_level_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `stock_level_` | `allocated_count`, `count_on_hand`, `created_at`, `id`, `incoming_count`, `reserved_count`, `stock_location_id`, `updated_at`, `variant_id` |\n| `stock_level_stock_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `stock_level_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `exchange_id`, `fulfillment_id`, `id`, `kind`, `order_id`, `purchase_order_id`, `quantity`, `reason`, `return_id`, `stock_level_id`, `stock_receipt_id`, `stock_transfer_id`, `unit_cost`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockMovement","sortable":["created_at","exchange_id","fulfillment_id","id","kind","order_id","purchase_order_id","quantity","reason","return_id","stock_item_id","stock_level_id","stock_receipt_id","stock_transfer_id","unit_cost","updated_at"]},"responses":{"200":{"description":"stock movements found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockMovement"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/stock_movements/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock movement ID","schema":{"type":"string"}}],"get":{"summary":"Get a stock movement","tags":["Stock Movements"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns a single stock movement by prefixed ID.\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"fields","in":"query","required":false,"description":"Comma-separated list of fields to include. id is always included.","schema":{"type":"string"}}],"responses":{"200":{"description":"stock movement found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockMovement"}}}},"404":{"description":"stock movement not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/api/v3/admin/stock_reservations":{"get":{"summary":"List stock reservations","tags":["Stock"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Returns the stock held for orders that are being checked out, so it cannot be sold twice before they complete or the hold expires.\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[created_at_eq]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `expires_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `line_item_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `order_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `quantity` | Number | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `stock_level_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[line_item_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `line_item_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `line_item_order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `line_item_tax_category_` | `created_at`, `id`, `is_default`, `name`, `tax_code`, `updated_at` |\n| `line_item_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `order_` | `channel_id`, `completed_at`, `considered_risky`, `coupon_code`, `created_at`, `currency`, `customer_id`, `delivery_total`, `email`, `fulfillment_status`, `id`, `item_total`, `number`, `order_group_id`, `payment_status`, `po_number`, `seller_id`, `status`, `total`, `total_quantity`, `updated_at` |\n| `order_bill_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_channel_` | `active`, `code`, `created_at`, `default`, `id`, `name`, `store_id`, `updated_at` |\n| `order_customer_` | `accepts_email_marketing`, `created_at`, `email`, `first_name`, `id`, `last_name`, `phone`, `updated_at` |\n| `order_fulfillments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_line_items_` | `additional_tax_total`, `adjustment_total`, `cost_price`, `created_at`, `discount_total`, `id`, `included_tax_total`, `non_taxable_adjustment_total`, `order_id`, `pre_tax_amount`, `price`, `quantity`, `tax_category_id`, `taxable_adjustment_total`, `updated_at`, `variant_id` |\n| `order_order_group_` | `created_at`, `currency`, `email`, `id`, `number`, `updated_at` |\n| `order_promotions_` | `code`, `created_at`, `expires_at`, `id`, `kind`, `name`, `path`, `promotion_category_id`, `starts_at`, `updated_at` |\n| `order_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `order_ship_address_` | `address1`, `address2`, `city`, `company`, `country_code`, `created_at`, `first_name`, `id`, `last_name`, `phone`, `postal_code`, `state_code`, `updated_at` |\n| `order_shipments_` | `created_at`, `id`, `number`, `updated_at` |\n| `order_store_` | `created_at`, `id`, `name`, `updated_at` |\n| `order_tags_` | `created_at`, `id`, `name`, `updated_at` |\n| `stock_level_` | `allocated_count`, `count_on_hand`, `created_at`, `id`, `incoming_count`, `reserved_count`, `stock_location_id`, `updated_at`, `variant_id` |\n| `stock_level_stock_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `stock_level_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n\n</Accordion>\n\n**Sort by:** `created_at`, `expires_at`, `id`, `line_item_id`, `order_id`, `quantity`, `stock_level_id`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockReservation","sortable":["created_at","expires_at","id","line_item_id","order_id","quantity","stock_item_id","stock_level_id","updated_at"]},"responses":{"200":{"description":"stock reservations found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockReservation"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}}}}},"/api/v3/admin/stock_transfers":{"get":{"summary":"List stock transfers","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Stock moving between two of the merchant's own warehouses.\n\nA transfer is a trip, not an instant. Units leave the source when the\ntransfer is marked in transit and land at the destination when somebody\ncounts them in — in between they are in flight, gone from one shelf and\nnot yet on the other.\n\nStatuses are `draft`, `ready_to_ship`, `in_transit`,\n`partially_received`, `received`, `over_received` and `canceled`. Each move between them\nis its own endpoint, not a `PATCH` that writes `status`.\n\nReceiving from a supplier is a purchase order, not a transfer with a\nmissing source.\n\nFilter with Ransack predicates such as `q[status_eq]`,\n`q[source_location_id_eq]` or `q[number_or_reference_cont]`. Expand\n`items`, `source_location` and `destination_location`.\n\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of number and reference (partial, case-insensitive)."},{"name":"q[closed]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `closed`."},{"name":"q[open]","in":"query","required":false,"schema":{"type":"boolean"},"description":"Set to `true` to apply `open`."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed: items, source_location, destination_location","schema":{"type":"string"}}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `closed_short_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `destination_location_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `received_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `shipped_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `source_location_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `status` | One of `draft`, `ready_to_ship`, `in_transit`, `partially_received`, `received`, `over_received`, `canceled` | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n<Accordion title=\"Filters through associations\">\n\nPrefix an associated record's attribute with the association, as in `q[destination_location_id_eq]`. The same predicates apply.\n\n| Prefix | Attributes |\n|---|---|\n| `destination_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `destination_location_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n| `items_` | `created_at`, `id`, `quantity_received`, `quantity_rejected`, `quantity_shipped`, `updated_at`, `variant_id` |\n| `items_variant_` | `carton_package_type_id`, `carton_weight`, `cartons_per_pallet`, `cost_currency`, `cost_price`, `country_of_origin`, `created_at`, `deleted_at`, `depth`, `discontinue_on`, `height`, `hs_code`, `id`, `minimum_order_quantity`, `order_multiple`, `position`, `product_id`, `purchase_unit`, `sku`, `track_inventory`, `units_per_carton`, `updated_at`, `weight`, `width` |\n| `source_location_` | `active`, `country_code`, `created_at`, `default`, `id`, `kind`, `name`, `pickup_enabled`, `returns_enabled`, `seller_id`, `state_code`, `updated_at` |\n| `source_location_seller_` | `contact_email`, `created_at`, `id`, `name`, `status`, `updated_at` |\n\n</Accordion>\n\n**Sort by:** `closed_short_at`, `created_at`, `destination_location_id`, `id`, `number`, `received_at`, `reference`, `shipped_at`, `source_location_id`, `status`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockTransfer","sortable":["closed_short_at","created_at","destination_location_id","id","number","received_at","reference","shipped_at","source_location_id","status","updated_at"]},"responses":{"200":{"description":"stock transfers found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/StockTransfer"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Persists a draft — a packing list the merchant can still edit. Nothing\nmoves until the transfer is marked in transit.\n\nA draft may legitimately open empty and gain lines as the merchant\npacks. Both warehouses are required and must belong to the same store.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"stock transfer created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}},"404":{"description":"warehouse belongs to another store","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransferCreateParams"}}},"required":true}}},"/api/v3/admin/stock_transfers/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"get":{"summary":"Get a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"expand","in":"query","required":false,"description":"Comma-separated associations to embed: items, source_location, destination_location","schema":{"type":"string"}}],"responses":{"200":{"description":"stock transfer found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}},"404":{"description":"stock transfer not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Edits a draft: its reference, notes, either end, and its lines.\nSending `items` replaces every line the draft holds. Status moves\nthrough the transfer's own actions, never through this endpoint.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"stock transfer updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransferUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Drafts only. Past `draft` the transfer describes a box that physically\nexists, so it is cancelled rather than deleted — a 422 says so.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"stock transfer deleted"}}}},"/api/v3/admin/stock_transfers/{id}/mark_ready":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Mark a transfer ready to ship","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Freezes the lines so the warehouse and the merchant are looking at the\nsame list. Nothing leaves the shelf yet.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer is ready to ship","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}}}},"/api/v3/admin/stock_transfers/{id}/mark_in_transit":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Send a transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"The moment stock leaves the source warehouse: `shipped` movements are\nwritten against the source's levels and `shipped_at` is stamped. The\ndestination is deliberately untouched — the units are in flight.\n\nRefused with a 422 when the source does not hold enough. Pass\n`force: true` to record the departure anyway: a merchant forcing it has\ndecided the box left whatever the ledger claims.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer is in transit","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransferMarkInTransitParams"}}},"required":true}}},"/api/v3/admin/stock_transfers/{stock_transfer_id}/stock_receipts":{"parameters":[{"name":"stock_transfer_id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"get":{"summary":"List the deliveries counted in against a transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Each delivery the destination counted in, with what it accepted and refused.\n\n**Required scope:** `read_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[number_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `number` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `receivable_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `receivable_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `received_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `received_by_id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `received_by_type` | Type | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `reference` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `created_at`, `id`, `number`, `receivable_id`, `receivable_type`, `received_at`, `received_by_id`, `received_by_type`, `reference`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"StockReceipt","sortable":["created_at","id","number","receivable_id","receivable_type","received_at","received_by_id","received_by_type","reference","updated_at"]},"responses":{"200":{"description":"deliveries found","content":{"application/json":{}}}}},"post":{"summary":"Count a delivery in","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Records one delivery the destination warehouse counted in, as a stock\nreceipt. Partial receipt is the normal case: ten left, eight arrived,\ntwo were crushed in transit. Quantities are this delivery's counts —\na second box adds to the first rather than restating it.\n\n`quantity_accepted` lands on the destination's shelf;\n`quantity_rejected` is refused and recorded with a `rejection_reason`\n(`damaged`, `wrong_item`, `expired` or `other`), never stocked. A\nrefused unit still arrived, so it counts toward the trip being over.\nOmit `items` to count in everything still outstanding, intact.\n\nThe transfer stays `partially_received` while units are still on the\nroad, settles in `received` once everything has arrived, and in\n`over_received` once more arrived than was shipped.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"delivery counted in","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockReceipt"}}}},"422":{"description":"transfer has not shipped yet","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockReceiptCreateParams"}}},"required":true}}},"/api/v3/admin/stock_transfers/{id}/mark_draft":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Take a transfer back to draft","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Unfreezes a ready-to-ship transfer so its lines can be changed. Nothing has left the source, so nothing is undone.\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer back in draft","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}}}},"/api/v3/admin/stock_transfers/{id}/close":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Close a transfer short","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Ends a partially received transfer whose missing units are not going\nto turn up. Nothing moves — they already left the source — and the\ntransfer settles in `received` with `closed_short_at` and the\n`reason` recorded, the outstanding count left on each line.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer closed short","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReceivableCloseParams"}}},"required":true}}},"/api/v3/admin/stock_transfers/{id}/cancel":{"parameters":[{"name":"id","in":"path","required":true,"description":"Stock transfer ID","schema":{"type":"string"}}],"patch":{"summary":"Cancel a stock transfer","tags":["Stock Transfers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Calls the trip off.\n\nCancelling a draft or a packed transfer costs nothing — no stock has\nmoved. Cancelling one already in transit needs `on_in_transit`, because\nthe units are physically gone from the source: either they come back\n(`restock`, as if the transfer had never shipped) or they are written\noff as lost (`write_off`). There is no default — guessing would either\ninvent stock or destroy it — so an in-flight cancellation without it is\nrefused with a 422.\n\n\n**Required scope:** `write_stock` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"transfer cancelled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransfer"}}}},"422":{"description":"in-transit cancellation needs a decision","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockTransferCancelParams"}}},"required":true}}},"/api/v3/admin/suppliers":{"get":{"summary":"List suppliers","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Who the merchant buys stock from. A supplier is an address-book entry\nwith a purchasing history — not a party that sells on the store, which\nis a seller.\n\nSuppliers belong to one store, and are soft-deleted so the purchase\norders that name them stay readable.\n\nFilter with Ransack predicates such as\n`q[name_or_contact_name_or_email_cont]` or `q[country_code_eq]`.\n\n\n**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}},{"name":"q[search]","in":"query","required":false,"schema":{"type":"string"},"description":"Matches any of name, contact name, and email (partial, case-insensitive)."},{"name":"page","in":"query","required":false,"description":"Page number","schema":{"type":"integer"}},{"name":"limit","in":"query","required":false,"description":"Number of records per page","schema":{"type":"integer"}},{"name":"q","in":"query","required":false,"style":"deepObject","explode":true,"schema":{"type":"object","additionalProperties":true},"description":"Attribute filters, as `q[<attribute>_<predicate>]=value`. See Filters above for the list."}],"x-mint":{"content":"## Filters\n\nFilter with `q[<attribute>_<predicate>]=value`, for example `q[name_cont]=…`. Send a list as `q[<attribute>_in][]=a&q[<attribute>_in][]=b`. [How filters work](/api-reference/admin-api/querying#which-filters-an-endpoint-accepts).\n\n| Attribute | Kind | Predicates |\n|---|---|---|\n| `city` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `contact_name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `country_code` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `created_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n| `email` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `id` | Prefixed ID | `eq` `not_eq` `in` `not_in` `null` `not_null` |\n| `name` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `phone` | Text | `eq` `not_eq` `in` `not_in` `cont` `i_cont` `not_cont` `start` `end` `null` `not_null` `present` `blank` |\n| `updated_at` | Date and time | `eq` `not_eq` `in` `not_in` `lt` `lteq` `gt` `gteq` `null` `not_null` |\n\n**Sort by:** `city`, `contact_name`, `country_code`, `created_at`, `email`, `id`, `name`, `phone`, `updated_at`. Prefix a field with `-` to sort descending."},"x-spree-filters":{"table":"Supplier","sortable":["city","contact_name","country_code","created_at","email","id","name","phone","updated_at"]},"responses":{"200":{"description":"suppliers found","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Supplier"}},"meta":{"$ref":"#/components/schemas/PaginationMeta"}},"required":["data","meta"]}}}},"401":{"description":"unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create a supplier","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Adds a supplier to this store's address book. The address is inline —\nstreet, city, state and country live on the supplier itself, the same\nshape a stock location uses.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"201":{"description":"supplier created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Supplier"}}}},"422":{"description":"validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupplierCreateParams"}}},"required":true}}},"/api/v3/admin/suppliers/{id}":{"parameters":[{"name":"id","in":"path","required":true,"description":"Supplier ID","schema":{"type":"string"}}],"get":{"summary":"Get a supplier","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `read_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"supplier found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Supplier"}}}},"404":{"description":"supplier not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"patch":{"summary":"Update a supplier","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"200":{"description":"supplier updated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Supplier"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupplierUpdateParams"}}},"required":true}},"delete":{"summary":"Delete a supplier","tags":["Suppliers"],"security":[{"api_key":[],"bearer_auth":[]}],"description":"Soft-deletes the supplier, so the purchase orders naming it stay\nreadable. Refused with a 422 while a purchase order still points at it.\n\n\n**Required scope:** `write_purchasing` (for API-key authentication).","parameters":[{"name":"x-spree-api-key","in":"header","required":true,"schema":{"type":"string"}},{"name":"Authorization","in":"header","required":true,"description":"Bearer token for admin authentication","schema":{"type":"string"}}],"responses":{"204":{"description":"supplier deleted"}}}}},"components":{"schemas":{"PaginationMeta":{"type":"object","properties":{"page":{"type":"integer"},"limit":{"type":"integer"},"count":{"type":"integer","description":"Total number of records"},"pages":{"type":"integer","description":"Total number of pages"},"from":{"type":"integer","description":"Index of first record on this page"},"to":{"type":"integer","description":"Index of last record on this page"},"in":{"type":"integer","description":"Number of records on this page"},"previous":{"type":"integer","nullable":true,"description":"Previous page number"},"next":{"type":"integer","nullable":true,"description":"Next page number"}},"required":["page","limit","count","pages","from","to","in"]},"ErrorResponse":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"details":{"type":"object","description":"Field-specific validation errors","nullable":true}},"required":["code","message"]}},"required":["error"]},"AuthResponse":{"type":"object","properties":{"token":{"type":"string","description":"JWT access token"},"user":{"$ref":"#/components/schemas/AdminUser"}},"required":["token","user"]},"PermissionRule":{"type":"object","description":"A single permission rule (CanCanCan rule). Rules are applied in order, last-matching-wins.","properties":{"allow":{"type":"boolean","description":"true for `can`, false for `cannot`"},"actions":{"type":"array","items":{"type":"string"},"description":"Action names, e.g. [\"read\", \"update\"] or [\"manage\"]"},"subjects":{"type":"array","items":{"type":"string"},"description":"Subject short names, e.g. [\"product\"] or [\"all\"]"},"has_conditions":{"type":"boolean","description":"True if the server-side rule has per-record conditions. The SPA shows the action optimistically and handles 403 from the API."}},"required":["allow","actions","subjects","has_conditions"]},"ImportSchemaField":{"type":"object","description":"A canonical column of an import type, including per-store custom field columns","properties":{"name":{"type":"string","description":"Canonical field name used in mappings"},"label":{"type":"string","description":"Human-readable label"},"required":{"type":"boolean","description":"Whether the field must be mapped before processing"}},"required":["name","label","required"]},"CheckoutRequirement":{"type":"object","properties":{"step":{"type":"string","description":"Checkout step this requirement belongs to"},"field":{"type":"string","description":"Field that needs to be satisfied"},"message":{"type":"string","description":"Human-readable requirement message"}},"required":["step","field","message"]},"CartWarning":{"type":"object","description":"A warning about a cart issue (e.g., item removed due to stock change)","properties":{"code":{"type":"string","description":"Machine-readable warning code"},"message":{"type":"string","description":"Human-readable warning message"},"line_item_id":{"type":"string","nullable":true,"description":"Prefixed line item ID (when applicable)"},"variant_id":{"type":"string","nullable":true,"description":"Prefixed variant ID (when applicable)"},"item_index":{"type":"integer","nullable":true,"description":"Position in the submitted items array, for warnings raised while applying a batch of item changes"}},"required":["code","message"]},"FulfillmentManifestItem":{"type":"object","description":"An item within a fulfillment — which line item and how many units are in this fulfillment","properties":{"item_id":{"type":"string","description":"Line item ID"},"variant_id":{"type":"string","description":"Variant ID"},"quantity":{"type":"integer","description":"Quantity in this fulfillment"}},"required":["item_id","variant_id","quantity"]},"AdminUserRoleAssignment":{"type":"object","description":"A role assignment for the current store on a staff member","properties":{"id":{"type":"string","description":"Prefixed role ID"},"name":{"type":"string","description":"Role name"}},"required":["id","name"]},"AdminUserStore":{"type":"object","description":"A store the staff member can access through a role assignment","properties":{"id":{"type":"string","description":"Prefixed store ID"},"name":{"type":"string","description":"Store name"},"code":{"type":"string","description":"Store code"}},"required":["id","name","code"]},"PreferenceSchema":{"type":"object","description":"The JSON Schema (draft 2020-12) of a type's `preferences`: one property per setting, with `format` (`money`, `currency`, `iso-country`, `prefixed-id`, …), `enum`, `default`, `x-spree-secret` for a secret and `x-spree-prefix` for an id list. Unknown keys are refused.","additionalProperties":true},"PromotionActionLineItem":{"type":"object","description":"One row in a `create_line_items` action — the variant added to the order and how many","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["variant_id","quantity"]},"MeResponse":{"type":"object","description":"Current admin user profile and serialized permissions","properties":{"user":{"$ref":"#/components/schemas/AdminUser"},"permissions":{"type":"array","items":{"$ref":"#/components/schemas/PermissionRule"}}},"required":["user","permissions"]},"Actor":{"type":"object","properties":{"id":{"type":"string"},"type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"label":{"type":"string","nullable":true}},"required":["id","type","label"],"x-typelizer":true},"Address":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string","nullable":true},"first_name":{"type":"string","nullable":true},"last_name":{"type":"string","nullable":true},"full_name":{"type":"string"},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"postal_code":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_name":{"type":"string"},"country_code":{"type":"string","enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"state_text":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"quick_checkout":{"type":"boolean"},"is_default_billing":{"type":"boolean"},"is_default_shipping":{"type":"boolean"},"state_name":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"latitude":{"type":"number","nullable":true},"longitude":{"type":"number","nullable":true},"customer_id":{"type":"string","nullable":true},"owner_id":{"type":"string","nullable":true},"owner_type":{"type":"string","nullable":true}},"required":["id","label","first_name","last_name","full_name","address1","address2","postal_code","city","phone","company","country_name","country_code","state_text","state_code","quick_checkout","is_default_billing","is_default_shipping","state_name","metadata","created_at","updated_at","latitude","longitude","customer_id","owner_id","owner_type"],"x-typelizer":true},"AdminUser":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"first_name":{"type":"string","nullable":true},"last_name":{"type":"string","nullable":true},"full_name":{"type":"string","nullable":true},"selected_locale":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"avatar_url":{"type":"string","nullable":true},"roles":{"type":"array","items":{"$ref":"#/components/schemas/AdminUserRoleAssignment"}},"stores":{"type":"array","items":{"$ref":"#/components/schemas/AdminUserStore"}}},"required":["id","email","first_name","last_name","full_name","selected_locale","created_at","updated_at","avatar_url","roles","stores"],"x-typelizer":true},"AllowedOrigin":{"type":"object","properties":{"id":{"type":"string"},"origin":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","origin","created_at","updated_at"],"x-typelizer":true},"ApiKey":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"key_type":{"type":"string","enum":["publishable","secret"]},"token_prefix":{"type":"string","nullable":true},"scopes":{"type":"array","items":{"type":"string"}},"created_at":{"type":"string"},"updated_at":{"type":"string"},"revoked_at":{"type":"string","nullable":true},"last_used_at":{"type":"string","nullable":true},"channel_id":{"type":"string","nullable":true},"plaintext_token":{"type":"string","nullable":true},"created_by_email":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by_label":{"type":"string","nullable":true}},"required":["id","name","key_type","token_prefix","scopes","created_at","updated_at","revoked_at","last_used_at","channel_id","plaintext_token","created_by_email","created_by_type","created_by_label"],"x-typelizer":true},"AppliedPromotion":{"type":"object","properties":{"id":{"type":"string"},"promotion_id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"code":{"type":"string","nullable":true},"amount":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","promotion_id","name","description","code","amount","created_at","updated_at"],"x-typelizer":true},"Cart":{"type":"object","properties":{"id":{"type":"string"},"market_id":{"type":"string","nullable":true},"channel_id":{"type":"string","nullable":true},"preferred_stock_location_id":{"type":"string","nullable":true},"company_id":{"type":"string","nullable":true},"company_name":{"type":"string","nullable":true},"po_number_required":{"type":"boolean"},"po_document_filename":{"type":"string","nullable":true},"po_document_byte_size":{"type":"number","nullable":true},"token":{"type":"string"},"email":{"type":"string","nullable":true},"customer_note":{"type":"string","nullable":true},"po_number":{"type":"string","nullable":true},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"locale":{"type":"string","nullable":true},"total_quantity":{"type":"number"},"warnings":{"type":"array","items":{"$ref":"#/components/schemas/CartWarning"}},"coupon_code":{"type":"string","nullable":true},"item_total":{"type":"string","nullable":true},"adjustment_total":{"type":"string","nullable":true},"discount_total":{"type":"string","nullable":true},"tax_total":{"type":"string","nullable":true},"included_tax_total":{"type":"string","nullable":true},"additional_tax_total":{"type":"string","nullable":true},"total":{"type":"string","nullable":true},"gift_card_total":{"type":"string","nullable":true},"amount_due":{"type":"string","nullable":true},"delivery_total":{"type":"string","nullable":true},"fee_total":{"type":"string","nullable":true},"store_credit_total":{"type":"string","nullable":true},"covered_by_store_credit":{"type":"boolean"},"current_step":{"type":"string"},"completed_steps":{"type":"array","items":{"type":"string"}},"requirements":{"type":"array","items":{"$ref":"#/components/schemas/CheckoutRequirement"}},"order_minimum":{"type":"string","nullable":true},"order_minimum_shortfall":{"type":"string","nullable":true},"below_order_minimum":{"type":"boolean","nullable":true},"freight_summary":{"allOf":[{"$ref":"#/components/schemas/FreightSummary"}],"nullable":true},"shipping_eq_billing_address":{"type":"boolean"},"items":{"type":"array","items":{"$ref":"#/components/schemas/LineItem"}},"billing_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"shipping_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"market":{"allOf":[{"$ref":"#/components/schemas/Market"}],"nullable":true},"completed_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"applied_promotions":{"type":"array","items":{"$ref":"#/components/schemas/AppliedPromotion"}}},"required":["id","market_id","channel_id","preferred_stock_location_id","company_id","company_name","po_number_required","po_document_filename","po_document_byte_size","token","email","customer_note","po_number","currency","locale","total_quantity","warnings","coupon_code","item_total","adjustment_total","discount_total","tax_total","included_tax_total","additional_tax_total","total","gift_card_total","amount_due","delivery_total","fee_total","store_credit_total","covered_by_store_credit","current_step","completed_steps","requirements","order_minimum","order_minimum_shortfall","below_order_minimum","freight_summary","shipping_eq_billing_address","items","billing_address","shipping_address","market","completed_at","created_at","updated_at","applied_promotions"],"x-typelizer":true},"CatalogAssignment":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"catalog_id":{"type":"string"},"assignable_type":{"type":"string"},"assignable_id":{"type":"string"},"assignable_name":{"type":"string","nullable":true}},"required":["id","created_at","catalog_id","assignable_type","assignable_id","assignable_name"],"x-typelizer":true},"CatalogOrderMinimum":{"type":"object","properties":{"id":{"type":"string"},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount":{"type":"string"}},"required":["id","currency","created_at","updated_at","amount"],"x-typelizer":true},"CatalogPrice":{"type":"object","properties":{"id":{"type":"string","nullable":true},"label":{"type":"string","nullable":true},"sku":{"type":"string","nullable":true},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"source":{"type":"string","enum":["explicit","automatic","base"]},"break_count":{"type":"number"},"amount":{"type":"string"},"tiers":{"type":"array","items":{"$ref":"#/components/schemas/CatalogPriceTier"}}},"required":["id","label","sku","currency","source","break_count","amount","tiers"],"x-typelizer":true},"CatalogPriceTier":{"type":"object","properties":{"min_quantity":{"type":"number"},"amount":{"type":"string"}},"required":["min_quantity","amount"],"x-typelizer":true},"CatalogProduct":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"thumbnail_url":{"type":"string","nullable":true},"quantity_rule":{"allOf":[{"$ref":"#/components/schemas/CatalogProductTerm"}],"nullable":true},"catalog_variants":{"type":"array","items":{"$ref":"#/components/schemas/CatalogPrice"}}},"required":["id","name","thumbnail_url"],"x-typelizer":true},"CatalogProductTerm":{"type":"object","properties":{"id":{"type":"string"},"product_id":{"type":"string"},"product_name":{"type":"string","nullable":true},"minimum_order_quantity":{"type":"number","nullable":true},"order_multiple":{"type":"number","nullable":true},"mixed":{"type":"boolean"}},"required":["id","product_id","product_name","minimum_order_quantity","order_multiple","mixed"],"x-typelizer":true},"CatalogQuantityRule":{"type":"object","properties":{"id":{"type":"string"},"minimum_order_quantity":{"type":"number","nullable":true},"order_multiple":{"type":"number","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"variant_id":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"product_name":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true}},"required":["id","minimum_order_quantity","order_multiple","created_at","updated_at","variant_id","variant_sku","product_name","options_text"],"x-typelizer":true},"Catalog":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"active":{"type":"boolean"},"position":{"type":"number","nullable":true},"metadata":{"type":"object","nullable":true},"minimum_order_quantity":{"type":"number","nullable":true},"order_multiple":{"type":"number","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"products_count":{"type":"number"},"pricing_strategy":{"type":"string"},"order_minimums":{"type":"array","items":{"$ref":"#/components/schemas/CatalogOrderMinimum"}},"price_list":{"$ref":"#/components/schemas/PriceList"},"assignments":{"type":"array","items":{"$ref":"#/components/schemas/CatalogAssignment"}}},"required":["id","name","description","active","position","metadata","minimum_order_quantity","order_multiple","created_at","updated_at","products_count","pricing_strategy"],"x-typelizer":true},"Category":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"permalink":{"type":"string"},"position":{"type":"number"},"depth":{"type":"number"},"meta_title":{"type":"string","nullable":true},"meta_description":{"type":"string","nullable":true},"meta_keywords":{"type":"string","nullable":true},"children_count":{"type":"number"},"parent_id":{"type":"string","nullable":true},"description":{"type":"string"},"description_html":{"type":"string"},"image_url":{"type":"string","nullable":true},"square_image_url":{"type":"string","nullable":true},"is_root":{"type":"boolean"},"is_child":{"type":"boolean"},"is_leaf":{"type":"boolean"},"parent":{"$ref":"#/components/schemas/Category"},"children":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"ancestors":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"external_references":{"type":"object"},"translations":{"type":"object"},"metadata":{"type":"object"},"pretty_name":{"type":"string"},"lft":{"type":"number"},"rgt":{"type":"number"},"products_count":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","permalink","position","depth","meta_title","meta_description","meta_keywords","children_count","parent_id","description","description_html","image_url","square_image_url","is_root","is_child","is_leaf","external_references","metadata","pretty_name","lft","rgt","products_count","created_at","updated_at"],"x-typelizer":true},"Channel":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"code":{"type":"string"},"active":{"type":"boolean"},"default":{"type":"boolean"},"storefront_access":{"type":"string","nullable":true,"enum":["public","prices_hidden","login_required"]},"guest_checkout":{"type":"boolean","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"order_routing_strategy":{"type":"string","nullable":true,"description":"Order routing strategy; null inherits the store setting. Built-in: rules. Extensions may register more."},"stock_location_ids":{"type":"array","items":{"type":"string"}},"default_catalog_id":{"type":"string","nullable":true}},"required":["id","name","code","active","default","storefront_access","guest_checkout","created_at","updated_at","order_routing_strategy","stock_location_ids","default_catalog_id"],"x-typelizer":true},"ClaimLineItem":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"send_replacement":{"type":"boolean"},"description":{"type":"string","nullable":true},"refund_amount":{"type":"string"},"paid_amount":{"type":"string"},"pre_tax_amount":{"type":"string"},"included_tax_total":{"type":"string"},"additional_tax_total":{"type":"string"},"tax_total":{"type":"string"},"variant_id":{"type":"string","nullable":true},"replacement_variant_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"variant":{"$ref":"#/components/schemas/Variant"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"replacement_variant":{"$ref":"#/components/schemas/Variant"}},"required":["id","quantity","send_replacement","description","refund_amount","paid_amount","pre_tax_amount","included_tax_total","additional_tax_total","tax_total","variant_id","replacement_variant_id","line_item_id","created_at","updated_at"],"x-typelizer":true},"ClaimReason":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"can_be_deleted":{"type":"boolean"}},"required":["id","name","active","created_at","updated_at","can_be_deleted"],"x-typelizer":true},"Claim":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["open","approved","resolved","denied","canceled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"resolution":{"type":"string","nullable":true},"order_id":{"type":"string","nullable":true},"reason_id":{"type":"string","nullable":true},"refund_total":{"type":"string"},"approved_at":{"type":"string","nullable":true},"resolved_at":{"type":"string","nullable":true},"denied_at":{"type":"string","nullable":true},"canceled_at":{"type":"string","nullable":true},"reason":{"$ref":"#/components/schemas/ClaimReason"},"claim_line_items":{"type":"array","items":{"$ref":"#/components/schemas/ClaimLineItem"}},"memo":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"created_by_id":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by":{"$ref":"#/components/schemas/Actor"},"order":{"$ref":"#/components/schemas/Order"},"refunds":{"type":"array","items":{"$ref":"#/components/schemas/Refund"}}},"required":["id","number","status","resolution","order_id","reason_id","refund_total","approved_at","resolved_at","denied_at","canceled_at","memo","metadata","created_at","updated_at","created_by_id","created_by_type"],"x-typelizer":true},"CollectionRule":{"type":"object","properties":{"id":{"type":"string"},"value":{"type":"string","nullable":true},"match_policy":{"type":"string","enum":["is_equal_to","is_not_equal_to","contains","does_not_contain"]},"type":{"type":"string","description":"Rule type. Built-in: tag, available_on, sale. Extensions may register more."}},"required":["id","value","match_policy","type"],"x-typelizer":true},"Collection":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"permalink":{"type":"string"},"position":{"type":"number"},"sort_order":{"type":"string"},"meta_title":{"type":"string","nullable":true},"meta_description":{"type":"string","nullable":true},"meta_keywords":{"type":"string","nullable":true},"products_count":{"type":"number"},"description":{"type":"string"},"description_html":{"type":"string"},"image_url":{"type":"string","nullable":true},"square_image_url":{"type":"string","nullable":true},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"translations":{"type":"object"},"automatic":{"type":"boolean"},"rules_match_policy":{"type":"string","enum":["all","any"]},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CollectionRule"}}},"required":["id","name","permalink","position","sort_order","meta_title","meta_description","meta_keywords","products_count","description","description_html","image_url","square_image_url","automatic","rules_match_policy","metadata","created_at","updated_at"],"x-typelizer":true},"CommissionLine":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["percentage","fixed"]},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"taxability_reason":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true,"enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"state_code":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"rate":{"type":"string"},"tax_rate":{"type":"string"},"amount":{"type":"string"},"tax_amount":{"type":"string"},"total":{"type":"string"},"order_id":{"type":"string"},"seller_id":{"type":"string"},"line_item_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"commission_rate_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"commission_rate":{"$ref":"#/components/schemas/CommissionRate"}},"required":["id","kind","currency","taxability_reason","country_code","state_code","created_at","updated_at","rate","tax_rate","amount","tax_amount","total","order_id","seller_id","line_item_id","fulfillment_id","commission_rate_id","seller_name"],"x-typelizer":true},"CommissionRate":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"code":{"type":"string","nullable":true},"enabled":{"type":"boolean"},"position":{"type":"number"},"kind":{"type":"string","enum":["percentage","fixed"]},"tax_inclusive":{"type":"boolean"},"include_shipping":{"type":"boolean"},"metadata":{"type":"object","nullable":true},"deleted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"value":{"type":"string"},"commission_tax_rate":{"type":"string","nullable":true},"amounts":{"type":"object"},"bounds":{"type":"object"},"global":{"type":"boolean"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CommissionRule"}}},"required":["id","name","code","enabled","position","kind","tax_inclusive","include_shipping","metadata","deleted_at","created_at","updated_at","value","commission_tax_rate","amounts","bounds","global","rules"],"x-typelizer":true},"CommissionRule":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: seller_rule, category_rule, product_rule, item_total_rule. Extensions may register more."},"commission_rate_id":{"type":"string"},"preferences":{"$ref":"#/components/schemas/CommissionRulePreferences"},"product_ids":{"type":"array","items":{"type":"string"},"nullable":true},"seller_ids":{"type":"array","items":{"type":"string"},"nullable":true},"category_ids":{"type":"array","items":{"type":"string"},"nullable":true},"sellers":{"type":"array","items":{"$ref":"#/components/schemas/Seller"}},"categories":{"type":"array","items":{"$ref":"#/components/schemas/Category"}}},"required":["id","created_at","updated_at","type","commission_rate_id","preferences","product_ids","seller_ids","category_ids"],"x-typelizer":true},"CompanyInvitation":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"expires_at":{"type":"string","nullable":true},"company_id":{"type":"string"},"status":{"type":"string","enum":["pending","accepted","revoked","expired"]},"accepted_at":{"type":"string","nullable":true},"revoked_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","email","expires_at","company_id","status","accepted_at","revoked_at","created_at","updated_at"],"x-typelizer":true},"CompanyMembership":{"type":"object","properties":{"id":{"type":"string"},"company_id":{"type":"string"},"customer_id":{"type":"string"},"email":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","company_id","customer_id","email","created_at","updated_at"],"x-typelizer":true},"Company":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"kind":{"type":"string","enum":["company","division"]},"po_number_required":{"type":"boolean"},"parent_id":{"type":"string","nullable":true},"ancestors":{"type":"array","items":{"type":"object"}},"external_references":{"type":"object"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"children_count":{"type":"number"},"members_count":{"type":"number"},"children":{"type":"array","items":{"$ref":"#/components/schemas/Company"}},"addresses":{"type":"array","items":{"$ref":"#/components/schemas/Address"}},"memberships":{"type":"array","items":{"$ref":"#/components/schemas/CompanyMembership"}}},"required":["id","name","kind","po_number_required","parent_id","ancestors","external_references","metadata","created_at","updated_at","children_count","members_count"],"x-typelizer":true},"ConsentRecord":{"type":"object","properties":{"id":{"type":"string"},"purpose":{"type":"string"},"source":{"type":"string","enum":["checkout","registration","account","admin","newsletter","anonymization","unknown","import","storefront"]},"accepted":{"type":"boolean"},"email":{"type":"string","nullable":true},"ip_address":{"type":"string","nullable":true},"created_at":{"type":"string"},"recorded_at":{"type":"string","nullable":true},"documents":{"type":"array","items":{"type":"object"}}},"required":["id","purpose","source","accepted","email","ip_address","created_at","recorded_at","documents"],"x-typelizer":true},"Country":{"type":"object","properties":{"iso":{"type":"string"},"iso3":{"type":"string"},"name":{"type":"string"},"states_required":{"type":"boolean"},"zipcode_required":{"type":"boolean"},"states":{"type":"array","items":{"$ref":"#/components/schemas/State"}},"market":{"allOf":[{"$ref":"#/components/schemas/Market"}],"nullable":true}},"required":["iso","iso3","name","states_required","zipcode_required"],"x-typelizer":true},"CouponCode":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"state":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"promotion_id":{"type":"string"},"order_id":{"type":"string","nullable":true}},"required":["id","code","state","created_at","updated_at","promotion_id","order_id"],"x-typelizer":true},"CreditCard":{"type":"object","properties":{"id":{"type":"string"},"brand":{"type":"string"},"last4":{"type":"string"},"month":{"type":"number"},"year":{"type":"number"},"name":{"type":"string","nullable":true},"default":{"type":"boolean"},"gateway_payment_profile_id":{"type":"string","nullable":true},"customer_id":{"type":"string","nullable":true},"payment_method_id":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","brand","last4","month","year","name","default","gateway_payment_profile_id","customer_id","payment_method_id","metadata","created_at","updated_at"],"x-typelizer":true},"CustomFieldDefinition":{"type":"object","properties":{"id":{"type":"string"},"namespace":{"type":"string"},"key":{"type":"string"},"label":{"type":"string"},"field_type":{"type":"string","enum":["short_text","long_text","rich_text","number","boolean","json"]},"storefront_visible":{"type":"boolean"},"searchable":{"type":"boolean"},"sortable":{"type":"boolean"},"filter_key":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"resource_type":{"type":"string","description":"Shorthand of the resource the field attaches to, for example product, variant, order, customer or category. Discover the full list from the resource_types endpoint; extensions may register more."}},"required":["id","namespace","key","label","field_type","storefront_visible","searchable","sortable","filter_key","created_at","updated_at","resource_type"],"x-typelizer":true},"CustomField":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"field_type":{"type":"string","enum":["short_text","long_text","rich_text","number","boolean","json"]},"key":{"type":"string"},"value":{},"created_at":{"type":"string"},"updated_at":{"type":"string"},"storefront_visible":{"type":"boolean"},"custom_field_definition_id":{"type":"string"}},"required":["id","label","field_type","key","value","created_at","updated_at","storefront_visible","custom_field_definition_id"],"x-typelizer":true},"CustomerGroup":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"customers_count":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"customers":{"type":"array","items":{"$ref":"#/components/schemas/Customer"}}},"required":["id","name","description","customers_count","created_at","updated_at"],"x-typelizer":true},"Customer":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"first_name":{"type":"string","nullable":true},"last_name":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"accepts_email_marketing":{"type":"boolean"},"email_marketing_consent_updated_at":{"type":"string","nullable":true},"full_name":{"type":"string"},"available_store_credit_total":{"type":"string"},"addresses":{"type":"array","items":{"$ref":"#/components/schemas/Address"}},"default_billing_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"default_shipping_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"newsletter_subscriber":{"allOf":[{"$ref":"#/components/schemas/NewsletterSubscriber"}],"nullable":true},"customer_groups":{"type":"array","items":{"$ref":"#/components/schemas/CustomerGroup"}},"failed_attempts":{"type":"number"},"metadata":{"type":"object"},"email_marketing_consent_source":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"anonymized_at":{"type":"string","nullable":true},"anonymized":{"type":"boolean"},"tags":{"type":"array","items":{"type":"string"}},"internal_note":{"type":"string","nullable":true},"internal_note_html":{"type":"string","nullable":true},"default_billing_address_id":{"type":"string","nullable":true},"default_shipping_address_id":{"type":"string","nullable":true},"orders_count":{"type":"number"},"total_spent":{"type":"string"},"last_order_completed_at":{"type":"string","nullable":true},"orders":{"type":"array","items":{"$ref":"#/components/schemas/Order"}},"store_credits":{"type":"array","items":{"$ref":"#/components/schemas/StoreCredit"}},"customer_group_ids":{"type":"array","items":{"type":"string"}},"companies":{"type":"array","items":{"$ref":"#/components/schemas/Company"}}},"required":["id","email","first_name","last_name","phone","accepts_email_marketing","email_marketing_consent_updated_at","full_name","available_store_credit_total","failed_attempts","metadata","email_marketing_consent_source","created_at","updated_at","anonymized_at","anonymized","tags","internal_note","internal_note_html","default_billing_address_id","default_shipping_address_id","orders_count","total_spent","last_order_completed_at","customer_group_ids"],"x-typelizer":true},"DashboardCounter":{"type":"object","properties":{"key":{"type":"string","description":"Registered counter name. The dashboard translates it; built-in: orders_to_fulfill, payments_to_collect, open_returns, open_exchanges, open_claims, low_stock_items, out_of_stock_items."},"value":{"type":"number"},"link":{"type":"object","nullable":true,"description":"The list filter that shows exactly the rows counted, or null when no list can."},"nav":{"type":"string","nullable":true,"description":"Sidebar entry key this count badges, or null."}},"required":["key","value","link","nav"],"x-typelizer":true},"DataRequest":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"kind":{"type":"string","enum":["access","erasure"]},"status":{"anyOf":[{"type":"string","enum":["pending","processing","completed","failed"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"requested_at":{"type":"string","nullable":true},"completed_at":{"type":"string","nullable":true},"expires_at":{"type":"string","nullable":true},"email":{"type":"string"},"error_message":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"customer_id":{"type":"string","nullable":true},"requested_by_id":{"type":"string","nullable":true},"customer":{"$ref":"#/components/schemas/Customer"}},"required":["id","number","kind","status","requested_at","completed_at","expires_at","email","error_message","created_at","updated_at","customer_id","requested_by_id"],"x-typelizer":true},"DeliveryMethodRule":{"type":"object","properties":{"id":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: item_total_rule, weight_rule, excluded_products_rule, channel_rule, volume_rule, company_rule. Extensions may register more."},"preferences":{"$ref":"#/components/schemas/DeliveryMethodRulePreferences"},"product_ids":{"type":"array","items":{"type":"string"}}},"required":["id","active","created_at","updated_at","type","preferences","product_ids"],"x-typelizer":true},"DeliveryMethod":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"code":{"type":"string","nullable":true},"estimated_transit_business_days_min":{"type":"number","nullable":true},"estimated_transit_business_days_max":{"type":"number","nullable":true},"digital":{"type":"boolean"},"pickup":{"type":"boolean"},"pickup_point":{"type":"boolean"},"admin_name":{"type":"string","nullable":true},"storefront_visible":{"type":"boolean"},"tracking_url":{"type":"string","nullable":true},"available_to_sellers":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"deleted_at":{"type":"string"},"markup_flat":{"type":"string","nullable":true},"markup_percent":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"services":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryMethodService"}},"rules":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryMethodRule"}},"tax_category_id":{"type":"string","nullable":true},"delivery_profile_id":{"type":"string"},"delivery_origin_group_id":{"type":"string","nullable":true},"delivery_zone_id":{"type":"string","nullable":true},"stock_location_ids":{"type":"array","items":{"type":"string"}},"fulfillment_provider":{"type":"string","description":"Fulfillment provider. Built-in: manual, digital, pickup, pickup_point. Provider gems register more (e.g. easy_post)."},"pickup_point_provider":{"type":"string","nullable":true,"description":"Pickup point network. None built in; provider gems register them."},"rate_provider":{"type":"string","nullable":true,"description":"Rate provider; null prices through the calculator. Built-in: internal, freight. Provider gems register more (e.g. easy_post)."},"calculator":{"allOf":[{"$ref":"#/components/schemas/DeliveryMethodCalculator"}],"nullable":true}},"required":["id","name","code","estimated_transit_business_days_min","estimated_transit_business_days_max","digital","pickup","pickup_point","admin_name","storefront_visible","tracking_url","available_to_sellers","created_at","updated_at","deleted_at","markup_flat","markup_percent","seller_id","seller_name","services","rules","tax_category_id","delivery_profile_id","delivery_origin_group_id","delivery_zone_id","stock_location_ids","fulfillment_provider","pickup_point_provider","rate_provider","calculator"],"x-typelizer":true},"DeliveryMethodService":{"type":"object","properties":{"id":{"type":"string"},"carrier":{"type":"string"},"service":{"type":"string"},"label":{"type":"string","nullable":true},"markup_flat":{"type":"string","nullable":true},"markup_percent":{"type":"string","nullable":true},"position":{"type":"number"}},"required":["id","carrier","service","label","markup_flat","markup_percent","position"],"x-typelizer":true},"DeliveryOriginGroup":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string","nullable":true},"position":{"type":"number","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivery_profile_id":{"type":"string"},"stock_location_ids":{"type":"array","items":{"type":"string"}},"delivery_zones_count":{"type":"number"},"delivery_methods_count":{"type":"number"}},"required":["id","name","position","created_at","updated_at","delivery_profile_id","stock_location_ids","delivery_zones_count","delivery_methods_count"],"x-typelizer":true},"DeliveryProfile":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"default":{"type":"boolean"},"position":{"type":"number","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"kind":{"type":"string","description":"Profile kind. Built-in: shipping, digital. Extensions may register more."},"digital":{"type":"boolean"},"offers_pickup":{"type":"boolean"},"offers_shipping":{"type":"boolean"},"stock_location_ids":{"type":"array","items":{"type":"string"}},"origin_groups":{"type":"array","items":{"type":"object"}},"products_count":{"type":"number"},"delivery_methods_count":{"type":"number"},"delivery_zones_count":{"type":"number"}},"required":["id","name","default","position","created_at","updated_at","kind","digital","offers_pickup","offers_shipping","stock_location_ids","origin_groups","products_count","delivery_methods_count","delivery_zones_count"],"x-typelizer":true},"DeliveryRate":{"type":"object","properties":{"id":{"type":"string"},"delivery_method_id":{"type":"string"},"name":{"type":"string"},"selected":{"type":"boolean"},"cost":{"type":"string"},"total":{"type":"string"},"additional_tax_total":{"type":"string"},"included_tax_total":{"type":"string"},"tax_total":{"type":"string"},"carrier":{"type":"string","nullable":true},"service_level":{"type":"string","nullable":true},"estimated_delivery_date":{"type":"string","nullable":true},"unpriced":{"type":"boolean"},"freight_summary":{"allOf":[{"$ref":"#/components/schemas/FreightSummary"}],"nullable":true},"delivery_method":{"$ref":"#/components/schemas/DeliveryMethod"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","delivery_method_id","name","selected","cost","total","additional_tax_total","included_tax_total","tax_total","carrier","service_level","estimated_delivery_date","unpriced","freight_summary","metadata","created_at","updated_at"],"x-typelizer":true},"Delivery":{"type":"object","properties":{"id":{"type":"string"},"tracking_number":{"type":"string"},"carrier":{"type":"string","nullable":true},"carrier_name":{"type":"string","nullable":true},"service":{"type":"string","nullable":true},"status":{"type":"string","enum":["pending","pre_transit","in_transit","out_for_delivery","available_for_pickup","delivered","return_to_sender","failure","unknown"]},"tracking_url":{"type":"string","nullable":true},"estimated_delivery_at":{"type":"string","nullable":true},"delivered_at":{"type":"string","nullable":true},"details":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"shipping_label_id":{"type":"string","nullable":true}},"required":["id","tracking_number","carrier","carrier_name","service","status","tracking_url","estimated_delivery_at","delivered_at","details","created_at","updated_at","shipping_label_id"],"x-typelizer":true},"DeliveryZoneMember":{"type":"object","properties":{"id":{"type":"string"},"member_type":{"type":"string","enum":["country","state","postal_code"]},"country_code":{"type":"string","nullable":true,"enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"state_code":{"type":"string","nullable":true},"postal_code_prefix":{"type":"string","nullable":true},"postal_code_from":{"type":"string","nullable":true},"postal_code_to":{"type":"string","nullable":true},"country_name":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","member_type","country_code","state_code","postal_code_prefix","postal_code_from","postal_code_to","country_name","state_name","created_at","updated_at"],"x-typelizer":true},"DeliveryZone":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"members":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryZoneMember"}},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivery_profile_id":{"type":"string"},"delivery_origin_group_id":{"type":"string","nullable":true},"delivery_method_ids":{"type":"array","items":{"type":"string"}}},"required":["id","name","description","created_at","updated_at","delivery_profile_id","delivery_origin_group_id","delivery_method_ids"],"x-typelizer":true},"DigitalAsset":{"type":"object","properties":{"id":{"type":"string"},"variant_id":{"type":"string","nullable":true},"filename":{"type":"string","nullable":true},"content_type":{"type":"string","nullable":true},"authorized_clicks":{"type":"number","nullable":true},"authorized_days":{"type":"number","nullable":true},"byte_size":{"type":"number","nullable":true},"provider_settings":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"provider_type":{"type":"string","nullable":true,"description":"Digital asset provider; null is an uploaded file. Built-in: file. Extensions may register more."},"provider_name":{"type":"string","description":"Digital asset provider name. Built-in: File. Extensions may register more."},"download_url":{"type":"string","nullable":true},"effective_authorized_clicks":{"type":"number"},"effective_authorized_days":{"type":"number"}},"required":["id","variant_id","filename","content_type","authorized_clicks","authorized_days","byte_size","provider_settings","created_at","updated_at","provider_type","provider_name","download_url","effective_authorized_clicks","effective_authorized_days"],"x-typelizer":true},"DigitalLink":{"type":"object","properties":{"id":{"type":"string"},"access_counter":{"type":"number"},"filename":{"type":"string"},"content_type":{"type":"string"},"download_url":{"type":"string"},"expires_at":{"type":"string","nullable":true},"authorizable":{"type":"boolean"},"expired":{"type":"boolean"},"access_limit_exceeded":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","access_counter","filename","content_type","download_url","expires_at","authorizable","expired","access_limit_exceeded","created_at","updated_at"],"x-typelizer":true},"Discount":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"kind":{"type":"string","enum":["promotion","manual"]},"code":{"type":"string","nullable":true},"value_type":{"type":"string","nullable":true},"value":{"type":"string","nullable":true},"promotion_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"amount":{"type":"string"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","label","kind","code","value_type","value","promotion_id","line_item_id","fulfillment_id","amount","metadata","created_at","updated_at"],"x-typelizer":true},"EmailTemplateDraft":{"type":"object","properties":{"id":{"type":"string"},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"lock_version":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"updated_by_id":{"type":"string","nullable":true},"updated_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"updated_by":{"$ref":"#/components/schemas/Actor"}},"required":["id","subject","body","lock_version","created_at","updated_at","updated_by_id","updated_by_type"],"x-typelizer":true},"EmailTemplatePreview":{"type":"object","properties":{"id":{"type":"string","nullable":true},"subject":{"type":"string"},"html":{"type":"string"},"text":{"type":"string"},"email_key":{"type":"string"},"variables":{"type":"object"}},"required":["id","subject","html","text","email_key","variables"],"x-typelizer":true},"EmailTemplateRevision":{"type":"object","properties":{"id":{"type":"string"},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"created_at":{"type":"string"},"published_by_id":{"type":"string","nullable":true},"published_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"published_by":{"$ref":"#/components/schemas/Actor"}},"required":["id","subject","body","created_at","published_by_id","published_by_type"],"x-typelizer":true},"EmailTemplateSampleRecord":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"created_at":{"type":"string"}},"required":["id","label","created_at"],"x-typelizer":true},"EmailTemplate":{"type":"object","properties":{"id":{"type":"string"},"key":{"type":"string"},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"language":{"type":"string"},"customized_languages":{"type":"array","items":{"type":"string"}},"kind":{"type":"string","enum":["email","layout","partial"]},"customized":{"type":"boolean"},"published_at":{"type":"string","nullable":true},"default_subject":{"type":"string","nullable":true},"default_body":{"type":"string"},"published_language":{"type":"string","nullable":true},"default_changed":{"type":"boolean"},"base_subject":{"type":"string","nullable":true},"base_body":{"type":"string","nullable":true},"draft":{"allOf":[{"$ref":"#/components/schemas/EmailTemplateDraft"}],"nullable":true}},"required":["id","key","subject","body","language","customized_languages","kind","customized","published_at","default_subject","default_body","published_language","default_changed","base_subject","base_body","draft"],"x-typelizer":true},"ExchangeLineItem":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"received_quantity":{"type":"number"},"resellable":{"type":"boolean"},"original_price":{"type":"string"},"new_variant_price":{"type":"string"},"price_difference":{"type":"string"},"original_tax_total":{"type":"string"},"new_tax_total":{"type":"string"},"original_variant_id":{"type":"string","nullable":true},"new_variant_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"fulfillment_item_id":{"type":"string","nullable":true},"original_variant":{"$ref":"#/components/schemas/Variant"},"new_variant":{"$ref":"#/components/schemas/Variant"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","quantity","received_quantity","resellable","original_price","new_variant_price","price_difference","original_tax_total","new_tax_total","original_variant_id","new_variant_id","line_item_id","fulfillment_item_id","created_at","updated_at"],"x-typelizer":true},"Exchange":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["requested","approved","received","fulfilled","canceled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"order_id":{"type":"string","nullable":true},"reason_id":{"type":"string","nullable":true},"price_difference":{"type":"string"},"approved_at":{"type":"string","nullable":true},"received_at":{"type":"string","nullable":true},"fulfilled_at":{"type":"string","nullable":true},"canceled_at":{"type":"string","nullable":true},"reason":{"$ref":"#/components/schemas/ReturnReason"},"exchange_line_items":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeLineItem"}},"memo":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_location_id":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by":{"$ref":"#/components/schemas/Actor"},"order":{"$ref":"#/components/schemas/Order"},"stock_location":{"$ref":"#/components/schemas/StockLocation"},"refunds":{"type":"array","items":{"$ref":"#/components/schemas/Refund"}}},"required":["id","number","status","order_id","reason_id","price_difference","approved_at","received_at","fulfilled_at","canceled_at","memo","metadata","created_at","updated_at","stock_location_id","created_by_id","created_by_type"],"x-typelizer":true},"Export":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"format":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","nullable":true},"user_id":{"type":"string","nullable":true},"done":{"type":"boolean"},"store_id":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"filename":{"type":"string","nullable":true},"byte_size":{"type":"number","nullable":true},"download_url":{"type":"string","nullable":true}},"required":["id","number","format","created_at","updated_at","type","user_id","done","store_id","seller_id","seller_name","filename","byte_size","download_url"],"x-typelizer":true},"Fee":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"kind":{"anyOf":[{"type":"string","enum":["surcharge","handling","gift_wrap","cod","payment","duty","exchange"]},{"type":"string"}],"description":"What sort of charge this is. `duty` is a customs duty on a cross-border order and is not taxed; the other kinds are. Extensions may register further kinds."},"line_item_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"amount":{"type":"string"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","label","kind","line_item_id","fulfillment_id","amount","metadata","created_at","updated_at"],"x-typelizer":true},"FileUpload":{"type":"object","properties":{"signed_id":{"type":"string"},"filename":{"type":"string"},"content_type":{"type":"string"},"byte_size":{"type":"number"},"visibility":{"type":"string","enum":["public","private"]},"expires_at":{"type":"string"},"upload":{"allOf":[{"$ref":"#/components/schemas/FileUploadTarget"}],"nullable":true}},"required":["signed_id","filename","content_type","byte_size","visibility","expires_at","upload"],"x-typelizer":true},"FileUploadTarget":{"type":"object","properties":{"method":{"type":"string"},"url":{"type":"string"},"headers":{"type":"object"}},"required":["method","url","headers"],"x-typelizer":true},"FreightSummaryLine":{"type":"object","properties":{"variant_id":{"type":"string","nullable":true},"sku":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"units":{"type":"number"},"cartons":{"type":"number","nullable":true},"pallets":{"type":"number","nullable":true},"units_per_carton":{"type":"number","nullable":true},"cartons_per_pallet":{"type":"number","nullable":true},"complete":{"type":"boolean"},"weight_per_carton":{"type":"string","nullable":true},"volume":{"type":"string"},"weight":{"type":"string"}},"required":["variant_id","sku","name","units","cartons","pallets","units_per_carton","cartons_per_pallet","complete","weight_per_carton","volume","weight"],"x-typelizer":true},"FreightSummary":{"type":"object","properties":{"total_units":{"type":"number"},"total_cartons":{"type":"number"},"total_pallets":{"type":"number","nullable":true},"total_volume":{"type":"string"},"total_weight":{"type":"string"},"complete":{"type":"boolean"},"lines":{"type":"array","items":{"$ref":"#/components/schemas/FreightSummaryLine"}}},"required":["total_units","total_cartons","total_pallets","total_volume","total_weight","complete","lines"],"x-typelizer":true},"FulfillmentItem":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"status":{"anyOf":[{"type":"string","enum":["on_hand","backordered","shipped","returned"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"variant_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"name":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true}},"required":["id","quantity","status","variant_id","line_item_id","name","options_text"],"x-typelizer":true},"Fulfillment":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"tracking":{"type":"string","nullable":true},"tracking_url":{"type":"string","nullable":true},"pickup_point_data":{"type":"object","nullable":true},"selected_delivery_rate_id":{"type":"string","nullable":true},"unpriced":{"type":"boolean"},"cost":{"type":"string"},"total":{"type":"string"},"discount_total":{"type":"string"},"additional_tax_total":{"type":"string"},"included_tax_total":{"type":"string"},"tax_total":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["unfulfilled","fulfilled","delivered","canceled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"fulfillment_type":{"type":"string","enum":["shipping","digital","pickup","pickup_point"]},"fulfilled_at":{"type":"string","nullable":true},"delivered_at":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/FulfillmentManifestItem"}},"deliveries":{"type":"array","items":{"$ref":"#/components/schemas/Delivery"}},"delivery_method":{"$ref":"#/components/schemas/DeliveryMethod"},"stock_location":{"$ref":"#/components/schemas/StockLocation"},"delivery_rates":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryRate"}},"tax_lines":{"type":"array","items":{"$ref":"#/components/schemas/TaxLine"}},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"adjustment_total":{"type":"string"},"pre_tax_amount":{"type":"string"},"order_id":{"type":"string","nullable":true},"stock_location_id":{"type":"string","nullable":true},"documents":{"type":"array","items":{"type":"object"}},"labels":{"type":"array","items":{"$ref":"#/components/schemas/ShippingLabel"}},"provider_generates_labels":{"type":"boolean"},"fulfillment_items":{"type":"array","items":{"$ref":"#/components/schemas/FulfillmentItem"}},"order":{"$ref":"#/components/schemas/Order"}},"required":["id","number","tracking","tracking_url","pickup_point_data","selected_delivery_rate_id","unpriced","cost","total","discount_total","additional_tax_total","included_tax_total","tax_total","status","fulfillment_type","fulfilled_at","delivered_at","items","deliveries","metadata","created_at","updated_at","adjustment_total","pre_tax_amount","order_id","stock_location_id","documents","labels","provider_generates_labels"],"x-typelizer":true},"GiftCardBatch":{"type":"object","properties":{"id":{"type":"string"},"codes_count":{"type":"number"},"currency":{"type":"string","nullable":true,"enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"prefix":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount":{"type":"string","nullable":true},"expires_at":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true}},"required":["id","codes_count","currency","prefix","created_at","updated_at","amount","expires_at","created_by_id"],"x-typelizer":true},"GiftCard":{"type":"object","properties":{"id":{"type":"string"},"code":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["active","partially_redeemed","redeemed","canceled","expired"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"amount":{"type":"string"},"amount_used":{"type":"string"},"amount_authorized":{"type":"string"},"amount_remaining":{"type":"string"},"expires_at":{"type":"string","nullable":true},"redeemed_at":{"type":"string","nullable":true},"expired":{"type":"boolean"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"customer_id":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true},"customer":{"$ref":"#/components/schemas/Customer"},"created_by":{"$ref":"#/components/schemas/AdminUser"},"gift_card_batch":{"$ref":"#/components/schemas/GiftCardBatch"},"orders":{"type":"array","items":{"$ref":"#/components/schemas/Order"}}},"required":["id","code","status","currency","amount","amount_used","amount_authorized","amount_remaining","expires_at","redeemed_at","expired","active","created_at","updated_at","customer_id","created_by_id"],"x-typelizer":true},"ImportMapping":{"type":"object","properties":{"id":{"type":"string"},"schema_field":{"type":"string"},"file_column":{"type":"string","nullable":true},"required":{"type":"boolean"}},"required":["id","schema_field","file_column","required"],"x-typelizer":true},"ImportRow":{"type":"object","properties":{"id":{"type":"string"},"row_number":{"type":"number"},"status":{"anyOf":[{"type":"string","enum":["pending","processing","completed","failed"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"validation_errors":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"import_id":{"type":"string","nullable":true},"item_type":{"type":"string","nullable":true},"item_id":{"type":"string","nullable":true},"data":{"type":"object"}},"required":["id","row_number","status","validation_errors","created_at","updated_at","import_id","item_type","item_id","data"],"x-typelizer":true},"Import":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"rows_count":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","nullable":true,"description":"Import type. Built-in: products, product_translations, customers, price_list_prices. Extensions may register more."},"status":{"anyOf":[{"type":"string","enum":["pending","mapping","completed_mapping","processing","completed","failed"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"store_id":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"user_id":{"type":"string","nullable":true},"processing_errors":{"type":"string","nullable":true},"delimiter":{"type":"string"},"price_list_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"original_filename":{"type":"string","nullable":true},"original_byte_size":{"type":"number","nullable":true},"original_file_url":{"type":"string","nullable":true},"completed_rows_count":{"type":"number"},"failed_rows_count":{"type":"number"},"schema_fields":{"type":"array","items":{"$ref":"#/components/schemas/ImportSchemaField"}},"csv_headers":{"type":"array","items":{"type":"string"}},"sample_row":{"type":"object"},"mappings":{"type":"array","items":{"$ref":"#/components/schemas/ImportMapping"}}},"required":["id","number","rows_count","created_at","updated_at","type","status","store_id","seller_id","user_id","processing_errors","delimiter","price_list_id","seller_name","original_filename","original_byte_size","original_file_url","completed_rows_count","failed_rows_count","schema_fields","csv_headers","sample_row","mappings"],"x-typelizer":true},"Integration":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Integration type, registered by the provider gem that owns it (for example the EasyPost provider). Core ships none."},"group":{"type":"string","nullable":true},"preferences":{"$ref":"#/components/schemas/IntegrationPreferences"}},"required":["id","name","active","created_at","updated_at","type","group","preferences"],"x-typelizer":true},"InvitationAcceptanceLink":{"type":"object","properties":{"id":{"type":"string"},"acceptance_url":{"type":"string"}},"required":["id","acceptance_url"],"x-typelizer":true},"Invitation":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","accepted"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"created_at":{"type":"string"},"updated_at":{"type":"string"},"expires_at":{"type":"string"},"role_id":{"type":"string"},"role_name":{"type":"string"},"inviter_email":{"type":"string"},"invitee_exists":{"type":"boolean"},"store":{"type":"object"}},"required":["id","email","status","created_at","updated_at","expires_at","role_id","role_name","inviter_email","invitee_exists","store"],"x-typelizer":true},"LineItem":{"type":"object","properties":{"id":{"type":"string"},"variant_id":{"type":"string"},"seller_id":{"type":"string","nullable":true},"preorder":{"type":"boolean"},"preorder_ships_at":{"type":"string","nullable":true},"quantity":{"type":"number"},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"name":{"type":"string"},"slug":{"type":"string"},"options_text":{"type":"string"},"price":{"type":"string"},"total":{"type":"string"},"adjustment_total":{"type":"string"},"additional_tax_total":{"type":"string"},"included_tax_total":{"type":"string"},"discount_total":{"type":"string"},"pre_tax_amount":{"type":"string"},"discounted_amount":{"type":"string"},"compare_at_amount":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}},"digital_links":{"type":"array","items":{"$ref":"#/components/schemas/DigitalLink"}},"tax_lines":{"type":"array","items":{"$ref":"#/components/schemas/TaxLine"}},"metadata":{"type":"object"},"price_source":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"catalog_price":{"type":"string","nullable":true},"price_list_id":{"type":"string","nullable":true},"price_list_name":{"type":"string","nullable":true},"catalog_id":{"type":"string","nullable":true},"catalog_name":{"type":"string","nullable":true},"cost_price":{"type":"string","nullable":true},"tax_category_id":{"type":"string","nullable":true},"variant":{"$ref":"#/components/schemas/Variant"},"tax_category":{"$ref":"#/components/schemas/TaxCategory"}},"required":["id","variant_id","seller_id","preorder","preorder_ships_at","quantity","currency","name","slug","options_text","price","total","adjustment_total","additional_tax_total","included_tax_total","discount_total","pre_tax_amount","discounted_amount","compare_at_amount","thumbnail_url","option_values","digital_links","metadata","price_source","created_at","updated_at","catalog_price","price_list_id","price_list_name","catalog_id","catalog_name","cost_price","tax_category_id"],"x-typelizer":true},"Market":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"default_locale":{"type":"string"},"tax_inclusive":{"type":"boolean"},"default":{"type":"boolean"},"country_codes":{"type":"array","items":{"type":"string","enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]}},"supported_locales":{"type":"array","items":{"type":"string"}},"countries":{"type":"array","items":{"$ref":"#/components/schemas/Country"}},"created_at":{"type":"string"},"updated_at":{"type":"string"},"tax_provider":{"type":"string","nullable":true,"description":"Tax provider; null uses the store default. Built-in: internal. Provider gems register more."}},"required":["id","name","currency","default_locale","tax_inclusive","default","country_codes","supported_locales","created_at","updated_at","tax_provider"],"x-typelizer":true},"Media":{"type":"object","properties":{"id":{"type":"string"},"product_id":{"type":"string","nullable":true},"variant_ids":{"type":"array","items":{"type":"string"}},"position":{"type":"number"},"alt":{"type":"string","nullable":true},"media_type":{"type":"string","enum":["image","video","external_video"]},"external_video_url":{"type":"string","nullable":true},"focal_point_x":{"type":"number","nullable":true},"focal_point_y":{"type":"number","nullable":true},"video_provider":{"type":"string","nullable":true},"video_embed_url":{"type":"string","nullable":true},"video_url":{"type":"string","nullable":true},"poster_url":{"type":"string","nullable":true},"original_url":{"type":"string","nullable":true},"mini_url":{"type":"string","nullable":true},"small_url":{"type":"string","nullable":true},"medium_url":{"type":"string","nullable":true},"large_url":{"type":"string","nullable":true},"xlarge_url":{"type":"string","nullable":true},"og_image_url":{"type":"string","nullable":true},"external_references":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"attached":{"type":"boolean"},"filename":{"type":"string","nullable":true},"content_type":{"type":"string","nullable":true},"byte_size":{"type":"number","nullable":true},"embed_url":{"type":"string","nullable":true},"signed_id":{"type":"string","nullable":true},"viewable_id":{"type":"string","nullable":true},"download_url":{"type":"string","nullable":true},"metadata":{"type":"object"},"viewable_type":{"type":"string","nullable":true}},"required":["id","product_id","variant_ids","position","alt","media_type","external_video_url","focal_point_x","focal_point_y","video_provider","video_embed_url","video_url","poster_url","original_url","mini_url","small_url","medium_url","large_url","xlarge_url","og_image_url","external_references","created_at","updated_at","attached","filename","content_type","byte_size","embed_url","signed_id","viewable_id","download_url","metadata","viewable_type"],"x-typelizer":true},"MembershipProduct":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"thumbnail_url":{"type":"string","nullable":true}},"required":["id","name","thumbnail_url"],"x-typelizer":true},"NewsletterSubscriber":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"verified":{"type":"boolean"},"verified_at":{"type":"string","nullable":true},"customer_id":{"type":"string","nullable":true}},"required":["id","email","created_at","updated_at","verified","verified_at","customer_id"],"x-typelizer":true},"OptionType":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"number"},"kind":{"type":"string","enum":["dropdown","color_swatch","buttons"]},"translations":{"type":"object"},"metadata":{"type":"object"},"filterable":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}}},"required":["id","name","label","position","kind","metadata","filterable","created_at","updated_at"],"x-typelizer":true},"OptionValue":{"type":"object","properties":{"id":{"type":"string"},"option_type_id":{"type":"string"},"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"number"},"color_code":{"type":"string","nullable":true},"option_type_name":{"type":"string"},"option_type_label":{"type":"string"},"image_url":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"option_type":{"$ref":"#/components/schemas/OptionType"}},"required":["id","option_type_id","name","label","position","color_code","option_type_name","option_type_label","image_url","metadata","created_at","updated_at"],"x-typelizer":true},"OrderCancellationReason":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"can_be_deleted":{"type":"boolean"}},"required":["id","name","active","created_at","updated_at","can_be_deleted"],"x-typelizer":true},"OrderGroup":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"email":{"type":"string","nullable":true},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"total":{"type":"string","nullable":true},"item_total":{"type":"string","nullable":true},"fulfillment_status":{"type":"string","nullable":true,"enum":["backorder","canceled","partial","unfulfilled","fulfilled","delivered","pending","ready","shipped"]},"payment_status":{"type":"string","nullable":true,"enum":["none","authorized","partially_paid","paid","partially_refunded","refunded","overcharged","voided"]},"completed_at":{"type":"string","nullable":true},"billing_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"shipping_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"orders":{"type":"array","items":{"$ref":"#/components/schemas/Order"}},"customer_id":{"type":"string","nullable":true},"cart_id":{"type":"string","nullable":true},"seller_count":{"type":"number"},"includes_first_party":{"type":"boolean"},"confirmation_delivered":{"type":"boolean"},"store_owner_notification_delivered":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"payments":{"type":"array","items":{"$ref":"#/components/schemas/Payment"}}},"required":["id","number","email","currency","total","item_total","fulfillment_status","payment_status","completed_at","billing_address","shipping_address","orders","customer_id","cart_id","seller_count","includes_first_party","confirmation_delivered","store_owner_notification_delivered","created_at","updated_at","payments"],"x-typelizer":true},"OrderRoutingRule":{"type":"object","properties":{"id":{"type":"string"},"position":{"type":"number"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: preferred_location, default_location, minimize_splits. Extensions may register more."},"channel_id":{"type":"string"},"preferences":{"$ref":"#/components/schemas/OrderRoutingRulePreferences"}},"required":["id","position","active","created_at","updated_at","type","channel_id","preferences"],"x-typelizer":true},"Order":{"type":"object","properties":{"id":{"type":"string"},"market_id":{"type":"string","nullable":true},"withdrawal_period_ends_at":{"type":"string","nullable":true},"within_withdrawal_period":{"type":"boolean"},"cart_id":{"type":"string","nullable":true},"channel_id":{"type":"string","nullable":true},"company_id":{"type":"string","nullable":true},"company_name":{"type":"string","nullable":true},"po_document_filename":{"type":"string","nullable":true},"po_document_byte_size":{"type":"number","nullable":true},"number":{"type":"string"},"email":{"type":"string"},"customer_note":{"type":"string","nullable":true},"po_number":{"type":"string","nullable":true},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"locale":{"type":"string","nullable":true},"total_quantity":{"type":"number"},"coupon_code":{"type":"string","nullable":true},"fulfillment_status":{"type":"string","nullable":true,"enum":["backorder","canceled","partial","unfulfilled","fulfilled","delivered","pending","ready","shipped"]},"payment_status":{"type":"string","nullable":true,"enum":["none","authorized","partially_paid","paid","partially_refunded","refunded","overcharged","voided"]},"completed_at":{"type":"string","nullable":true},"item_total":{"type":"string"},"adjustment_total":{"type":"string"},"discount_total":{"type":"string"},"tax_total":{"type":"string"},"included_tax_total":{"type":"string"},"additional_tax_total":{"type":"string"},"total":{"type":"string"},"gift_card_total":{"type":"string"},"amount_due":{"type":"string"},"delivery_total":{"type":"string"},"fee_total":{"type":"string"},"store_credit_total":{"type":"string"},"covered_by_store_credit":{"type":"boolean"},"items":{"type":"array","items":{"$ref":"#/components/schemas/LineItem"}},"fulfillments":{"type":"array","items":{"$ref":"#/components/schemas/Fulfillment"}},"payments":{"type":"array","items":{"$ref":"#/components/schemas/Payment"}},"billing_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"shipping_address":{"allOf":[{"$ref":"#/components/schemas/Address"}],"nullable":true},"gift_card":{"allOf":[{"$ref":"#/components/schemas/GiftCard"}],"nullable":true},"market":{"allOf":[{"$ref":"#/components/schemas/Market"}],"nullable":true},"external_references":{"type":"object"},"status":{"type":"string","enum":["draft","placed","canceled"]},"last_ip_address":{"type":"string","nullable":true},"considered_risky":{"type":"boolean"},"confirmation_delivered":{"type":"boolean"},"store_owner_notification_delivered":{"type":"boolean","nullable":true},"metadata":{"type":"object"},"cancel_note":{"type":"string","nullable":true},"canceled_at":{"type":"string","nullable":true},"approved_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"payment_total":{"type":"string"},"commission_amount_total":{"type":"string"},"commission_tax_total":{"type":"string"},"commission_total":{"type":"string"},"preferred_stock_location_id":{"type":"string","nullable":true},"po_document_url":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"},"order_group_id":{"type":"string","nullable":true},"tags":{"type":"array","items":{"type":"string"}},"internal_note":{"type":"string","nullable":true},"internal_note_html":{"type":"string","nullable":true},"approver_id":{"type":"string","nullable":true},"approver_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"approver":{"$ref":"#/components/schemas/Actor"},"canceler_id":{"type":"string","nullable":true},"canceler_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"canceler":{"$ref":"#/components/schemas/Actor"},"created_by_id":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by":{"$ref":"#/components/schemas/Actor"},"cancel_reason_id":{"type":"string","nullable":true},"cancel_reason_name":{"type":"string","nullable":true},"customer_id":{"type":"string","nullable":true},"applied_promotions":{"type":"array","items":{"$ref":"#/components/schemas/AppliedPromotion"}},"payment_splits":{"type":"array","items":{"$ref":"#/components/schemas/PaymentSplit"}},"cart":{"$ref":"#/components/schemas/Cart"},"channel":{"$ref":"#/components/schemas/Channel"},"preferred_stock_location":{"$ref":"#/components/schemas/StockLocation"},"payment_methods":{"type":"array","items":{"$ref":"#/components/schemas/PaymentMethod"}},"customer":{"$ref":"#/components/schemas/Customer"},"cancel_reason":{"$ref":"#/components/schemas/OrderCancellationReason"},"returns":{"type":"array","items":{"$ref":"#/components/schemas/Return"}},"exchanges":{"type":"array","items":{"$ref":"#/components/schemas/Exchange"}},"claims":{"type":"array","items":{"$ref":"#/components/schemas/Claim"}},"freight_summary":{"allOf":[{"$ref":"#/components/schemas/FreightSummary"}],"nullable":true}},"required":["id","market_id","withdrawal_period_ends_at","within_withdrawal_period","cart_id","channel_id","company_id","company_name","po_document_filename","po_document_byte_size","number","email","customer_note","po_number","currency","locale","total_quantity","coupon_code","fulfillment_status","payment_status","completed_at","item_total","adjustment_total","discount_total","tax_total","included_tax_total","additional_tax_total","total","gift_card_total","amount_due","delivery_total","fee_total","store_credit_total","covered_by_store_credit","gift_card","market","external_references","status","last_ip_address","considered_risky","confirmation_delivered","store_owner_notification_delivered","metadata","cancel_note","canceled_at","approved_at","created_at","updated_at","payment_total","commission_amount_total","commission_tax_total","commission_total","preferred_stock_location_id","po_document_url","seller_id","order_group_id","tags","internal_note","internal_note_html","approver_id","approver_type","canceler_id","canceler_type","created_by_id","created_by_type","cancel_reason_id","cancel_reason_name","customer_id","freight_summary"],"x-typelizer":true},"PackageType":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"kind":{"type":"string","enum":["box","envelope","carton","pallet","container"]},"length":{"type":"string","nullable":true},"width":{"type":"string","nullable":true},"height":{"type":"string","nullable":true},"weight":{"type":"string","nullable":true},"max_weight":{"type":"string","nullable":true},"default":{"type":"boolean"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"volume":{"type":"string","nullable":true},"seller_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true}},"required":["id","name","kind","length","width","height","weight","max_weight","default","metadata","created_at","updated_at","dimensions_unit","weight_unit","volume","seller_id","seller_name"],"x-typelizer":true},"PaymentMethod":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"type":{"type":"string","description":"Payment method type. Built-in: check, store_credit, custom_payment_source_method, bogus (test only); payment provider gems register their own, for example stripe."},"session_required":{"type":"boolean"},"source_required":{"type":"boolean"},"metadata":{"type":"object"},"active":{"type":"boolean"},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"],"nullable":true},"resolved_capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"]},"storefront_visible":{"type":"boolean"},"position":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"preferences":{"$ref":"#/components/schemas/PaymentMethodPreferences"},"logo_url":{"type":"string","nullable":true},"docs_url":{"type":"string","nullable":true},"third_party":{"type":"boolean"}},"required":["id","name","description","type","session_required","source_required","metadata","active","capture_method","resolved_capture_method","storefront_visible","position","created_at","updated_at","preferences","logo_url","docs_url","third_party"],"x-typelizer":true},"Payment":{"type":"object","properties":{"id":{"type":"string"},"payment_method_id":{"type":"string"},"response_code":{"type":"string","nullable":true},"number":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["checkout","processing","pending","completed","failed","void","invalid"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"amount":{"type":"string"},"source_type":{"type":"string","nullable":true,"enum":["credit_card","store_credit","payment_source"]},"source_id":{"type":"string","nullable":true},"source":{"anyOf":[{"$ref":"#/components/schemas/CreditCard"},{"$ref":"#/components/schemas/StoreCredit"},{"$ref":"#/components/schemas/PaymentSource"}],"nullable":true},"payment_method":{"$ref":"#/components/schemas/PaymentMethod"},"metadata":{"type":"object"},"avs_response":{"type":"string","nullable":true},"cvv_response_code":{"type":"string","nullable":true},"cvv_response_message":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"captured_amount":{"type":"string"},"order_id":{"type":"string","nullable":true},"order":{"$ref":"#/components/schemas/Order"},"refunds":{"type":"array","items":{"$ref":"#/components/schemas/Refund"}},"payment_splits":{"type":"array","items":{"$ref":"#/components/schemas/PaymentSplit"}}},"required":["id","payment_method_id","response_code","number","status","amount","source_type","source_id","source","metadata","avs_response","cvv_response_code","cvv_response_message","created_at","updated_at","captured_amount","order_id"],"x-typelizer":true},"PaymentSource":{"type":"object","properties":{"id":{"type":"string"},"gateway_payment_profile_id":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","gateway_payment_profile_id","metadata","created_at","updated_at"],"x-typelizer":true},"PaymentSplit":{"type":"object","properties":{"id":{"type":"string"},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"created_at":{"type":"string"},"updated_at":{"type":"string"},"authorized_amount":{"type":"string"},"captured_amount":{"type":"string"},"refunded_amount":{"type":"string"},"claimed_amount":{"type":"string"},"net_captured_amount":{"type":"string"},"refundable_amount":{"type":"string"},"payment_id":{"type":"string"},"payment_number":{"type":"string","nullable":true},"order_id":{"type":"string"},"order_number":{"type":"string","nullable":true}},"required":["id","currency","created_at","updated_at","authorized_amount","captured_amount","refunded_amount","claimed_amount","net_captured_amount","refundable_amount","payment_id","payment_number","order_id","order_number"],"x-typelizer":true},"Permission":{"type":"object","properties":{"key":{"type":"string"},"resource":{"type":"string"},"kind":{"type":"string","enum":["read","write"]},"group":{"type":"string"},"group_label":{"type":"string"},"label":{"type":"string"},"description":{"type":"string"}},"required":["key","resource","kind","group","group_label","label","description"],"x-typelizer":true},"Policy":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"body":{"type":"string","nullable":true},"body_html":{"type":"string","nullable":true},"updated_at":{"type":"string"},"created_at":{"type":"string"}},"required":["id","name","slug","body","body_html","updated_at","created_at"],"x-typelizer":true},"PriceAdjustmentTier":{"type":"object","properties":{"id":{"type":"string"},"min_quantity":{"type":"number"},"percentage":{"type":"string"}},"required":["id","min_quantity","percentage"],"x-typelizer":true},"PriceHistory":{"type":"object","properties":{"id":{"type":"string"},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"amount":{"type":"string","nullable":true},"recorded_at":{"type":"string"},"variant_id":{"type":"string"},"price_id":{"type":"string"},"compare_at_amount":{"type":"string","nullable":true},"created_at":{"type":"string"}},"required":["id","currency","amount","recorded_at","variant_id","price_id","compare_at_amount","created_at"],"x-typelizer":true},"PriceListProduct":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"thumbnail_url":{"type":"string","nullable":true},"price_list_variants":{"type":"array","items":{"$ref":"#/components/schemas/CatalogPrice"}}},"required":["id","name","thumbnail_url"],"x-typelizer":true},"PriceList":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"status":{"anyOf":[{"type":"string","enum":["draft","active","inactive","scheduled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"position":{"type":"number"},"match_policy":{"type":"string","enum":["all","any"]},"adjust_compare_at":{"type":"boolean"},"starts_at":{"type":"string","nullable":true},"ends_at":{"type":"string","nullable":true},"deleted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"price_adjustment_percentage":{"type":"string","nullable":true},"automatic_pricing":{"type":"boolean"},"currently_active":{"type":"boolean"},"products_count":{"type":"number"},"prices_count":{"type":"number"},"price_adjustment_tiers":{"type":"array","items":{"$ref":"#/components/schemas/PriceAdjustmentTier"}},"price_rules":{"type":"array","items":{"$ref":"#/components/schemas/PriceRule"}}},"required":["id","name","description","status","position","match_policy","adjust_compare_at","starts_at","ends_at","deleted_at","created_at","updated_at","price_adjustment_percentage","automatic_pricing","currently_active","products_count","prices_count","price_adjustment_tiers"],"x-typelizer":true},"PriceRule":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: channel_rule, customer_group_rule, market_rule, user_rule, volume_rule, zone_rule. Extensions may register more."},"price_list_id":{"type":"string"},"preferences":{"$ref":"#/components/schemas/PriceRulePreferences"},"markets":{"type":"array","items":{"$ref":"#/components/schemas/Market"}},"customer_groups":{"type":"array","items":{"$ref":"#/components/schemas/CustomerGroup"}},"channels":{"type":"array","items":{"$ref":"#/components/schemas/Channel"}},"customers":{"type":"array","items":{"$ref":"#/components/schemas/Customer"}}},"required":["id","created_at","updated_at","type","price_list_id","preferences"],"x-typelizer":true},"Price":{"type":"object","properties":{"id":{"type":"string"},"currency":{"type":"string","nullable":true,"enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"amount":{"type":"string","nullable":true},"compare_at_amount":{"type":"string","nullable":true},"price_list_id":{"type":"string","nullable":true},"min_quantity":{"type":"number"},"variant_id":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"variant":{"$ref":"#/components/schemas/Variant"}},"required":["id","currency","amount","compare_at_amount","price_list_id","min_quantity","variant_id","created_at","updated_at"],"x-typelizer":true},"ProductPublication":{"type":"object","properties":{"id":{"type":"string"},"published_at":{"type":"string","nullable":true},"unpublished_at":{"type":"string","nullable":true},"product_id":{"type":"string"},"channel_id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","published_at","unpublished_at","product_id","channel_id","created_at","updated_at"],"x-typelizer":true},"Product":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"meta_title":{"type":"string","nullable":true},"meta_description":{"type":"string","nullable":true},"meta_keywords":{"type":"string","nullable":true},"variant_count":{"type":"number"},"available_on":{"type":"string","nullable":true},"preorder_ships_at":{"type":"string","nullable":true},"purchasable":{"type":"boolean"},"preorder":{"type":"boolean"},"in_stock":{"type":"boolean"},"backorderable":{"type":"boolean"},"available":{"type":"boolean"},"description":{"type":"string","nullable":true},"description_html":{"type":"string","nullable":true},"default_variant_id":{"type":"string"},"buy_box_variant_id":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true},"tags":{"type":"array","items":{"type":"string"}},"price":{"allOf":[{"$ref":"#/components/schemas/Price"}],"nullable":true},"original_price":{"allOf":[{"$ref":"#/components/schemas/Price"}],"nullable":true},"seller_id":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"},"primary_media":{"$ref":"#/components/schemas/Media"},"media":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"variants":{"type":"array","items":{"$ref":"#/components/schemas/Variant"}},"default_variant":{"$ref":"#/components/schemas/Variant"},"option_types":{"type":"array","items":{"$ref":"#/components/schemas/OptionType"}},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}},"categories":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"prior_price":{"allOf":[{"$ref":"#/components/schemas/PriceHistory"}],"nullable":true},"external_references":{"type":"object"},"translations":{"type":"object"},"status":{"anyOf":[{"type":"string","enum":["draft","active","archived","proposed","rejected"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"metadata":{"type":"object"},"deleted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"submission":{"allOf":[{"$ref":"#/components/schemas/ProductSubmission"}],"nullable":true},"seller_name":{"type":"string","nullable":true},"product_type_id":{"type":"string","nullable":true},"tax_category_id":{"type":"string","nullable":true},"digital_assets":{"type":"array","items":{"$ref":"#/components/schemas/DigitalAsset"}},"collections":{"type":"array","items":{"$ref":"#/components/schemas/Collection"}},"product_publications":{"type":"array","items":{"$ref":"#/components/schemas/ProductPublication"}},"channels":{"type":"array","items":{"$ref":"#/components/schemas/Channel"}},"product_type":{"$ref":"#/components/schemas/ProductType"}},"required":["id","name","slug","meta_title","meta_description","meta_keywords","variant_count","available_on","preorder_ships_at","purchasable","preorder","in_stock","backorderable","available","description","description_html","default_variant_id","buy_box_variant_id","thumbnail_url","tags","price","original_price","seller_id","external_references","status","metadata","deleted_at","created_at","updated_at","delivery_profile_id","seller_name","product_type_id","tax_category_id"],"x-typelizer":true},"ProductSubmission":{"type":"object","properties":{"id":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","approved","rejected","withdrawn"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"review_note":{"type":"string","nullable":true},"reviewed_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"product_id":{"type":"string"},"metadata":{"type":"object","nullable":true},"updated_at":{"type":"string"},"submitted_by_id":{"type":"string","nullable":true},"reviewed_by_id":{"type":"string","nullable":true},"reviewed_by_name":{"type":"string","nullable":true},"auto_approved":{"type":"boolean"}},"required":["id","status","review_note","reviewed_at","created_at","product_id","metadata","updated_at","submitted_by_id","reviewed_by_id","reviewed_by_name","auto_approved"],"x-typelizer":true},"ProductTypeCustomFieldDefinition":{"type":"object","properties":{"id":{"type":"string"},"key":{"type":"string"},"namespace":{"type":"string"},"label":{"type":"string"},"field_type":{"type":"string","enum":["short_text","long_text","rich_text","number","boolean","json"]},"required":{"type":"boolean"},"sort_order":{"type":"number"}},"required":["id","key","namespace","label","field_type","required","sort_order"],"x-typelizer":true},"ProductType":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"translations":{"type":"object"},"products_count":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"option_type_ids":{"type":"array","items":{"type":"string"}},"category_ids":{"type":"array","items":{"type":"string"}},"custom_field_definitions":{"type":"array","items":{"$ref":"#/components/schemas/ProductTypeCustomFieldDefinition"}}},"required":["id","name","products_count","created_at","updated_at","delivery_profile_id","option_type_ids","category_ids","custom_field_definitions"],"x-typelizer":true},"PromotionAction":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Action type. Built-in: create_adjustment, create_item_adjustments, create_line_items, free_shipping. Extensions may register more."},"promotion_id":{"type":"string"},"preferences":{"type":"object"},"calculator":{"allOf":[{"$ref":"#/components/schemas/PromotionActionCalculator"}],"nullable":true},"line_items":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionLineItem"},"nullable":true}},"required":["id","created_at","updated_at","type","promotion_id","preferences","calculator","line_items"],"x-typelizer":true},"PromotionRule":{"type":"object","properties":{"id":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"type":{"type":"string","description":"Rule type. Built-in: currency, country, channel, market, item_total, product, customer, customer_group, first_order, customer_logged_in, one_use_per_user, category, option_value. Extensions may register more."},"promotion_id":{"type":"string"},"preferences":{"$ref":"#/components/schemas/PromotionRulePreferences"},"product_ids":{"type":"array","items":{"type":"string"},"nullable":true},"category_ids":{"type":"array","items":{"type":"string"},"nullable":true},"customer_ids":{"type":"array","items":{"type":"string"},"nullable":true},"option_value_ids":{"type":"array","items":{"type":"string"},"nullable":true},"products":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"categories":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"customers":{"type":"array","items":{"$ref":"#/components/schemas/Customer"}},"customer_groups":{"type":"array","items":{"$ref":"#/components/schemas/CustomerGroup"}},"countries":{"type":"array","items":{"$ref":"#/components/schemas/Country"}},"channels":{"type":"array","items":{"$ref":"#/components/schemas/Channel"}},"markets":{"type":"array","items":{"$ref":"#/components/schemas/Market"}},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}}},"required":["id","created_at","updated_at","type","promotion_id","preferences","product_ids","category_ids","customer_ids","option_value_ids"],"x-typelizer":true},"Promotion":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"code":{"type":"string","nullable":true},"starts_at":{"type":"string","nullable":true},"expires_at":{"type":"string","nullable":true},"usage_limit":{"type":"number","nullable":true},"match_policy":{"type":"string","enum":["all","any"]},"path":{"type":"string","nullable":true},"kind":{"type":"string","enum":["coupon_code","automatic"]},"multi_codes":{"type":"boolean"},"number_of_codes":{"type":"number","nullable":true},"code_prefix":{"type":"string","nullable":true},"promotion_category_id":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"action_ids":{"type":"array","items":{"type":"string"}},"rule_ids":{"type":"array","items":{"type":"string"}}},"required":["id","name","description","code","starts_at","expires_at","usage_limit","match_policy","path","kind","multi_codes","number_of_codes","code_prefix","promotion_category_id","metadata","created_at","updated_at","action_ids","rule_ids"],"x-typelizer":true},"PurchaseOrderItem":{"type":"object","properties":{"id":{"type":"string"},"quantity_ordered":{"type":"number"},"quantity_received":{"type":"number"},"quantity_rejected":{"type":"number"},"quantity_over":{"type":"number"},"outstanding":{"type":"number"},"currency":{"type":"string","nullable":true,"enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"created_at":{"type":"string"},"updated_at":{"type":"string"},"unit_cost":{"type":"string"},"total_cost":{"type":"string"},"purchase_order_id":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"product_id":{"type":"string","nullable":true},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true}},"required":["id","quantity_ordered","quantity_received","quantity_rejected","quantity_over","outstanding","currency","created_at","updated_at","unit_cost","total_cost","purchase_order_id","variant_id","product_id","variant_name","variant_sku","options_text","thumbnail_url"],"x-typelizer":true},"PurchaseOrder":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"status":{"type":"string"},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"reference":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"metadata":{"type":"object"},"close_reason":{"type":"string","nullable":true},"items_count":{"type":"number"},"quantity_received_total":{"type":"number"},"quantity_rejected_total":{"type":"number"},"ordered_at":{"type":"string","nullable":true},"received_at":{"type":"string","nullable":true},"closed_short_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"expected_at":{"type":"string","nullable":true},"cancel_by":{"type":"string","nullable":true},"closed_short":{"type":"boolean"},"quantity_ordered_total":{"type":"number"},"editable":{"type":"boolean"},"subtotal":{"type":"string"},"supplier_id":{"type":"string","nullable":true},"destination_location_id":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/PurchaseOrderItem"}},"stock_receipts":{"type":"array","items":{"$ref":"#/components/schemas/StockReceipt"}},"supplier":{"$ref":"#/components/schemas/Supplier"},"destination_location":{"$ref":"#/components/schemas/StockLocation"}},"required":["id","number","status","currency","reference","notes","metadata","close_reason","items_count","quantity_received_total","quantity_rejected_total","ordered_at","received_at","closed_short_at","created_at","updated_at","expected_at","cancel_by","closed_short","quantity_ordered_total","editable","subtotal","supplier_id","destination_location_id"],"x-typelizer":true},"RefundReason":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"can_be_deleted":{"type":"boolean"}},"required":["id","name","active","created_at","updated_at","can_be_deleted"],"x-typelizer":true},"Refund":{"type":"object","properties":{"id":{"type":"string"},"transaction_id":{"type":"string","nullable":true},"amount":{"type":"string","nullable":true},"payment_id":{"type":"string","nullable":true},"refund_reason_id":{"type":"string","nullable":true},"originator_id":{"type":"string","nullable":true},"originator_type":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"tax_amount":{"type":"string"},"refunder_id":{"type":"string","nullable":true},"refunder_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"refunder":{"$ref":"#/components/schemas/Actor"},"payment":{"$ref":"#/components/schemas/Payment"}},"required":["id","transaction_id","amount","payment_id","refund_reason_id","originator_id","originator_type","metadata","created_at","updated_at","tax_amount","refunder_id","refunder_type"],"x-typelizer":true},"ReturnLineItem":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"received_quantity":{"type":"number"},"resellable":{"type":"boolean"},"pre_tax_amount":{"type":"string"},"included_tax_total":{"type":"string"},"additional_tax_total":{"type":"string"},"tax_total":{"type":"string"},"refund_amount":{"type":"string"},"variant_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"fulfillment_item_id":{"type":"string","nullable":true},"variant":{"$ref":"#/components/schemas/Variant"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"line_item":{"$ref":"#/components/schemas/LineItem"},"tax_lines":{"type":"array","items":{"$ref":"#/components/schemas/TaxLine"}}},"required":["id","quantity","received_quantity","resellable","pre_tax_amount","included_tax_total","additional_tax_total","tax_total","refund_amount","variant_id","line_item_id","fulfillment_item_id","created_at","updated_at"],"x-typelizer":true},"ReturnReason":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"can_be_deleted":{"type":"boolean"}},"required":["id","name","active","created_at","updated_at","can_be_deleted"],"x-typelizer":true},"Return":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["requested","approved","received","refunded","canceled"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"order_id":{"type":"string","nullable":true},"reason_id":{"type":"string","nullable":true},"refund_total":{"type":"string"},"refund_tax_total":{"type":"string"},"approved_at":{"type":"string","nullable":true},"received_at":{"type":"string","nullable":true},"refunded_at":{"type":"string","nullable":true},"canceled_at":{"type":"string","nullable":true},"reason":{"$ref":"#/components/schemas/ReturnReason"},"return_line_items":{"type":"array","items":{"$ref":"#/components/schemas/ReturnLineItem"}},"memo":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_location_id":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true},"created_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"created_by":{"$ref":"#/components/schemas/Actor"},"refunded_total":{"type":"string"},"refundable_total":{"type":"string"},"order":{"$ref":"#/components/schemas/Order"},"stock_location":{"$ref":"#/components/schemas/StockLocation"},"refunds":{"type":"array","items":{"$ref":"#/components/schemas/Refund"}},"documents":{"type":"array","items":{"type":"object"}},"labels":{"type":"array","items":{"$ref":"#/components/schemas/ShippingLabel"}},"deliveries":{"type":"array","items":{"$ref":"#/components/schemas/Delivery"}}},"required":["id","number","status","order_id","reason_id","refund_total","refund_tax_total","approved_at","received_at","refunded_at","canceled_at","memo","metadata","created_at","updated_at","stock_location_id","created_by_id","created_by_type","refunded_total","refundable_total","documents","labels","deliveries"],"x-typelizer":true},"Role":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"permissions":{"type":"array","items":{"type":"string"}},"mutable":{"type":"boolean"},"users_count":{"type":"number"}},"required":["id","name","description","created_at","updated_at","permissions","mutable","users_count"],"x-typelizer":true},"SavedReport":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"query":{"type":"object"},"seeded":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"user_id":{"type":"string","nullable":true},"author_name":{"type":"string","nullable":true}},"required":["id","name","description","query","seeded","created_at","updated_at","user_id","author_name"],"x-typelizer":true},"SellerBalance":{"type":"object","properties":{"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"settlement_currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"converted":{"type":"boolean"},"seller_id":{"type":"string"},"earned":{"type":"string"},"pending":{"type":"string"},"payable":{"type":"string"},"paid":{"type":"string"},"balance":{"type":"string"}},"required":["currency","settlement_currency","converted","seller_id","earned","pending","payable","paid","balance"],"x-typelizer":true},"SellerPayout":{"type":"object","properties":{"id":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","processing","completed","failed","unresolved"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"reference":{"type":"string","nullable":true},"metadata":{"type":"object"},"period_start":{"type":"string","nullable":true},"period_end":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount":{"type":"string"},"seller_id":{"type":"string"},"seller_name":{"type":"string","nullable":true},"transfers_count":{"type":"number"},"provider":{"type":"string","description":"Payout provider. Built-in: system. Provider gems register more (e.g. stripe)."}},"required":["id","status","currency","reference","metadata","period_start","period_end","created_at","updated_at","amount","seller_id","seller_name","transfers_count","provider"],"x-typelizer":true},"SellerRequirement":{"type":"object","properties":{"id":{"type":"string"},"position":{"type":"number"},"active":{"type":"boolean"},"required":{"type":"boolean"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"kind":{"type":"string","description":"Requirement kind. Built-in: accept_terms, complete_profile, billing_address, returns_address, delivery_method, package_type, minimum_products, payout_account, required_custom_fields, policy, attestation, operator_review, document. Extensions may register more."},"name":{"type":"string"},"description":{"type":"string","nullable":true},"preferences":{"$ref":"#/components/schemas/SellerRequirementPreferences"},"custom_field_definition_ids":{"type":"array","items":{"type":"string"}},"allow_multiple":{"type":"boolean"},"accepts_submissions":{"type":"boolean"},"reviewed_by_operator":{"type":"boolean"}},"required":["id","position","active","required","metadata","created_at","updated_at","kind","name","description","preferences","custom_field_definition_ids","allow_multiple","accepts_submissions","reviewed_by_operator"],"x-typelizer":true},"SellerRequirementStatus":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","description":"Requirement kind. Built-in: accept_terms, complete_profile, billing_address, returns_address, delivery_method, package_type, minimum_products, payout_account, required_custom_fields, policy, attestation, operator_review, document. Extensions may register more."},"name":{"type":"string"},"description":{"type":"string","nullable":true},"required":{"type":"boolean"},"position":{"type":"number"},"status":{"type":"string","enum":["complete","incomplete","pending","rejected"]},"action_url":{"type":"string","nullable":true},"blocker":{"type":"object","nullable":true},"blocking":{"type":"boolean"},"required_policy_name":{"type":"string","nullable":true},"submission":{"$ref":"#/components/schemas/SellerRequirementSubmission"},"published_policy":{"$ref":"#/components/schemas/Policy"}},"required":["id","kind","name","description","required","position","status","action_url","blocker","blocking","required_policy_name"],"x-typelizer":true},"SellerRequirementSubmission":{"type":"object","properties":{"id":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","accepted","rejected","waived"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"note":{"type":"string","nullable":true},"review_note":{"type":"string","nullable":true},"reference":{"type":"string","nullable":true},"metadata":{"type":"object","nullable":true},"reviewed_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"seller_id":{"type":"string"},"requirement_id":{"type":"string"},"requirement_name":{"type":"string"},"file_url":{"type":"string","nullable":true},"file_name":{"type":"string","nullable":true}},"required":["id","status","note","review_note","reference","metadata","reviewed_at","created_at","updated_at","seller_id","requirement_id","requirement_name","file_url","file_name"],"x-typelizer":true},"Seller":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"about":{"type":"string"},"about_html":{"type":"string"},"logo_url":{"type":"string","nullable":true},"square_logo_url":{"type":"string","nullable":true},"cover_photo_url":{"type":"string","nullable":true},"status":{"anyOf":[{"type":"string","enum":["pending","invited","canceled","onboarding","ready_for_review","approved","rejected","suspended"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"contact_email":{"type":"string","nullable":true},"billing_email":{"type":"string","nullable":true},"tax_remittance":{"type":"string"},"payouts_schedule_interval":{"type":"string","nullable":true},"metadata":{"type":"object","nullable":true},"holiday_mode_until":{"type":"string","nullable":true},"terms_accepted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"deleted_at":{"type":"string","nullable":true},"minimum_payout_amount":{"type":"string","nullable":true},"on_holiday":{"type":"boolean"},"sellable":{"type":"boolean"},"products_count":{"type":"number"},"users_count":{"type":"number"},"onboarding_progress":{"type":"object"},"onboarding_complete":{"type":"boolean"},"legal_name":{"type":"string","nullable":true},"registration_number":{"type":"string","nullable":true},"billing_address":{"$ref":"#/components/schemas/Address"},"returns_address":{"$ref":"#/components/schemas/Address"}},"required":["id","name","slug","about","about_html","logo_url","square_logo_url","cover_photo_url","status","contact_email","billing_email","tax_remittance","payouts_schedule_interval","metadata","holiday_mode_until","terms_accepted_at","created_at","updated_at","deleted_at","minimum_payout_amount","on_holiday","sellable","products_count","users_count","onboarding_progress","onboarding_complete","legal_name","registration_number"],"x-typelizer":true},"SellerTeamMember":{"type":"object","properties":{"id":{"type":"string"},"email":{"type":"string"},"first_name":{"type":"string","nullable":true},"last_name":{"type":"string","nullable":true},"full_name":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"avatar_url":{"type":"string","nullable":true}},"required":["id","email","first_name","last_name","full_name","created_at","updated_at","avatar_url"],"x-typelizer":true},"SellerTransfer":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","enum":["earning","refund_reversal"]},"status":{"anyOf":[{"type":"string","enum":["pending","processing","completed","failed","unresolved"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"reference":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount":{"type":"string"},"settled_amount":{"type":"string","nullable":true},"settled_currency":{"type":"string","nullable":true,"enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"converted":{"type":"boolean"},"seller_id":{"type":"string"},"order_id":{"type":"string","nullable":true},"payout_id":{"type":"string","nullable":true},"reversed_from_id":{"type":"string","nullable":true},"refund_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"order_number":{"type":"string","nullable":true},"provider":{"type":"string","description":"Payout provider. Built-in: system. Provider gems register more (e.g. stripe)."}},"required":["id","kind","status","currency","reference","metadata","created_at","updated_at","amount","settled_amount","settled_currency","converted","seller_id","order_id","payout_id","reversed_from_id","refund_id","seller_name","order_number","provider"],"x-typelizer":true},"SetupTask":{"type":"object","properties":{"name":{"type":"string"},"done":{"type":"boolean"}},"required":["name","done"],"x-typelizer":true},"ShippingLabel":{"type":"object","properties":{"id":{"type":"string"},"source":{"type":"string","enum":["purchased","uploaded"]},"status":{"anyOf":[{"type":"string","enum":["purchased","refund_requested","refunded"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"carrier":{"type":"string","nullable":true},"carrier_name":{"type":"string","nullable":true},"service":{"type":"string","nullable":true},"tracking_number":{"type":"string","nullable":true},"currency":{"type":"string","nullable":true,"enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"format":{"type":"string","nullable":true},"external_id":{"type":"string","nullable":true},"metadata":{"type":"object"},"refunded_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"owner_id":{"type":"string"},"owner_type":{"type":"string","enum":["fulfillment","return"]},"cost":{"type":"string"},"integration_id":{"type":"string","nullable":true},"file_pending":{"type":"boolean"},"download_url":{"type":"string","nullable":true}},"required":["id","source","status","carrier","carrier_name","service","tracking_number","currency","format","external_id","metadata","refunded_at","created_at","updated_at","owner_id","owner_type","cost","integration_id","file_pending","download_url"],"x-typelizer":true},"State":{"type":"object","properties":{"abbr":{"type":"string"},"name":{"type":"string"}},"required":["abbr","name"],"x-typelizer":true},"StockLevel":{"type":"object","properties":{"id":{"type":"string"},"count_on_hand":{"type":"number"},"backorderable":{"type":"boolean"},"stock_location_id":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"external_references":{"type":"object"},"metadata":{"type":"object"},"reserved_count":{"type":"number"},"incoming_count":{"type":"number"},"purchasable_count":{"type":"number"},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_location_name":{"type":"string","nullable":true},"product_id":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true},"allocated_count":{"type":"number"},"available_count":{"type":"number"},"stock_location":{"$ref":"#/components/schemas/StockLocation"},"variant":{"$ref":"#/components/schemas/Variant"}},"required":["id","count_on_hand","backorderable","stock_location_id","variant_id","external_references","metadata","reserved_count","incoming_count","purchasable_count","variant_name","variant_sku","created_at","updated_at","stock_location_name","product_id","options_text","thumbnail_url","allocated_count","available_count"],"x-typelizer":true},"StockLocation":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"address1":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"zipcode":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true,"enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"country_name":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"state_text":{"type":"string","nullable":true},"pickup_ready_in_minutes":{"type":"number","nullable":true},"pickup_instructions":{"type":"string","nullable":true},"external_references":{"type":"object"},"admin_name":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"active":{"type":"boolean"},"default":{"type":"boolean"},"backorderable_default":{"type":"boolean"},"propagate_all_variants":{"type":"boolean"},"kind":{"anyOf":[{"type":"string","enum":["warehouse","store","fulfillment_center"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"pickup_enabled":{"type":"boolean"},"pickup_stock_policy":{"type":"string","enum":["local","any"]},"returns_enabled":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"seller_id":{"type":"string","nullable":true},"seller_name":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"}},"required":["id","name","address1","city","zipcode","country_code","country_name","state_code","state_text","pickup_ready_in_minutes","pickup_instructions","external_references","admin_name","address2","state_name","phone","company","active","default","backorderable_default","propagate_all_variants","kind","pickup_enabled","pickup_stock_policy","returns_enabled","created_at","updated_at","seller_id","seller_name"],"x-typelizer":true},"StockMovement":{"type":"object","properties":{"id":{"type":"string"},"quantity":{"type":"number"},"kind":{"type":"string","nullable":true,"enum":["received","allocated","shipped","released","adjusted"]},"reason":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_level_id":{"type":"string","nullable":true},"stock_location_id":{"type":"string","nullable":true},"stock_location_name":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"order_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"return_id":{"type":"string","nullable":true},"exchange_id":{"type":"string","nullable":true},"stock_transfer_id":{"type":"string","nullable":true},"stock_receipt_id":{"type":"string","nullable":true},"purchase_order_id":{"type":"string","nullable":true},"order_number":{"type":"string","nullable":true},"return_number":{"type":"string","nullable":true},"exchange_number":{"type":"string","nullable":true},"stock_transfer_number":{"type":"string","nullable":true},"purchase_order_number":{"type":"string","nullable":true},"unit_cost":{"type":"string","nullable":true}},"required":["id","quantity","kind","reason","created_at","updated_at","stock_level_id","stock_location_id","stock_location_name","variant_id","variant_name","variant_sku","order_id","fulfillment_id","return_id","exchange_id","stock_transfer_id","stock_receipt_id","purchase_order_id","order_number","return_number","exchange_number","stock_transfer_number","purchase_order_number","unit_cost"],"x-typelizer":true},"StockReceiptItem":{"type":"object","properties":{"id":{"type":"string"},"quantity_accepted":{"type":"number"},"quantity_rejected":{"type":"number"},"rejection_reason":{"type":"string","nullable":true,"enum":["damaged","wrong_item","expired","other"]},"notes":{"type":"string","nullable":true},"line_type":{"type":"string","enum":["purchase_order_item","stock_transfer_item"]},"line_id":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"product_id":{"type":"string","nullable":true},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true}},"required":["id","quantity_accepted","quantity_rejected","rejection_reason","notes","line_type","line_id","variant_id","product_id","variant_name","variant_sku","thumbnail_url"],"x-typelizer":true},"StockReceipt":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"reference":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"metadata":{"type":"object"},"quantity_accepted_total":{"type":"number"},"quantity_rejected_total":{"type":"number"},"received_at":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"receivable_type":{"type":"string","enum":["purchase_order","stock_transfer"]},"receivable_id":{"type":"string"},"received_by_id":{"type":"string","nullable":true},"received_by_type":{"anyOf":[{"type":"string","enum":["admin_user","api_key"]},{"type":"string"}],"nullable":true,"description":"The values listed are the built-in ones; extensions may add more."},"received_by":{"$ref":"#/components/schemas/Actor"},"items_count":{"type":"number"},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockReceiptItem"}}},"required":["id","number","reference","notes","metadata","quantity_accepted_total","quantity_rejected_total","received_at","created_at","updated_at","receivable_type","receivable_id","received_by_id","received_by_type","items_count"],"x-typelizer":true},"StockReservation":{"type":"object","properties":{"id":{"type":"string"},"stock_level_id":{"type":"string"},"line_item_id":{"type":"string"},"order_id":{"type":"string"},"variant_id":{"type":"string","nullable":true},"stock_location_id":{"type":"string","nullable":true},"quantity":{"type":"number"},"expires_at":{"type":"string"},"active":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","stock_level_id","line_item_id","order_id","variant_id","stock_location_id","quantity","expires_at","active","created_at","updated_at"],"x-typelizer":true},"StockTransferItem":{"type":"object","properties":{"id":{"type":"string"},"quantity_shipped":{"type":"number"},"quantity_received":{"type":"number"},"quantity_rejected":{"type":"number"},"quantity_over":{"type":"number"},"outstanding":{"type":"number"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"stock_transfer_id":{"type":"string","nullable":true},"variant_id":{"type":"string","nullable":true},"product_id":{"type":"string","nullable":true},"variant_name":{"type":"string","nullable":true},"variant_sku":{"type":"string","nullable":true},"options_text":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true}},"required":["id","quantity_shipped","quantity_received","quantity_rejected","quantity_over","outstanding","created_at","updated_at","stock_transfer_id","variant_id","product_id","variant_name","variant_sku","options_text","thumbnail_url"],"x-typelizer":true},"StockTransfer":{"type":"object","properties":{"id":{"type":"string"},"number":{"type":"string"},"reference":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"source_location_id":{"type":"string"},"destination_location_id":{"type":"string"},"status":{"type":"string"},"notes":{"type":"string","nullable":true},"metadata":{"type":"object"},"close_reason":{"type":"string","nullable":true},"items_count":{"type":"number"},"quantity_received_total":{"type":"number"},"quantity_rejected_total":{"type":"number"},"shipped_at":{"type":"string","nullable":true},"received_at":{"type":"string","nullable":true},"closed_short_at":{"type":"string","nullable":true},"deleted_at":{"type":"string","nullable":true},"closed_short":{"type":"boolean"},"quantity_shipped_total":{"type":"number"},"editable":{"type":"boolean"},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockTransferItem"}},"stock_receipts":{"type":"array","items":{"$ref":"#/components/schemas/StockReceipt"}},"source_location":{"$ref":"#/components/schemas/StockLocation"},"destination_location":{"$ref":"#/components/schemas/StockLocation"}},"required":["id","number","reference","created_at","updated_at","source_location_id","destination_location_id","status","notes","metadata","close_reason","items_count","quantity_received_total","quantity_rejected_total","shipped_at","received_at","closed_short_at","deleted_at","closed_short","quantity_shipped_total","editable"],"x-typelizer":true},"StoreCreditEvent":{"type":"object","properties":{"id":{"type":"string"},"action":{"type":"string"},"authorization_code":{"type":"string","nullable":true},"display_action":{"type":"string","nullable":true},"amount":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"store_credit_id":{"type":"string"},"originator_type":{"type":"string","nullable":true},"originator_id":{"type":"string","nullable":true}},"required":["id","action","authorization_code","display_action","amount","created_at","updated_at","store_credit_id","originator_type","originator_id"],"x-typelizer":true},"StoreCredit":{"type":"object","properties":{"id":{"type":"string"},"amount":{"type":"string"},"amount_used":{"type":"string"},"amount_remaining":{"type":"string"},"currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"memo":{"type":"string","nullable":true},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"amount_authorized":{"type":"string"},"outstanding":{"type":"boolean"},"customer_id":{"type":"string","nullable":true},"created_by_id":{"type":"string","nullable":true},"originator_type":{"type":"string","nullable":true},"originator_id":{"type":"string","nullable":true},"customer":{"$ref":"#/components/schemas/Customer"},"created_by":{"$ref":"#/components/schemas/AdminUser"}},"required":["id","amount","amount_used","amount_remaining","currency","memo","metadata","created_at","updated_at","amount_authorized","outstanding","customer_id","created_by_id","originator_type","originator_id"],"x-typelizer":true},"Store":{"type":"object","properties":{"id":{"type":"string"},"metadata":{"type":"object"},"name":{"type":"string"},"code":{"type":"string"},"default_currency":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"default_locale":{"type":"string"},"default_country_code":{"type":"string","nullable":true},"mail_from_address":{"type":"string","nullable":true},"customer_support_email":{"type":"string","nullable":true},"new_order_notifications_email":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"order_routing_strategy":{"type":"string","description":"Order routing strategy. Built-in: rules. Extensions may register more."},"payout_provider":{"type":"string","nullable":true,"description":"Payout provider; null uses the installation default. Built-in: system. Provider gems register more (e.g. stripe)."},"admin_locale":{"type":"string","nullable":true},"timezone":{"type":"string"},"storefront_url":{"type":"string","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"unit_system":{"type":"string","enum":["metric","imperial"]},"storefront_access":{"type":"string","enum":["public","prices_hidden","login_required"]},"guest_checkout":{"type":"boolean"},"always_include_confirm_step":{"type":"boolean"},"company_field_enabled":{"type":"boolean"},"address_requires_company":{"type":"boolean"},"address_requires_phone":{"type":"boolean"},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"]},"track_inventory_levels":{"type":"boolean"},"stock_reservations_enabled":{"type":"boolean"},"low_stock_threshold":{"type":"number"},"tax_using_ship_address":{"type":"boolean"},"track_price_history":{"type":"boolean"},"show_products_without_price":{"type":"boolean"},"disable_sku_validation":{"type":"boolean"},"pricing_provider":{"type":"string"},"inventory_provider":{"type":"string"},"pricing_provider_failure_policy":{"type":"string","enum":["fallback","strict"]},"inventory_provider_failure_policy":{"type":"string","enum":["fallback","strict"]},"default_payouts_schedule_interval":{"type":"string","enum":["daily","weekly","biweekly","monthly","manual"]},"auto_approve_sellers":{"type":"boolean"},"auto_approve_seller_products":{"type":"boolean"},"send_seller_transactional_emails":{"type":"boolean"},"document_number_format":{"type":"string","enum":["sequential","random"]},"order_number_prefix":{"type":"string"},"order_number_suffix":{"type":"string"},"order_number_sequence_start":{"type":"number"},"limit_digital_download_count":{"type":"boolean"},"digital_asset_authorized_clicks":{"type":"number"},"limit_digital_download_days":{"type":"boolean"},"digital_asset_authorized_days":{"type":"number"},"send_consumer_transactional_emails":{"type":"boolean"},"email_accent_color":{"type":"string","nullable":true},"email_background_color":{"type":"string","nullable":true},"email_card_color":{"type":"string","nullable":true},"email_text_color":{"type":"string","nullable":true},"email_heading_color":{"type":"string","nullable":true},"email_font":{"type":"string","nullable":true,"enum":["inter","system","helvetica","georgia","roboto","lato","merriweather"]},"order_number_sequence_started":{"type":"boolean"},"default_minimum_payout_amount":{"type":"string","nullable":true},"default_commission_tax_rate":{"type":"string","nullable":true},"url":{"type":"string"},"api_url":{"type":"string"},"setup_tasks":{"type":"array","items":{"$ref":"#/components/schemas/SetupTask"}},"supported_currencies":{"type":"array","items":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]}},"supported_locales":{"type":"array","items":{"type":"string"}},"available_locales":{"type":"array","items":{"type":"string"}},"logo_url":{"type":"string","nullable":true},"mailer_logo_url":{"type":"string","nullable":true}},"required":["id","metadata","name","code","default_currency","default_locale","default_country_code","mail_from_address","customer_support_email","new_order_notifications_email","created_at","updated_at","order_routing_strategy","payout_provider","admin_locale","timezone","storefront_url","weight_unit","unit_system","storefront_access","guest_checkout","always_include_confirm_step","company_field_enabled","address_requires_company","address_requires_phone","capture_method","track_inventory_levels","stock_reservations_enabled","low_stock_threshold","tax_using_ship_address","track_price_history","show_products_without_price","disable_sku_validation","pricing_provider","inventory_provider","pricing_provider_failure_policy","inventory_provider_failure_policy","default_payouts_schedule_interval","auto_approve_sellers","auto_approve_seller_products","send_seller_transactional_emails","document_number_format","order_number_prefix","order_number_suffix","order_number_sequence_start","limit_digital_download_count","digital_asset_authorized_clicks","limit_digital_download_days","digital_asset_authorized_days","send_consumer_transactional_emails","email_accent_color","email_background_color","email_card_color","email_text_color","email_heading_color","email_font","order_number_sequence_started","default_minimum_payout_amount","default_commission_tax_rate","url","api_url","setup_tasks","supported_currencies","supported_locales","available_locales","logo_url","mailer_logo_url"],"x-typelizer":true},"Supplier":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"contact_name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true,"enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"postal_code":{"type":"string","nullable":true},"purchase_orders_count":{"type":"number"},"metadata":{"type":"object"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"deleted_at":{"type":"string","nullable":true},"can_be_deleted":{"type":"boolean"}},"required":["id","name","contact_name","email","phone","notes","address1","address2","city","state_name","state_code","country_code","postal_code","purchase_orders_count","metadata","created_at","updated_at","deleted_at","can_be_deleted"],"x-typelizer":true},"TaxCategory":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"tax_code":{"type":"string","nullable":true},"description":{"type":"string","nullable":true},"is_default":{"type":"boolean"},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","name","tax_code","description","is_default","created_at","updated_at"],"x-typelizer":true},"TaxExemptionCertificate":{"type":"object","properties":{"id":{"type":"string"},"certificate_number":{"type":"string"},"reason_code":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["pending","verified","expired","revoked"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"issuing_authority":{"type":"string","nullable":true},"metadata":{"type":"object","nullable":true},"issued_at":{"type":"string"},"expires_at":{"type":"string"},"verified_at":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"},"company_id":{"type":"string"},"country_code":{"type":"string","nullable":true,"enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"state_code":{"type":"string","nullable":true},"active":{"type":"boolean"},"lapsed":{"type":"boolean"},"can_be_deleted":{"type":"boolean"},"document_filename":{"type":"string","nullable":true},"document_byte_size":{"type":"number","nullable":true},"document_url":{"type":"string","nullable":true}},"required":["id","certificate_number","reason_code","status","issuing_authority","metadata","issued_at","expires_at","verified_at","created_at","updated_at","company_id","country_code","state_code","active","lapsed","can_be_deleted","document_filename","document_byte_size","document_url"],"x-typelizer":true},"TaxIdentifier":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string","description":"Tax identifier kind, keyed to a registered validator. Built-in: eu_vat. Extensions may register more."},"value":{"type":"string"},"validation_status":{"type":"string","nullable":true,"enum":["pending","verified","unverified","unavailable","unsupported"]},"validation_evidence":{"type":"object","nullable":true},"source":{"type":"string","nullable":true,"enum":["override","company","customer"]},"validated_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"validatable":{"type":"boolean"},"customer_id":{"type":"string","nullable":true},"cart_id":{"type":"string","nullable":true},"order_id":{"type":"string","nullable":true}},"required":["id","kind","value","validation_status","validation_evidence","source","validated_at","created_at","updated_at","validatable","customer_id","cart_id","order_id"],"x-typelizer":true},"TaxLine":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"},"included":{"type":"boolean"},"credit":{"type":"boolean"},"rate":{"type":"string","nullable":true},"tax_rate_id":{"type":"string","nullable":true},"line_item_id":{"type":"string","nullable":true},"fulfillment_id":{"type":"string","nullable":true},"fee_id":{"type":"string","nullable":true},"return_line_item_id":{"type":"string","nullable":true},"claim_line_item_id":{"type":"string","nullable":true},"exchange_line_item_id":{"type":"string","nullable":true},"amount":{"type":"string"},"provider_id":{"type":"string","nullable":true},"metadata":{"type":"object","nullable":true},"taxability_reason":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true,"enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"state_code":{"type":"string","nullable":true},"data":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"original_tax_line_id":{"type":"string","nullable":true}},"required":["id","label","included","credit","rate","tax_rate_id","line_item_id","fulfillment_id","fee_id","return_line_item_id","claim_line_item_id","exchange_line_item_id","amount","provider_id","metadata","taxability_reason","country_code","state_code","data","created_at","updated_at","original_tax_line_id"],"x-typelizer":true},"TaxRate":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"included_in_price":{"type":"boolean"},"show_rate_in_label":{"type":"boolean"},"metadata":{"type":"object","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"deleted_at":{"type":"string","nullable":true},"rate":{"type":"string","nullable":true},"rate_percent":{"type":"string","nullable":true},"tax_category_id":{"type":"string","nullable":true},"store_id":{"type":"string","nullable":true},"country_code":{"type":"string","nullable":true,"enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"state_code":{"type":"string","nullable":true}},"required":["id","name","included_in_price","show_rate_in_label","metadata","created_at","updated_at","deleted_at","rate","rate_percent","tax_category_id","store_id","country_code","state_code"],"x-typelizer":true},"Variant":{"type":"object","properties":{"id":{"type":"string"},"product_id":{"type":"string"},"sku":{"type":"string","nullable":true},"options_text":{"type":"string"},"track_inventory":{"type":"boolean"},"media_count":{"type":"number"},"preorder_ships_at":{"type":"string","nullable":true},"thumbnail_url":{"type":"string","nullable":true},"purchasable":{"type":"boolean"},"in_stock":{"type":"boolean"},"backorderable":{"type":"boolean"},"preorder":{"type":"boolean"},"weight":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"depth":{"type":"number","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"minimum_order_quantity":{"type":"number","nullable":true},"order_multiple":{"type":"number","nullable":true},"purchase_unit":{"type":"string","nullable":true,"enum":["unit","carton"]},"units_per_carton":{"type":"number","nullable":true},"price":{"$ref":"#/components/schemas/Price"},"original_price":{"allOf":[{"$ref":"#/components/schemas/Price"}],"nullable":true},"seller_id":{"type":"string","nullable":true},"seller":{"$ref":"#/components/schemas/Seller"},"primary_media":{"$ref":"#/components/schemas/Media"},"media":{"type":"array","items":{"$ref":"#/components/schemas/Media"}},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValue"}},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomField"}},"prior_price":{"allOf":[{"$ref":"#/components/schemas/PriceHistory"}],"nullable":true},"external_references":{"type":"object"},"metadata":{"type":"object"},"position":{"type":"number"},"cost_currency":{"type":"string","nullable":true,"enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"barcode":{"type":"string","nullable":true},"backorder_limit":{"type":"number","nullable":true},"hs_code":{"type":"string","nullable":true},"country_of_origin":{"type":"string","nullable":true,"enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"customs_description":{"type":"string","nullable":true},"carton_weight":{"type":"string","nullable":true},"cartons_per_pallet":{"type":"number","nullable":true},"deleted_at":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"cost_price":{"type":"string","nullable":true},"preorderable":{"type":"boolean"},"tax_category_id":{"type":"string","nullable":true},"carton_package_type_id":{"type":"string","nullable":true},"units_per_pallet":{"type":"number","nullable":true},"available_stock":{"type":"number","nullable":true},"reserved_quantity":{"type":"number"},"total_on_hand":{"type":"number","nullable":true},"product_name":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"prices":{"type":"array","items":{"$ref":"#/components/schemas/Price"}},"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevel"}}},"required":["id","product_id","sku","options_text","track_inventory","media_count","preorder_ships_at","thumbnail_url","purchasable","in_stock","backorderable","preorder","weight","height","width","depth","weight_unit","dimensions_unit","minimum_order_quantity","order_multiple","purchase_unit","units_per_carton","price","original_price","seller_id","option_values","external_references","metadata","position","cost_currency","barcode","backorder_limit","hs_code","country_of_origin","customs_description","carton_weight","cartons_per_pallet","deleted_at","created_at","updated_at","cost_price","preorderable","tax_category_id","carton_package_type_id","units_per_pallet","available_stock","reserved_quantity","total_on_hand","product_name","delivery_profile_id"],"x-typelizer":true},"WebhookDelivery":{"type":"object","properties":{"id":{"type":"string"},"event_name":{"type":"string"},"event_id":{"type":"string","nullable":true},"response_code":{"type":"number","nullable":true},"execution_time":{"type":"number","nullable":true},"error_type":{"type":"string","nullable":true},"request_errors":{"type":"string","nullable":true},"response_body":{"type":"string","nullable":true},"success":{"type":"boolean","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"delivered_at":{"type":"string","nullable":true},"payload":{"type":"object","nullable":true},"webhook_endpoint_id":{"type":"string"},"webhook_endpoint_url":{"type":"string"}},"required":["id","event_name","event_id","response_code","execution_time","error_type","request_errors","response_body","success","created_at","updated_at","delivered_at","payload","webhook_endpoint_id","webhook_endpoint_url"],"x-typelizer":true},"WebhookEndpoint":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string","nullable":true},"url":{"type":"string"},"active":{"type":"boolean"},"subscriptions":{"type":"array","items":{"type":"string"}},"disabled_reason":{"type":"string","nullable":true},"created_at":{"type":"string"},"updated_at":{"type":"string"},"disabled_at":{"type":"string","nullable":true},"secret_key":{"type":"string","nullable":true},"last_delivery_at":{"type":"string","nullable":true},"recent_delivery_count":{"type":"number"},"recent_failure_count":{"type":"number"},"total_delivery_count":{"type":"number"},"successful_delivery_count":{"type":"number"},"failed_delivery_count":{"type":"number"}},"required":["id","name","url","active","subscriptions","disabled_reason","created_at","updated_at","disabled_at","secret_key","last_delivery_at","recent_delivery_count","recent_failure_count","total_delivery_count","successful_delivery_count","failed_delivery_count"],"x-typelizer":true},"WebhookEvent":{"type":"object","properties":{"name":{"type":"string"},"group":{"type":"string"},"credential_permission":{"type":"string","nullable":true},"credential":{"type":"boolean"},"deprecated":{"type":"boolean"},"replaced_by":{"type":"string","nullable":true}},"required":["name","group","credential_permission","credential","deprecated","replaced_by"],"x-typelizer":true},"CommissionRuleCategoryRulePreferences":{"type":"object","properties":{"category_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^ctg_[A-Za-z0-9]+$","x-spree-prefix":"ctg"},"default":[]}},"additionalProperties":false},"CommissionRuleItemTotalRulePreferences":{"type":"object","properties":{"min_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"max_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"additionalProperties":false},"CommissionRuleProductRulePreferences":{"type":"object","properties":{},"additionalProperties":false},"CommissionRuleSellerRulePreferences":{"type":"object","properties":{"seller_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^sel_[A-Za-z0-9]+$","x-spree-prefix":"sel"},"default":[]}},"additionalProperties":false},"CommissionRulePreferences":{"description":"Settings of a commission rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/CommissionRuleCategoryRulePreferences"},{"$ref":"#/components/schemas/CommissionRuleItemTotalRulePreferences"},{"$ref":"#/components/schemas/CommissionRuleProductRulePreferences"},{"$ref":"#/components/schemas/CommissionRuleSellerRulePreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"category_rule":"#/components/schemas/CommissionRuleCategoryRulePreferences","item_total_rule":"#/components/schemas/CommissionRuleItemTotalRulePreferences","product_rule":"#/components/schemas/CommissionRuleProductRulePreferences","seller_rule":"#/components/schemas/CommissionRuleSellerRulePreferences"}},"DeliveryCalculatorDigitalDeliveryPreferences":{"type":"object","properties":{"amounts":{"type":"object","additionalProperties":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"default":{},"x-spree-property-names":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorFlatPercentItemTotalPreferences":{"type":"object","properties":{"flat_percent":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"}},"additionalProperties":false},"DeliveryCalculatorFlatRatePreferences":{"type":"object","properties":{"amounts":{"type":"object","additionalProperties":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"default":{},"x-spree-property-names":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorFlexiRatePreferences":{"type":"object","properties":{"first_item":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"additional_item":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"max_items":{"type":"integer","default":0},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorPerItemPreferences":{"type":"object","properties":{"amounts":{"type":"object","additionalProperties":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"default":{},"x-spree-property-names":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorPriceSackPreferences":{"type":"object","properties":{"minimal_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"normal_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"discount_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"DeliveryCalculatorPreferences":{"description":"Settings of a delivery calculator, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/DeliveryCalculatorDigitalDeliveryPreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorFlatPercentItemTotalPreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorFlatRatePreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorFlexiRatePreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorPerItemPreferences"},{"$ref":"#/components/schemas/DeliveryCalculatorPriceSackPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"digital_delivery":"#/components/schemas/DeliveryCalculatorDigitalDeliveryPreferences","flat_percent_item_total":"#/components/schemas/DeliveryCalculatorFlatPercentItemTotalPreferences","flat_rate":"#/components/schemas/DeliveryCalculatorFlatRatePreferences","flexi_rate":"#/components/schemas/DeliveryCalculatorFlexiRatePreferences","per_item":"#/components/schemas/DeliveryCalculatorPerItemPreferences","price_sack":"#/components/schemas/DeliveryCalculatorPriceSackPreferences"}},"DeliveryMethodRuleChannelRulePreferences":{"type":"object","properties":{"channel_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^ch_[A-Za-z0-9]+$","x-spree-prefix":"ch"},"default":[]}},"additionalProperties":false},"DeliveryMethodRuleCompanyRulePreferences":{"type":"object","properties":{"company_orders_only":{"type":"boolean","default":true}},"additionalProperties":false},"DeliveryMethodRuleExcludedProductsRulePreferences":{"type":"object","properties":{},"additionalProperties":false},"DeliveryMethodRuleItemTotalRulePreferences":{"type":"object","properties":{"minimum_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"maximum_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"additionalProperties":false},"DeliveryMethodRuleVolumeRulePreferences":{"type":"object","properties":{"minimum_volume":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"maximum_volume":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"additionalProperties":false},"DeliveryMethodRuleWeightRulePreferences":{"type":"object","properties":{"minimum_weight":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"maximum_weight":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"additionalProperties":false},"DeliveryMethodRulePreferences":{"description":"Settings of a delivery method rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/DeliveryMethodRuleChannelRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleCompanyRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleExcludedProductsRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleItemTotalRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleVolumeRulePreferences"},{"$ref":"#/components/schemas/DeliveryMethodRuleWeightRulePreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"channel_rule":"#/components/schemas/DeliveryMethodRuleChannelRulePreferences","company_rule":"#/components/schemas/DeliveryMethodRuleCompanyRulePreferences","excluded_products_rule":"#/components/schemas/DeliveryMethodRuleExcludedProductsRulePreferences","item_total_rule":"#/components/schemas/DeliveryMethodRuleItemTotalRulePreferences","volume_rule":"#/components/schemas/DeliveryMethodRuleVolumeRulePreferences","weight_rule":"#/components/schemas/DeliveryMethodRuleWeightRulePreferences"}},"IntegrationPreferences":{"description":"Settings of a integration, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{}},"OrderRoutingRuleDefaultLocationPreferences":{"type":"object","properties":{},"additionalProperties":false},"OrderRoutingRuleMinimizeSplitsPreferences":{"type":"object","properties":{},"additionalProperties":false},"OrderRoutingRulePreferredLocationPreferences":{"type":"object","properties":{},"additionalProperties":false},"OrderRoutingRulePreferences":{"description":"Settings of a order routing rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/OrderRoutingRuleDefaultLocationPreferences"},{"$ref":"#/components/schemas/OrderRoutingRuleMinimizeSplitsPreferences"},{"$ref":"#/components/schemas/OrderRoutingRulePreferredLocationPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"default_location":"#/components/schemas/OrderRoutingRuleDefaultLocationPreferences","minimize_splits":"#/components/schemas/OrderRoutingRuleMinimizeSplitsPreferences","preferred_location":"#/components/schemas/OrderRoutingRulePreferredLocationPreferences"}},"PaymentMethodBogusPreferences":{"type":"object","properties":{"dummy_key":{"type":"string","default":"PUBLICKEY123"},"dummy_secret_key":{"type":"string","x-spree-secret":true,"nullable":true}},"additionalProperties":false},"PaymentMethodCheckPreferences":{"type":"object","properties":{},"additionalProperties":false},"PaymentMethodCustomPaymentSourceMethodPreferences":{"type":"object","properties":{},"additionalProperties":false},"PaymentMethodStoreCreditPreferences":{"type":"object","properties":{},"additionalProperties":false},"PaymentMethodPreferences":{"description":"Settings of a payment method, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/PaymentMethodBogusPreferences"},{"$ref":"#/components/schemas/PaymentMethodCheckPreferences"},{"$ref":"#/components/schemas/PaymentMethodCustomPaymentSourceMethodPreferences"},{"$ref":"#/components/schemas/PaymentMethodStoreCreditPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"bogus":"#/components/schemas/PaymentMethodBogusPreferences","check":"#/components/schemas/PaymentMethodCheckPreferences","custom_payment_source_method":"#/components/schemas/PaymentMethodCustomPaymentSourceMethodPreferences","store_credit":"#/components/schemas/PaymentMethodStoreCreditPreferences"}},"PriceRuleChannelRulePreferences":{"type":"object","properties":{"channel_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^ch_[A-Za-z0-9]+$","x-spree-prefix":"ch"},"default":[]}},"additionalProperties":false},"PriceRuleCustomerGroupRulePreferences":{"type":"object","properties":{"customer_group_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^cg_[A-Za-z0-9]+$","x-spree-prefix":"cg"},"default":[]}},"additionalProperties":false},"PriceRuleMarketRulePreferences":{"type":"object","properties":{"market_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^mkt_[A-Za-z0-9]+$","x-spree-prefix":"mkt"},"default":[]}},"additionalProperties":false},"PriceRuleUserRulePreferences":{"type":"object","properties":{"user_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^cust_[A-Za-z0-9]+$","x-spree-prefix":"cust"},"default":[]}},"additionalProperties":false},"PriceRuleVolumeRulePreferences":{"type":"object","properties":{"min_quantity":{"type":"integer","default":1},"max_quantity":{"type":"integer","nullable":true}},"additionalProperties":false},"PriceRulePreferences":{"description":"Settings of a price rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/PriceRuleChannelRulePreferences"},{"$ref":"#/components/schemas/PriceRuleCustomerGroupRulePreferences"},{"$ref":"#/components/schemas/PriceRuleMarketRulePreferences"},{"$ref":"#/components/schemas/PriceRuleUserRulePreferences"},{"$ref":"#/components/schemas/PriceRuleVolumeRulePreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"channel_rule":"#/components/schemas/PriceRuleChannelRulePreferences","customer_group_rule":"#/components/schemas/PriceRuleCustomerGroupRulePreferences","market_rule":"#/components/schemas/PriceRuleMarketRulePreferences","user_rule":"#/components/schemas/PriceRuleUserRulePreferences","volume_rule":"#/components/schemas/PriceRuleVolumeRulePreferences"}},"PromotionCalculatorFlatPercentItemTotalPreferences":{"type":"object","properties":{"flat_percent":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"}},"additionalProperties":false},"PromotionCalculatorFlatRatePreferences":{"type":"object","properties":{"amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"},"apply_only_on_full_priced_items":{"type":"boolean","default":false}},"additionalProperties":false},"PromotionCalculatorFlexiRatePreferences":{"type":"object","properties":{"first_item":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"additional_item":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"max_items":{"type":"integer","default":0},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"},"apply_only_on_full_priced_items":{"type":"boolean","default":false}},"additionalProperties":false},"PromotionCalculatorPercentOnLineItemPreferences":{"type":"object","properties":{"percent":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"apply_only_on_full_priced_items":{"type":"boolean","default":false}},"additionalProperties":false},"PromotionCalculatorTieredFlatRatePreferences":{"type":"object","properties":{"tiers":{"type":"array","items":{"type":"object","properties":{"threshold":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"value":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$"}},"required":["threshold","value"],"additionalProperties":false},"default":[]},"base_amount":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"},"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$"}},"additionalProperties":false},"PromotionCalculatorTieredPercentPreferences":{"type":"object","properties":{"tiers":{"type":"array","items":{"type":"object","properties":{"threshold":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$"},"value":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$"}},"required":["threshold","value"],"additionalProperties":false},"default":[]},"base_percent":{"type":"string","pattern":"^-?\\d+(\\.\\d+)?$","default":"0"}},"additionalProperties":false},"PromotionCalculatorPreferences":{"description":"Settings of a promotion calculator, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/PromotionCalculatorFlatPercentItemTotalPreferences"},{"$ref":"#/components/schemas/PromotionCalculatorFlatRatePreferences"},{"$ref":"#/components/schemas/PromotionCalculatorFlexiRatePreferences"},{"$ref":"#/components/schemas/PromotionCalculatorPercentOnLineItemPreferences"},{"$ref":"#/components/schemas/PromotionCalculatorTieredFlatRatePreferences"},{"$ref":"#/components/schemas/PromotionCalculatorTieredPercentPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"flat_percent_item_total":"#/components/schemas/PromotionCalculatorFlatPercentItemTotalPreferences","flat_rate":"#/components/schemas/PromotionCalculatorFlatRatePreferences","flexi_rate":"#/components/schemas/PromotionCalculatorFlexiRatePreferences","percent_on_line_item":"#/components/schemas/PromotionCalculatorPercentOnLineItemPreferences","tiered_flat_rate":"#/components/schemas/PromotionCalculatorTieredFlatRatePreferences","tiered_percent":"#/components/schemas/PromotionCalculatorTieredPercentPreferences"}},"PromotionRuleCategoryPreferences":{"type":"object","properties":{"match_policy":{"type":"string","enum":["any","all"],"default":"any"}},"additionalProperties":false},"PromotionRuleChannelPreferences":{"type":"object","properties":{"channel_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^ch_[A-Za-z0-9]+$","x-spree-prefix":"ch"},"default":[]}},"additionalProperties":false},"PromotionRuleCountryPreferences":{"type":"object","properties":{"country_codes":{"type":"array","items":{"type":"string","format":"iso-country","pattern":"^[A-Z]{2}$"},"default":[]},"country_id":{"type":"integer","nullable":true},"country_code":{"type":"string","format":"iso-country","pattern":"^[A-Z]{2}$","nullable":true}},"additionalProperties":false},"PromotionRuleCurrencyPreferences":{"type":"object","properties":{"currency":{"type":"string","format":"currency","pattern":"^[A-Z]{3}$","nullable":true}},"additionalProperties":false},"PromotionRuleCustomerPreferences":{"type":"object","properties":{},"additionalProperties":false},"PromotionRuleCustomerGroupPreferences":{"type":"object","properties":{"customer_group_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^cg_[A-Za-z0-9]+$","x-spree-prefix":"cg"},"default":[]}},"additionalProperties":false},"PromotionRuleCustomerLoggedInPreferences":{"type":"object","properties":{},"additionalProperties":false},"PromotionRuleFirstOrderPreferences":{"type":"object","properties":{},"additionalProperties":false},"PromotionRuleItemTotalPreferences":{"type":"object","properties":{"amount_min":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","default":"100"},"operator_min":{"type":"string","default":">"},"amount_max":{"type":"string","format":"money","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"operator_max":{"type":"string","default":"<"}},"additionalProperties":false},"PromotionRuleMarketPreferences":{"type":"object","properties":{"market_ids":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^mkt_[A-Za-z0-9]+$","x-spree-prefix":"mkt"},"default":[]}},"additionalProperties":false},"PromotionRuleOneUsePerUserPreferences":{"type":"object","properties":{},"additionalProperties":false},"PromotionRuleOptionValuePreferences":{"type":"object","properties":{"match_policy":{"type":"string","enum":["any"],"default":"any"},"eligible_values":{"type":"array","items":{"type":"string","format":"prefixed-id","pattern":"^optval_[A-Za-z0-9]+$","x-spree-prefix":"optval"},"default":[]}},"additionalProperties":false},"PromotionRuleProductPreferences":{"type":"object","properties":{"match_policy":{"type":"string","enum":["any","all","none"],"default":"any"}},"additionalProperties":false},"PromotionRulePreferences":{"description":"Settings of a promotion rule, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/PromotionRuleCategoryPreferences"},{"$ref":"#/components/schemas/PromotionRuleChannelPreferences"},{"$ref":"#/components/schemas/PromotionRuleCountryPreferences"},{"$ref":"#/components/schemas/PromotionRuleCurrencyPreferences"},{"$ref":"#/components/schemas/PromotionRuleCustomerPreferences"},{"$ref":"#/components/schemas/PromotionRuleCustomerGroupPreferences"},{"$ref":"#/components/schemas/PromotionRuleCustomerLoggedInPreferences"},{"$ref":"#/components/schemas/PromotionRuleFirstOrderPreferences"},{"$ref":"#/components/schemas/PromotionRuleItemTotalPreferences"},{"$ref":"#/components/schemas/PromotionRuleMarketPreferences"},{"$ref":"#/components/schemas/PromotionRuleOneUsePerUserPreferences"},{"$ref":"#/components/schemas/PromotionRuleOptionValuePreferences"},{"$ref":"#/components/schemas/PromotionRuleProductPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"category":"#/components/schemas/PromotionRuleCategoryPreferences","channel":"#/components/schemas/PromotionRuleChannelPreferences","country":"#/components/schemas/PromotionRuleCountryPreferences","currency":"#/components/schemas/PromotionRuleCurrencyPreferences","customer":"#/components/schemas/PromotionRuleCustomerPreferences","customer_group":"#/components/schemas/PromotionRuleCustomerGroupPreferences","customer_logged_in":"#/components/schemas/PromotionRuleCustomerLoggedInPreferences","first_order":"#/components/schemas/PromotionRuleFirstOrderPreferences","item_total":"#/components/schemas/PromotionRuleItemTotalPreferences","market":"#/components/schemas/PromotionRuleMarketPreferences","one_use_per_user":"#/components/schemas/PromotionRuleOneUsePerUserPreferences","option_value":"#/components/schemas/PromotionRuleOptionValuePreferences","product":"#/components/schemas/PromotionRuleProductPreferences"}},"SellerRequirementAcceptTermsPreferences":{"type":"object","properties":{"terms_body":{"type":"string","x-spree-widget":"textarea","nullable":true},"terms_effective_from":{"type":"string","format":"date","nullable":true},"terms_url":{"type":"string","nullable":true}},"additionalProperties":false},"SellerRequirementAttestationPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementBillingAddressPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementCompleteProfilePreferences":{"type":"object","properties":{"require_about":{"type":"boolean","default":true},"require_logo":{"type":"boolean","default":true},"require_cover_photo":{"type":"boolean","default":false},"require_contact_email":{"type":"boolean","default":true}},"additionalProperties":false},"SellerRequirementDeliveryMethodPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementDocumentPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementMinimumProductsPreferences":{"type":"object","properties":{"minimum_count":{"type":"integer","default":1}},"additionalProperties":false},"SellerRequirementOperatorReviewPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementPackageTypePreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementPayoutAccountPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementPolicyPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementRequiredCustomFieldsPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementReturnsAddressPreferences":{"type":"object","properties":{},"additionalProperties":false},"SellerRequirementPreferences":{"description":"Settings of a seller requirement, shaped by its `type` (see `x-spree-preferences-by-type`). A type an extension registers is a plain object, described by the `schema` its `/types` entry carries.","anyOf":[{"$ref":"#/components/schemas/SellerRequirementAcceptTermsPreferences"},{"$ref":"#/components/schemas/SellerRequirementAttestationPreferences"},{"$ref":"#/components/schemas/SellerRequirementBillingAddressPreferences"},{"$ref":"#/components/schemas/SellerRequirementCompleteProfilePreferences"},{"$ref":"#/components/schemas/SellerRequirementDeliveryMethodPreferences"},{"$ref":"#/components/schemas/SellerRequirementDocumentPreferences"},{"$ref":"#/components/schemas/SellerRequirementMinimumProductsPreferences"},{"$ref":"#/components/schemas/SellerRequirementOperatorReviewPreferences"},{"$ref":"#/components/schemas/SellerRequirementPackageTypePreferences"},{"$ref":"#/components/schemas/SellerRequirementPayoutAccountPreferences"},{"$ref":"#/components/schemas/SellerRequirementPolicyPreferences"},{"$ref":"#/components/schemas/SellerRequirementRequiredCustomFieldsPreferences"},{"$ref":"#/components/schemas/SellerRequirementReturnsAddressPreferences"},{"type":"object","additionalProperties":true}],"x-spree-preferences-by-type":{"accept_terms":"#/components/schemas/SellerRequirementAcceptTermsPreferences","attestation":"#/components/schemas/SellerRequirementAttestationPreferences","billing_address":"#/components/schemas/SellerRequirementBillingAddressPreferences","complete_profile":"#/components/schemas/SellerRequirementCompleteProfilePreferences","delivery_method":"#/components/schemas/SellerRequirementDeliveryMethodPreferences","document":"#/components/schemas/SellerRequirementDocumentPreferences","minimum_products":"#/components/schemas/SellerRequirementMinimumProductsPreferences","operator_review":"#/components/schemas/SellerRequirementOperatorReviewPreferences","package_type":"#/components/schemas/SellerRequirementPackageTypePreferences","payout_account":"#/components/schemas/SellerRequirementPayoutAccountPreferences","policy":"#/components/schemas/SellerRequirementPolicyPreferences","required_custom_fields":"#/components/schemas/SellerRequirementRequiredCustomFieldsPreferences","returns_address":"#/components/schemas/SellerRequirementReturnsAddressPreferences"}},"DeliveryMethodCalculator":{"type":"object","description":"How the delivery method prices a shipment","properties":{"type":{"type":"string","description":"Wire shorthand for the calculator subclass"},"preferences":{"$ref":"#/components/schemas/DeliveryCalculatorPreferences"}},"required":["type","preferences"]},"PromotionActionCalculator":{"type":"object","description":"The action's nested calculator (when the action carries one — null for actions like `free_shipping`)","properties":{"type":{"type":"string","description":"Wire shorthand for the calculator subclass"},"preferences":{"$ref":"#/components/schemas/PromotionCalculatorPreferences"}},"required":["type","preferences"]},"CurrencyCode":{"type":"string","enum":["AED","AFN","ALL","AMD","ANG","AOA","ARS","AUD","AWG","AZN","BAM","BBD","BDT","BGN","BHD","BIF","BMD","BND","BOB","BRL","BSD","BTN","BWP","BYN","BYR","BZD","CAD","CDF","CHF","CLF","CLP","CNY","COP","CRC","CUC","CUP","CVE","CZK","DJF","DKK","DOP","DZD","EEK","EGP","ERN","ETB","EUR","FJD","FKP","GBP","GEL","GHS","GIP","GMD","GNF","GTQ","GYD","HKD","HNL","HRK","HTG","HUF","IDR","ILS","INR","IQD","IRR","ISK","JMD","JOD","JPY","KES","KGS","KHR","KMF","KPW","KRW","KWD","KYD","KZT","LAK","LBP","LKR","LRD","LSL","LTL","LVL","LYD","MAD","MDL","MGA","MKD","MMK","MNT","MOP","MRO","MRU","MTL","MUR","MVR","MWK","MXN","MYR","MZN","NAD","NGN","NIO","NOK","NPR","NZD","OMR","PAB","PEN","PGK","PHP","PKR","PLN","PYG","QAR","RON","RSD","RUB","RWF","SAR","SBD","SCR","SDG","SEK","SGD","SHP","SKK","SLE","SLL","SOS","SRD","SSP","STD","STN","SVC","SYP","SZL","THB","TJS","TMM","TMT","TND","TOP","TRY","TTD","TWD","TZS","UAH","UGX","USD","UYI","UYU","UYW","UZS","VED","VEF","VES","VND","VUV","WST","XAF","XCD","XCG","XOF","XPF","YER","ZAR","ZMK","ZMW","ZWD","ZWG","ZWL","ZWN","ZWR"]},"CountryCode":{"type":"string","enum":["AD","AE","AF","AG","AI","AL","AM","AO","AR","AS","AT","AU","AW","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GT","GU","GW","GY","HK","HN","HR","HT","HU","ID","IE","IL","IM","IN","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TC","TD","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","YE","YT","ZA","ZM","ZW"]},"AddressInputParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"company":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"phone":{"type":"string"},"label":{"type":"string"},"zipcode":{"type":"string","description":"Legacy spelling of `postal_code`; send only one of the two."},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"ISO 3166-1 alpha-2 code, such as `US`."},"state_code":{"type":"string","description":"The state or province abbreviation, such as `NY`."},"state_name":{"type":"string","description":"For countries without states in the database."},"alternative_phone":{"type":"string"}}},"AdminUserUpdateParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"role_ids":{"type":"array","items":{"type":"string"},"description":"Role IDs of the current store the user should hold. Replaces the user's roles on this store; an empty list removes them all."}}},"AllowedOriginCreateParams":{"type":"object","properties":{"origin":{"type":"string","description":"Origin to allow in admin CORS preflight checks: a bare `scheme://host[:port]` (no path, query or fragment) using `http` or `https`."}},"required":["origin"]},"AllowedOriginUpdateParams":{"type":"object","properties":{"origin":{"type":"string","description":"Origin to allow in admin CORS preflight checks: a bare `scheme://host[:port]` (no path, query or fragment) using `http` or `https`."}}},"ApiKeyCreateParams":{"type":"object","properties":{"name":{"type":"string"},"key_type":{"type":"string","enum":["publishable","secret"]},"scopes":{"type":"array","items":{"type":"string"},"description":"Required for secret keys. You can only grant scopes you hold yourself. Fixed once created: to change them, create a new key and revoke the old one."},"channel_id":{"type":"string","description":"Binds a publishable key to one channel of the store (`ch_...`), so it rejects requests for other channels. Fixed once created; omit it for a store-wide key."}},"required":["name","key_type"]},"ApiKeyUpdateParams":{"type":"object","properties":{"name":{"type":"string"}},"required":["name"]},"BulkTagsParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"},"description":"The records to change. Records the caller cannot update are skipped; an empty list changes nothing."},"tags":{"type":"array","items":{"type":"string"}}},"required":["ids","tags"]},"CatalogAssignParams":{"type":"object","properties":{"assignable_type":{"type":"string","enum":["customer_group","company"],"description":"Buyer audiences only. A company assignment covers its subtree."},"assignable_id":{"type":"string"}},"required":["assignable_type","assignable_id"]},"CatalogAssignmentParams":{"type":"object","properties":{"assignable_type":{"type":"string","enum":["customer_group","company"],"description":"Buyer audiences only. A company assignment covers its subtree."},"assignable_id":{"type":"string"}},"required":["assignable_type","assignable_id"]},"CatalogOrderMinimumParams":{"type":"object","properties":{"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"ISO 4217 code. Required on create; one minimum per currency."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"}}},"CatalogParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","description":"Internal note on what the agreement is, never shown to shoppers.","nullable":true},"active":{"type":"boolean"},"position":{"type":"integer"},"minimum_order_quantity":{"type":"integer","description":"The catalog-wide quantity terms, between a variant's own rule and a per-variant override. Null leaves the field to the variant's own rule.","nullable":true},"order_multiple":{"type":"integer","description":"The catalog-wide quantity terms, between a variant's own rule and a per-variant override. Null leaves the field to the variant's own rule.","nullable":true},"metadata":{"type":"object","additionalProperties":true},"assignments":{"type":"array","items":{"$ref":"#/components/schemas/CatalogAssignmentParams"},"description":"The whole audience. An entry left out is withdrawn; omitting the key leaves the audience alone."},"order_minimums":{"type":"array","items":{"$ref":"#/components/schemas/CatalogOrderMinimumParams"},"description":"The whole order-minimum set. A currency left out has its minimum lifted; omitting the key leaves them alone."},"price_list":{"allOf":[{"$ref":"#/components/schemas/CatalogPriceListParams"}],"description":"The price list this catalog prices through, written inline: an object creates the owned list or updates it. Null deletes the list (a soft delete). Omit the key, or send `{}`, to leave the pricing alone. A catalog with an empty assortment prices without hiding anything; curate or import products to make it restrictive.","nullable":true}}},"CatalogPriceListParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"status":{"type":"string"},"match_policy":{"type":"string"},"starts_at":{"type":"string","format":"date-time","nullable":true},"ends_at":{"type":"string","format":"date-time","nullable":true},"price_adjustment_percentage":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Signed: negative discounts off base prices, positive marks up.","nullable":true},"adjust_compare_at":{"type":"boolean"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PriceListRuleParams"},"description":"Contextual rules, in practice a `volume_rule`. Audience rules are left as they are, and an empty list clears the contextual rules."},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceListPriceOverrideParams"},"description":"Explicit per-variant amounts. An empty list clears them, which is what switching to a percentage sends."},"price_adjustment_tiers":{"type":"array","items":{"$ref":"#/components/schemas/PriceAdjustmentTierParams"},"description":"Quantity bands on the percentage. The payload is the whole ladder, so an empty list clears it."}}},"CatalogProductTermsParams":{"type":"object","properties":{"terms":{"type":"object","additionalProperties":true,"description":"Quantity terms keyed by product: `{ minimum_order_quantity, order_multiple }`, each a whole number or null. A product whose pair is both null has its terms cleared; a product not yet in the assortment is added."}},"required":["terms"]},"CategoryCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"parent_id":{"type":"string","description":"The parent category. Omitted or null, a new category goes to the top level and an existing one keeps its parent: moving one to the top level is the reposition endpoint.","nullable":true},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"permalink":{"type":"string"},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the landscape image, or null to remove it.","nullable":true},"square_image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the square image, or null to remove it.","nullable":true},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}},"required":["name"]},"CategoryRepositionParams":{"type":"object","properties":{"new_parent_id":{"type":"string","description":"The new parent. Omit or null to move the category to the top level.","nullable":true},"new_position":{"type":"integer","description":"0-based index among the new parent's children."}},"required":["new_position"]},"CategoryUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"parent_id":{"type":"string","description":"The parent category. Omitted or null, a new category goes to the top level and an existing one keeps its parent: moving one to the top level is the reposition endpoint.","nullable":true},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"permalink":{"type":"string"},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the landscape image, or null to remove it.","nullable":true},"square_image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the square image, or null to remove it.","nullable":true},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}}},"ChannelAddProductsParams":{"type":"object","properties":{"product_ids":{"type":"array","items":{"type":"string"}},"published_at":{"type":"string","format":"date-time","description":"When the publications go live. Null means immediately.","nullable":true},"unpublished_at":{"type":"string","format":"date-time","description":"When the publications come down. Null means never.","nullable":true}},"required":["product_ids"]},"ChannelCreateParams":{"type":"object","properties":{"name":{"type":"string"},"code":{"type":"string","description":"URL-safe slug, derived from `name` when blank (`Point of Sale` becomes `point-of-sale`)."},"active":{"type":"boolean"},"default":{"type":"boolean"},"order_routing_strategy":{"type":"string","description":"Order routing strategy shorthand (built-in: `rules`). Null inherits the store setting.","nullable":true},"storefront_access":{"type":"string","enum":["public","prices_hidden","login_required"],"description":"What anonymous visitors can see. Null inherits the store setting.","nullable":true},"guest_checkout":{"type":"boolean","description":"Whether guests can check out without an account. Null inherits the store setting.","nullable":true},"default_catalog_id":{"type":"string","description":"Catalog (`cat_...`) shown to shoppers no company or customer group catalog covers. Null means every product published on the channel.","nullable":true},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Stock locations (`sloc_...`) that fulfill this channel. Replaces the whole set; an empty list means every location of the store."}},"required":["name"]},"ChannelRemoveProductsParams":{"type":"object","properties":{"product_ids":{"type":"array","items":{"type":"string"}}},"required":["product_ids"]},"ChannelUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"code":{"type":"string","description":"URL-safe slug, derived from `name` when blank (`Point of Sale` becomes `point-of-sale`)."},"active":{"type":"boolean"},"default":{"type":"boolean"},"order_routing_strategy":{"type":"string","description":"Order routing strategy shorthand (built-in: `rules`). Null inherits the store setting.","nullable":true},"storefront_access":{"type":"string","enum":["public","prices_hidden","login_required"],"description":"What anonymous visitors can see. Null inherits the store setting.","nullable":true},"guest_checkout":{"type":"boolean","description":"Whether guests can check out without an account. Null inherits the store setting.","nullable":true},"default_catalog_id":{"type":"string","description":"Catalog (`cat_...`) shown to shoppers no company or customer group catalog covers. Null means every product published on the channel.","nullable":true},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Stock locations (`sloc_...`) that fulfill this channel. Replaces the whole set; an empty list means every location of the store."}}},"ClaimCancelParams":{"type":"object","properties":{"reason":{"type":"string","description":"A note on why the claim was canceled."}}},"ClaimCreateParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"line_item_id":{"type":"string"},"quantity":{"type":"integer"},"description":{"type":"string"},"send_replacement":{"type":"boolean"},"replacement_variant_id":{"type":"string","description":"Defaults to the variant that was bought."},"refund_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"}},"required":["line_item_id","quantity"]},"description":"Affected items, and how each should be made right."},"reason_id":{"type":"string","description":"One of the store's claim reasons."},"memo":{"type":"string"}},"required":["items"]},"ClaimDenyParams":{"type":"object","properties":{"reason":{"type":"string","description":"Recorded on the claim for the customer."}}},"ClaimResolveParams":{"type":"object","properties":{"resolution":{"type":"string","enum":["refund","replacement","refund_and_replacement"],"description":"Money back, a replacement shipment, or both."},"refund_method":{"type":"string","enum":["original_payment","store_credit"],"description":"Defaults to `store_credit`."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Defaults to the claim total."},"replacement_line_item_ids":{"type":"array","items":{"type":"string"},"description":"Which claim lines to send a replacement for. Omit to keep what the claim was opened with."}},"required":["resolution"]},"ClaimUpdateParams":{"type":"object","properties":{"reason_id":{"type":"string","description":"One of the store's claim reasons."},"memo":{"type":"string"},"metadata":{"type":"object","additionalProperties":true}}},"CollectionCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"permalink":{"type":"string"},"position":{"type":"integer","description":"1-based position among the store's collections; the server shifts its siblings. The nested products reposition endpoints, unlike this, take 0-based indexes."},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the landscape image, or null to remove it.","nullable":true},"square_image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the square image, or null to remove it.","nullable":true},"automatic":{"type":"boolean","description":"When true, membership is materialized from `rules` instead of curated by hand."},"rules_match_policy":{"type":"string","enum":["all","any"],"description":"Whether a product must match all rules or any of them. Defaults to `all`."},"sort_order":{"type":"string","enum":["manual","best_selling","price asc","price desc","available_on desc","available_on asc","name asc","name desc"],"description":"Default product sort for the storefront listing; a shopper's own sort wins. Defaults to `manual`."},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CollectionRuleParams"},"description":"The complete desired rule set. Entries with an `id` update, entries without one are created, and existing rules left out are removed."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}},"required":["name"]},"CollectionRuleParams":{"type":"object","properties":{"id":{"type":"string","description":"Omit to create a new rule."},"type":{"type":"string","description":"Wire shorthand for the rule kind, from the collection rule types endpoint."},"value":{"type":"string"},"match_policy":{"type":"string","enum":["is_equal_to","is_not_equal_to","contains","does_not_contain"]}}},"CollectionUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"permalink":{"type":"string"},"position":{"type":"integer","description":"1-based position among the store's collections; the server shifts its siblings. The nested products reposition endpoints, unlike this, take 0-based indexes."},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the landscape image, or null to remove it.","nullable":true},"square_image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the square image, or null to remove it.","nullable":true},"automatic":{"type":"boolean","description":"When true, membership is materialized from `rules` instead of curated by hand."},"rules_match_policy":{"type":"string","enum":["all","any"],"description":"Whether a product must match all rules or any of them. Defaults to `all`."},"sort_order":{"type":"string","enum":["manual","best_selling","price asc","price desc","available_on desc","available_on asc","name asc","name desc"],"description":"Default product sort for the storefront listing; a shopper's own sort wins. Defaults to `manual`."},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CollectionRuleParams"},"description":"The complete desired rule set. Entries with an `id` update, entries without one are created, and existing rules left out are removed."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}}},"CommissionRateCreateParams":{"type":"object","properties":{"name":{"type":"string"},"code":{"type":"string","description":"Your own identifier for this rate; unique per store.","nullable":true},"enabled":{"type":"boolean"},"position":{"type":"integer","description":"Place in the list. Rates resolve top-down and the first whose rules match wins, so 1 is tried first. New rates are created at the top; send this to move one. A rate with no rules matches every sale, so the marketplace default belongs at the bottom."},"kind":{"type":"string","enum":["percentage","fixed"],"description":"`percentage` charges a share of the sale; `fixed` charges a flat fee."},"value":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"A percentage (10 = 10%) or a flat amount, per `kind`."},"tax_inclusive":{"type":"boolean","description":"Charge on the price including the customer's VAT. Left off, commission is charged on the seller's net revenue, which is the usual basis where the fee is taxed as its own supply."},"include_shipping":{"type":"boolean","description":"Also charge commission on the seller's delivery revenue. Percentage rates only."},"commission_tax_rate":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"VAT on the commission itself, as a fraction rather than a percentage. Null lets the store's tax engine answer for the seller's jurisdiction.","nullable":true},"metadata":{"type":"object","additionalProperties":true},"amounts":{"type":"object","additionalProperties":true,"description":"What a flat fee charges, keyed by currency, as decimal strings. A sale in a currency with no amount falls to the next matching rate. Replaces the whole set."},"bounds":{"type":"object","additionalProperties":true,"description":"The floor and cap a percentage charges within, keyed by currency: `{ min_amount, max_amount }` decimal strings. A sale in a currency with no bounds is charged unbounded. Replaces the whole set."},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CommissionRuleDraftParams"},"description":"The full targeting; what you send replaces what the rate holds."}},"required":["name","kind","value"]},"CommissionRateUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"code":{"type":"string","description":"Your own identifier for this rate; unique per store.","nullable":true},"enabled":{"type":"boolean"},"position":{"type":"integer","description":"Place in the list. Rates resolve top-down and the first whose rules match wins, so 1 is tried first. New rates are created at the top; send this to move one. A rate with no rules matches every sale, so the marketplace default belongs at the bottom."},"kind":{"type":"string","enum":["percentage","fixed"],"description":"`percentage` charges a share of the sale; `fixed` charges a flat fee."},"value":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"A percentage (10 = 10%) or a flat amount, per `kind`."},"tax_inclusive":{"type":"boolean","description":"Charge on the price including the customer's VAT. Left off, commission is charged on the seller's net revenue, which is the usual basis where the fee is taxed as its own supply."},"include_shipping":{"type":"boolean","description":"Also charge commission on the seller's delivery revenue. Percentage rates only."},"commission_tax_rate":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"VAT on the commission itself, as a fraction rather than a percentage. Null lets the store's tax engine answer for the seller's jurisdiction.","nullable":true},"metadata":{"type":"object","additionalProperties":true},"amounts":{"type":"object","additionalProperties":true,"description":"What a flat fee charges, keyed by currency, as decimal strings. A sale in a currency with no amount falls to the next matching rate. Replaces the whole set."},"bounds":{"type":"object","additionalProperties":true,"description":"The floor and cap a percentage charges within, keyed by currency: `{ min_amount, max_amount }` decimal strings. A sale in a currency with no bounds is charged unbounded. Replaces the whole set."},"rules":{"type":"array","items":{"$ref":"#/components/schemas/CommissionRuleDraftParams"},"description":"The full targeting; what you send replaces what the rate holds."}}},"CommissionRuleDraftParams":{"type":"object","properties":{"id":{"type":"string","description":"Present for an existing rule; omit to create one.","nullable":true},"type":{"type":"string","description":"A kind from `GET /commission_rates/rule_types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Configuration for the kind, per its type's `schema`."},"product_ids":{"type":"array","items":{"type":"string"},"description":"For kinds that name products, which are kept outside preferences."}},"required":["type"]},"CompanyAddressParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"company":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"phone":{"type":"string"},"label":{"type":"string"},"zipcode":{"type":"string","description":"Legacy spelling of `postal_code`; send only one of the two."},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"ISO 3166-1 alpha-2 code, such as `US`."},"state_code":{"type":"string","description":"The state or province abbreviation, such as `NY`."},"state_name":{"type":"string","description":"For countries without states in the database."},"default_billing":{"type":"boolean","description":"True makes this the default address of that kind, false gives the slot up, and leaving it out keeps the current default."},"default_shipping":{"type":"boolean","description":"True makes this the default address of that kind, false gives the slot up, and leaving it out keeps the current default."}}},"CompanyMembershipCreateParams":{"type":"object","properties":{"customer_email":{"type":"string","description":"An existing customer becomes a member immediately; an unknown email becomes an invitation, and the response is an invitation instead of a membership."},"metadata":{"type":"object","additionalProperties":true}},"required":["customer_email"]},"CompanyParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string","description":"Required when creating."},"kind":{"type":"string","enum":["company","division"],"description":"`company` is a legal entity (may hold tax registrations), `division` an organizational unit. Roots must be `company`."},"parent_id":{"type":"string","description":"The parent node. Omit or null for a root.","nullable":true},"po_number_required":{"type":"boolean","description":"Whether this buyer's own procurement process demands a PO reference on every order: checkout asks for one and refuses to complete without it."},"metadata":{"type":"object","additionalProperties":true}}},"CustomFieldCreateParams":{"type":"object","properties":{"custom_field_definition_id":{"type":"string"},"value":{"description":"A value matching the definition's `field_type`: a scalar for text, number and boolean fields; a list or a hash for JSON fields."}},"required":["custom_field_definition_id","value"]},"CustomFieldDefinitionCreateParams":{"type":"object","properties":{"namespace":{"type":"string","description":"Defaults to `custom`."},"key":{"type":"string"},"label":{"type":"string","description":"Human-readable name; defaults to the titleized `key`."},"field_type":{"type":"string","description":"Custom field type token (`short_text`, `long_text`, `rich_text`, `number`, …). An extension type that has no token is named by its registered class instead."},"resource_type":{"type":"string","description":"Shorthand of the resource the field attaches to, from the resource types endpoint."},"storefront_visible":{"type":"boolean","description":"When false, the definition is admin-only and never exposed in the Store API."},"searchable":{"type":"boolean","description":"Include values in storefront product text search. Supported for `short_text`, `long_text` and `number` fields; other types are refused."},"sortable":{"type":"boolean","description":"Allow storefront product listings to sort by this field (`sort=cf_{namespace}_{key}`). Supported for `short_text` and `number` fields; other types are refused."}},"required":["key","field_type","resource_type"]},"CustomFieldDefinitionUpdateParams":{"type":"object","properties":{"namespace":{"type":"string","description":"Defaults to `custom`."},"key":{"type":"string"},"label":{"type":"string","description":"Human-readable name; defaults to the titleized `key`."},"field_type":{"type":"string","description":"Custom field type token (`short_text`, `long_text`, `rich_text`, `number`, …). An extension type that has no token is named by its registered class instead."},"resource_type":{"type":"string","description":"Shorthand of the resource the field attaches to, from the resource types endpoint."},"storefront_visible":{"type":"boolean","description":"When false, the definition is admin-only and never exposed in the Store API."},"searchable":{"type":"boolean","description":"Include values in storefront product text search. Supported for `short_text`, `long_text` and `number` fields; other types are refused."},"sortable":{"type":"boolean","description":"Allow storefront product listings to sort by this field (`sort=cf_{namespace}_{key}`). Supported for `short_text` and `number` fields; other types are refused."}}},"CustomFieldUpdateParams":{"type":"object","properties":{"value":{"description":"A value matching the definition's `field_type`: a scalar for text, number and boolean fields; a list or a hash for JSON fields."}},"required":["value"]},"CustomFieldValueParams":{"type":"object","properties":{"id":{"type":"string"},"custom_field_definition_id":{"type":"string"},"value":{"description":"A scalar for text, number and boolean fields; a list or a hash for JSON fields."}}},"CustomerAddressParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"company":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"phone":{"type":"string"},"label":{"type":"string"},"zipcode":{"type":"string","description":"Legacy spelling of `postal_code`; send only one of the two."},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"ISO 3166-1 alpha-2 code, such as `US`."},"state_code":{"type":"string","description":"The state or province abbreviation, such as `NY`."},"state_name":{"type":"string","description":"For countries without states in the database."},"alternative_phone":{"type":"string"},"quick_checkout":{"type":"boolean"},"is_default_billing":{"type":"boolean","description":"Makes this the customer's default address of that kind."},"is_default_shipping":{"type":"boolean","description":"Makes this the customer's default address of that kind."}}},"CustomerBulkGroupsParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"customer_group_ids":{"type":"array","items":{"type":"string"},"description":"Groups from other stores are ignored."}},"required":["ids","customer_group_ids"]},"CustomerCreateParams":{"type":"object","properties":{"email":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"phone":{"type":"string"},"password":{"type":"string","description":"Optional: a customer created without one claims the account through a password reset."},"password_confirmation":{"type":"string","description":"Optional: a customer created without one claims the account through a password reset."},"selected_locale":{"type":"string"},"avatar_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`."},"accepts_email_marketing":{"type":"boolean"},"internal_note":{"type":"string","description":"Rich text HTML. Reads come back as this plus `internal_note_html`."},"metadata":{"type":"object","additionalProperties":true},"tags":{"type":"array","items":{"type":"string"}},"customer_group_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the customer's group membership."}},"required":["email"]},"CustomerGroupCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"customer_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the group's members."}},"required":["name"]},"CustomerGroupUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"customer_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the group's members."}}},"CustomerStoreCreditCreateParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}]},"memo":{"type":"string"}},"required":["amount","currency"]},"CustomerStoreCreditUpdateParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"memo":{"type":"string"}}},"CustomerUpdateParams":{"type":"object","properties":{"email":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"phone":{"type":"string"},"password":{"type":"string","description":"Optional: a customer created without one claims the account through a password reset."},"password_confirmation":{"type":"string","description":"Optional: a customer created without one claims the account through a password reset."},"selected_locale":{"type":"string"},"avatar_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`."},"accepts_email_marketing":{"type":"boolean"},"internal_note":{"type":"string","description":"Rich text HTML. Reads come back as this plus `internal_note_html`."},"metadata":{"type":"object","additionalProperties":true},"tags":{"type":"array","items":{"type":"string"}},"customer_group_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the customer's group membership."}}},"DataRequestCreateParams":{"type":"object","properties":{"customer_id":{"type":"string"},"kind":{"type":"string","enum":["access","erasure"],"description":"`access` asks for a copy of the customer's personal data; `erasure` asks for it to be erased."}},"required":["customer_id","kind"]},"DeliveryCreateParams":{"type":"object","properties":{"tracking_number":{"type":"string","description":"A carrier tracking number, a freight PRO or container number, or a full tracking link. A corrected number resets the carrier status to `pending`."},"carrier":{"type":"string","description":"Free text; detected from the number's format when omitted."},"service":{"type":"string"},"tracking_url":{"type":"string"}},"required":["tracking_number"]},"DeliveryMarkDeliveredParams":{"type":"object","properties":{"delivered_at":{"type":"string","format":"date-time","description":"When it arrived. Defaults to now."},"notify_customer":{"type":"boolean","description":"Whether the customer gets a delivery notification once the parcel completes. Defaults to true."}}},"DeliveryMethodParams":{"type":"object","properties":{"name":{"type":"string"},"admin_name":{"type":"string","nullable":true},"code":{"type":"string","nullable":true},"fulfillment_provider":{"type":"string","description":"Fulfillment provider shorthand (see the fulfillment providers endpoint), e.g. `manual`."},"pickup_point_provider":{"type":"string","nullable":true},"rate_provider":{"type":"string","description":"Rate provider shorthand (see the rate providers endpoint), e.g. `easy_post`. Omit or send null for the built-in provider, which prices through the method's calculator.","nullable":true},"storefront_visible":{"type":"boolean"},"available_to_sellers":{"type":"boolean","description":"Marketplace only: whether a seller's packages may be quoted by this method. Off by default, and refused on a method that belongs to a seller."},"tracking_url":{"type":"string","nullable":true},"estimated_transit_business_days_min":{"type":"integer","nullable":true},"estimated_transit_business_days_max":{"type":"integer","nullable":true},"tax_category_id":{"type":"string","description":"Prefixed tax category ID (`taxcat_...`), or null to clear.","nullable":true},"markup_flat":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Method-level flat handling fee added on top of provider-quoted rates.","nullable":true},"markup_percent":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Method-level percentage handling fee added on top of provider-quoted rates. Ignored for calculator-priced methods.","nullable":true},"delivery_profile_id":{"type":"string","description":"Delivery profile this method belongs to (`fp_...`); defaults to the store default profile."},"delivery_origin_group_id":{"type":"string","description":"Origin group offering this method (`og_...`); defaults to the zone's group, else the profile's default group."},"delivery_zone_id":{"type":"string","description":"Delivery zone narrowing destinations (`dz_...`), or null for no restriction. Must belong to the method's profile.","nullable":true},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Pickup locations (`sloc_...`); replaces the full set."},"calculator":{"type":"object","properties":{"type":{"type":"string"},"preferences":{"type":"object","additionalProperties":true}},"description":"How the method prices a shipment: a type from the calculators endpoint and its preferences, matching that type's `schema`."},"rules":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","description":"A rule kind from the delivery method rule types endpoint."},"active":{"type":"boolean"},"preferences":{"type":"object","additionalProperties":true},"product_ids":{"type":"array","items":{"type":"string"},"description":"Products an association-backed rule (`excluded_products_rule`) applies to."}}},"description":"Eligibility rules. Replaces the full set: omitted rules are removed."},"services":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryMethodServiceParams"},"description":"Carrier service rows: which provider services this method offers. Replaces the full set: omitted rows are removed; no rows means every service the provider returns is offered."}}},"DeliveryMethodRuleCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"A rule kind from the delivery method rule types endpoint."},"active":{"type":"boolean","description":"Defaults to true on create."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's preference schema."},"product_ids":{"type":"array","items":{"type":"string"},"description":"Products an association-backed rule (`excluded_products_rule`) applies to. An empty list clears them."}},"required":["type"]},"DeliveryMethodRuleUpdateParams":{"type":"object","properties":{"active":{"type":"boolean","description":"Defaults to true on create."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's preference schema."},"product_ids":{"type":"array","items":{"type":"string"},"description":"Products an association-backed rule (`excluded_products_rule`) applies to. An empty list clears them."}}},"DeliveryMethodServiceParams":{"type":"object","properties":{"id":{"type":"string","description":"Prefixed row ID (`dms_...`) when updating an existing row."},"carrier":{"type":"string","description":"Carrier identifier as the provider's API knows it."},"service":{"type":"string","description":"Service identifier as the provider's API knows it."},"label":{"type":"string","description":"Display label shown to customers instead of the carrier-derived name.","nullable":true},"markup_flat":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Overrides the method-level flat markup for this service.","nullable":true},"markup_percent":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Overrides the method-level percentage markup for this service.","nullable":true},"position":{"type":"integer"}},"required":["carrier","service"]},"DeliveryOriginGroupParams":{"type":"object","properties":{"name":{"type":"string","nullable":true},"position":{"type":"integer"},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Prefixed stock location IDs (`sloc_...`); replaces the full set. Empty means every store location."}}},"DeliveryProfileParams":{"type":"object","properties":{"name":{"type":"string"},"kind":{"type":"string","description":"Registered profile kind (`shipping`, `digital`, extension kinds) from the kinds endpoint. Read on create only; defaults to shipping."},"default":{"type":"boolean","description":"Promotes this profile to the store default; the previous default is demoted."},"position":{"type":"integer"},"stock_location_ids":{"type":"array","items":{"type":"string"},"description":"Prefixed stock location IDs (`sloc_...`); replaces the full set. Empty means every store location."}}},"DeliveryUpdateParams":{"type":"object","properties":{"tracking_number":{"type":"string","description":"A carrier tracking number, a freight PRO or container number, or a full tracking link. A corrected number resets the carrier status to `pending`."},"carrier":{"type":"string","description":"Free text; detected from the number's format when omitted."},"service":{"type":"string"},"tracking_url":{"type":"string"}}},"DeliveryZoneMemberParams":{"type":"object","properties":{"member_type":{"type":"string","enum":["country","state","postal_code"]},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}]},"state_code":{"type":"string","description":"A subdivision code or name. Without `country_code` the country is inferred when only one country matches."},"postal_code_prefix":{"type":"string"},"postal_code_from":{"type":"string"},"postal_code_to":{"type":"string"}},"required":["member_type"]},"DeliveryZoneParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"delivery_profile_id":{"type":"string","description":"Delivery profile this zone belongs to (`fp_...`); defaults to the store default profile."},"delivery_origin_group_id":{"type":"string","description":"Origin group this zone belongs to (`og_...`)."},"members":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryZoneMemberParams"},"description":"Replaces the zone's full member set atomically."}}},"DigitalAssetCreateParams":{"type":"object","properties":{"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` with `visibility: 'private'`. Required for an uploaded file, omitted for a provider-backed asset. On update it replaces the file for everyone who already bought it."},"variant_id":{"type":"string","description":"Defaults to the product's default variant when omitted."},"provider_type":{"type":"string","description":"A provider shorthand from the providers endpoint. Omit for an uploaded file."},"provider_settings":{"type":"object","additionalProperties":true,"description":"Values for the provider's settings schema, keyed by field name."},"authorized_clicks":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true},"authorized_days":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true}}},"DigitalAssetUpdateParams":{"type":"object","properties":{"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` with `visibility: 'private'`. Required for an uploaded file, omitted for a provider-backed asset. On update it replaces the file for everyone who already bought it."},"variant_id":{"type":"string","description":"Defaults to the product's default variant when omitted."},"provider_type":{"type":"string","description":"A provider shorthand from the providers endpoint. Omit for an uploaded file."},"provider_settings":{"type":"object","additionalProperties":true,"description":"Values for the provider's settings schema, keyed by field name."},"authorized_clicks":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true},"authorized_days":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true}}},"DiscountCodeApplyParams":{"type":"object","properties":{"code":{"type":"string"}},"required":["code"]},"DiscountCreateParams":{"type":"object","properties":{"label":{"type":"string"},"value":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"An amount in the order currency for a `flat` discount, or a percentage for a `percent` one."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"On create, an older spelling of `value`, read when `value` is absent. On update, the new amount of the row."},"value_type":{"type":"string","enum":["flat","percent"],"description":"Defaults to `flat`."},"line_item_id":{"type":"string","description":"The line item the discount applies to. Omitted, the value is distributed across the line items.","nullable":true}},"required":["label"]},"DiscountUpdateParams":{"type":"object","properties":{"label":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"On create, an older spelling of `value`, read when `value` is absent. On update, the new amount of the row."}}},"EmailTemplateDraftParams":{"type":"object","properties":{"language":{"type":"string","description":"A language code, or `any` (the default) for the version every language uses."},"subject":{"type":"string","nullable":true},"body":{"type":"string"},"lock_version":{"type":"integer","description":"The `lock_version` the draft was loaded with, or null when there was no draft; a save from an older copy is refused with 409. Omit it to save without checking.","nullable":true},"rebase":{"type":"boolean","description":"Marks the draft as based on Spree's current default, after reviewing what changed in it."}}},"EmailTemplatePreviewParams":{"type":"object","properties":{"language":{"type":"string","description":"A language code, or `any` (the default) for the version every language uses."},"subject":{"type":"string","description":"An unsaved subject, in place of the current one.","nullable":true},"body":{"type":"string","description":"An unsaved body, in place of the current one."},"record_id":{"type":"string","description":"The record to build sample data from; the store's latest matching record otherwise."},"email_key":{"type":"string","description":"For the layout or a partial, the email to show it in."},"branding":{"type":"object","properties":{"accent_color":{"type":"string","nullable":true},"background_color":{"type":"string","nullable":true},"card_color":{"type":"string","nullable":true},"text_color":{"type":"string","nullable":true},"heading_color":{"type":"string","nullable":true},"font":{"type":"string","enum":["inter","system","helvetica","georgia","roboto","lato","merriweather"],"nullable":true}},"description":"Unsaved colors and font to preview, named like the store's `email_*` settings."}}},"EmailTemplateRestoreParams":{"type":"object","properties":{"language":{"type":"string","description":"A language code, or `any` (the default) for the version every language uses."},"lock_version":{"type":"integer","description":"The open draft's `lock_version`, or null when there is none; checked as when saving.","nullable":true}}},"EmailTemplateVersionParams":{"type":"object","properties":{"language":{"type":"string","description":"A language code, or `any` (the default) for the version every language uses."},"lock_version":{"type":"integer","description":"The draft's `lock_version` as reviewed. A draft saved since is refused with 409."}}},"ExchangeCancelParams":{"type":"object","properties":{"reason":{"type":"string","description":"A note on why the exchange was canceled."}}},"ExchangeCreateParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"fulfillment_item_id":{"type":"string"},"new_variant_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["fulfillment_item_id","new_variant_id","quantity"]},"description":"Items coming back, and what goes out in their place."},"stock_location_id":{"type":"string","description":"Where the goods come back to."},"reason_id":{"type":"string","description":"One of the store's return reasons."},"memo":{"type":"string"}},"required":["items"]},"ExchangeFulfillParams":{"type":"object","properties":{"refund_method":{"type":"string","enum":["original_payment","store_credit"],"description":"How a credit is returned when the replacements cost less than what came back. Defaults to `store_credit`. A balance the customer owes is left for the merchant to collect."}}},"ExchangeReceiveParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"exchange_line_item_id":{"type":"string"},"quantity":{"type":"integer"},"resellable":{"type":"boolean","description":"Goods that cannot be resold are received but never restocked. Defaults to true."}},"required":["exchange_line_item_id","quantity"]},"description":"What actually arrived. Omit to receive everything as requested and resellable."}}},"ExchangeUpdateParams":{"type":"object","properties":{"stock_location_id":{"type":"string","description":"Where the goods come back to."},"reason_id":{"type":"string","description":"One of the store's return reasons."},"memo":{"type":"string"},"metadata":{"type":"object","additionalProperties":true}}},"ExportCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Which dataset to export, as its shorthand: `products`, `orders`, `customers`, `product_translations`, `gift_cards`, `coupon_codes`, `newsletter_subscribers`, `price_list_prices`, `purchase_orders`, or a type an extension registers."},"record_selection":{"type":"string","enum":["filtered","all"],"description":"`filtered` (the default) keeps `search_params`; `all` ignores them and exports every record in scope."},"results_url":{"type":"string","description":"Absolute URL of your admin exports view; the export-done email uses it as the download button target. Only honored when it matches one of the store's allowed origins."},"search_params":{"type":"object","additionalProperties":true,"description":"A Ransack query, with the predicates the list endpoint accepts. A `price_list_prices` export requires `price_list_id_eq` naming a price list of the current store, and refuses `record_selection: \"all\"`."}},"required":["type"]},"FeeCreateParams":{"type":"object","properties":{"label":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"kind":{"anyOf":[{"type":"string","enum":["surcharge","handling","gift_wrap","cod","payment","duty","exchange"]},{"type":"string"}],"description":"Defaults to `surcharge`. The values listed are the built-in ones; extensions may add more."},"line_item_id":{"type":"string","description":"The line item or fulfillment the fee belongs to. Omitted, the fee is order-level.","nullable":true},"fulfillment_id":{"type":"string","description":"The line item or fulfillment the fee belongs to. Omitted, the fee is order-level.","nullable":true}},"required":["label","amount"]},"FeeUpdateParams":{"type":"object","properties":{"label":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"kind":{"anyOf":[{"type":"string","enum":["surcharge","handling","gift_wrap","cod","payment","duty","exchange"]},{"type":"string"}],"description":"Defaults to `surcharge`. The values listed are the built-in ones; extensions may add more."}}},"FileUploadCreateParams":{"type":"object","properties":{"filename":{"type":"string"},"content_type":{"type":"string"},"byte_size":{"type":"integer"},"checksum":{"type":"string","description":"Base64-encoded MD5 digest of the file; the storage service checks the bytes against it."},"visibility":{"type":"string","enum":["public","private"],"description":"`public` (the default) for images and videos customers see, `private` for anything else."},"file":{"type":"string","format":"binary","description":"The bytes, for a multipart upload."}},"required":["filename","content_type"]},"FulfillmentCreateParams":{"type":"object","properties":{"stock_location_id":{"type":"string","description":"The location the fulfillment ships from. On update, moving it re-prices the fulfillment against that location's rates."},"source_fulfillment_id":{"type":"string","description":"The only fulfillment of this order to move units from, its exchange and claim replacements included: how a canceled replacement is sent again. Omitted, the customer's bought units are taken from every unshipped fulfillment."},"tracking":{"type":"string","description":"Carrier tracking number, or a full `https://` tracking link, which is served back as `tracking_url` unchanged."},"delivery_method_id":{"type":"string","description":"Delivery method attached as the selected rate. Defaults to the delivery method of the fully drained source fulfillments."},"cost":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Explicit shipping cost, such as the 3PL price. Defaults to the summed cost of the fully drained source fulfillments, which keeps the order total unchanged. Persists only with `status: shipped`; pending fulfillments are re-priced by the rate engine."},"status":{"type":"string","enum":["shipped"],"description":"Pass `shipped` to register an already-shipped external fulfillment."},"metadata":{"type":"object","additionalProperties":true},"items":{"type":"array","items":{"type":"object","properties":{"item_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["item_id","quantity"]},"description":"Line item quantities to fulfill. Omit to fulfill every unit not yet shipped."}},"required":["stock_location_id"]},"FulfillmentFulfillParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"item_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["item_id","quantity"]},"description":"Line item quantities to ship. Omit to ship everything the fulfillment holds; a subset is split onto a new fulfillment, which is the one that ships."},"tracking":{"type":"string","description":"Carrier tracking number or a full `https://` tracking link, stored on the fulfillment that ships."},"tracking_carrier":{"type":"string","description":"Which carrier the number belongs to; detected from the number when omitted."},"notify_customer":{"type":"boolean","description":"Whether the customer gets the shipment email. Defaults to true; pass false to suppress it for this dispatch only."},"force":{"type":"boolean","description":"Hand the goods over even though the order is unpaid or holds backordered units."}}},"FulfillmentMarkDeliveredParams":{"type":"object","properties":{"delivered_at":{"type":"string","format":"date-time","description":"When it arrived. Defaults to now; return windows run from this time."},"notify_customer":{"type":"boolean","description":"Whether the customer gets a delivery notification. Defaults to true."}}},"FulfillmentSplitParams":{"type":"object","properties":{"variant_id":{"type":"string","description":"The variant being moved out."},"quantity":{"type":"integer"},"stock_location_id":{"type":"string","description":"Origin of the new fulfillment. Defaults to the source fulfillment's location."}},"required":["variant_id","quantity"]},"FulfillmentUpdateParams":{"type":"object","properties":{"stock_location_id":{"type":"string","description":"The location the fulfillment ships from. On update, moving it re-prices the fulfillment against that location's rates."},"tracking":{"type":"string","description":"Carrier tracking number, or a full `https://` tracking link, which is served back as `tracking_url` unchanged."},"tracking_carrier":{"type":"string","description":"Which carrier the tracking number belongs to: a slug from the tracking carriers endpoint. Left blank, it is detected from the number's format where possible."},"selected_delivery_rate_id":{"type":"string"}}},"GiftCardApplyParams":{"type":"object","properties":{"code":{"type":"string","description":"The gift card code; matched case-insensitively."}},"required":["code"]},"GiftCardBatchCreateParams":{"type":"object","properties":{"prefix":{"type":"string","description":"Lowercased and prepended to every generated code."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"The amount of each card, greater than zero."},"codes_count":{"type":"integer","description":"How many cards to generate. Capped at `gift_card_batch_limit`; batches over `gift_card_batch_web_limit` generate in the background."},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"ISO 4217 currency code. Defaults to the store currency."},"expires_at":{"type":"string","format":"date","nullable":true}},"required":["prefix","amount","codes_count"]},"GiftCardCreateParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Greater than zero."},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"ISO 4217 currency code. Defaults to the store currency."},"code":{"type":"string","description":"Generated when omitted."},"expires_at":{"type":"string","format":"date","nullable":true},"customer_id":{"type":"string","description":"The customer the card belongs to. Needs the `read_customers` permission; null detaches it.","nullable":true}},"required":["amount"]},"GiftCardUpdateParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Greater than zero."},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"ISO 4217 currency code. Defaults to the store currency."},"code":{"type":"string","description":"Generated when omitted."},"expires_at":{"type":"string","format":"date","nullable":true},"customer_id":{"type":"string","description":"The customer the card belongs to. Needs the `read_customers` permission; null detaches it.","nullable":true}}},"ImportCompleteMappingParams":{"type":"object","properties":{"mappings":{"type":"array","items":{"type":"object","properties":{"schema_field":{"type":"string","description":"A schema field name from the import's `schema_fields`."},"file_column":{"type":"string","description":"The CSV header to read the field from; null unmaps the field.","nullable":true}},"required":["schema_field"]},"description":"Column assignments to apply before processing starts. Omit to accept the ones assigned on create."}}},"ImportCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Which dataset to import, as its shorthand: `products`, `customers`, `product_translations`, `price_list_prices`, `purchase_orders`, or a type an extension registers."},"attachment_signed_id":{"type":"string","description":"The `signed_id` of the uploaded CSV, from `files.upload()` with `visibility: \"private\"`."},"delimiter":{"type":"string","enum":[",",";","|","\t"],"description":"CSV column separator. Defaults to a comma."},"results_url":{"type":"string","description":"Absolute URL of your admin imports view; the import-done email links back to it with `?import=<id>` appended. Only honored when it matches one of the store's allowed origins."},"price_list_id":{"type":"string","description":"For `price_list_prices` imports: the price list the rows are merged into. Must belong to the current store; other types ignore it."}},"required":["type","attachment_signed_id"]},"IntegrationCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Wire shorthand from the integration types endpoint."},"active":{"type":"boolean","description":"Activating runs the connection check, and a failed check is a 422."},"preferences":{"type":"object","additionalProperties":true,"description":"Credential values. Secret preferences come back masked, and sending a masked value back keeps the stored secret."}},"required":["type"]},"IntegrationUpdateParams":{"type":"object","properties":{"active":{"type":"boolean","description":"Activating runs the connection check, and a failed check is a 422."},"preferences":{"type":"object","additionalProperties":true,"description":"Credential values. Secret preferences come back masked, and sending a masked value back keeps the stored secret."}}},"InvitationAcceptParams":{"type":"object","properties":{"password":{"type":"string","description":"Required when the invitee has no account yet: it creates one. An existing account signs in without it."},"password_confirmation":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"}}},"InvitationCreateParams":{"type":"object","properties":{"email":{"type":"string"},"role_id":{"type":"string","description":"The role (`role_...`) the invitee gets on accepting."}},"required":["email","role_id"]},"LineItemCreateParams":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer","description":"Defaults to 1 when adding an item."},"price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Negotiated unit price. Stamps the line `price_source: 'manual'`, so quantity changes and recalculation never re-price it; an explicit null reverts the line to catalog pricing. Omit to leave pricing alone. Draft (incomplete) orders only.","nullable":true},"options":{"type":"object","additionalProperties":true}},"required":["variant_id"]},"LineItemUpdateParams":{"type":"object","properties":{"quantity":{"type":"integer","description":"Defaults to 1 when adding an item."},"price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Negotiated unit price. Stamps the line `price_source: 'manual'`, so quantity changes and recalculation never re-price it; an explicit null reverts the line to catalog pricing. Omit to leave pricing alone. Draft (incomplete) orders only.","nullable":true},"metadata":{"type":"object","additionalProperties":true}}},"MarketCreateParams":{"type":"object","properties":{"name":{"type":"string","description":"Display name, unique within the store."},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"ISO 4217 currency code."},"default_locale":{"type":"string","description":"Locale used as the market default. Always part of `supported_locales`."},"tax_inclusive":{"type":"boolean","description":"Display prices with tax included."},"tax_provider":{"type":"string","description":"Shorthand of the tax engine that prices this market, from the tax providers endpoint. Null uses the installation default.","nullable":true},"default":{"type":"boolean","description":"Setting true demotes the previous default market of the store."},"position":{"type":"integer","description":"Sort order within the store; lower comes first."},"supported_locales":{"type":"array","items":{"type":"string"},"description":"Locales available in this market. The default locale is always included."},"country_codes":{"type":"array","items":{"$ref":"#/components/schemas/CountryCode"},"description":"ISO 3166-1 alpha-2 codes of the countries in this market. At least one is required."}},"required":["name","currency","default_locale","country_codes"]},"MarketUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"Display name, unique within the store."},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"ISO 4217 currency code."},"default_locale":{"type":"string","description":"Locale used as the market default. Always part of `supported_locales`."},"tax_inclusive":{"type":"boolean","description":"Display prices with tax included."},"tax_provider":{"type":"string","description":"Shorthand of the tax engine that prices this market, from the tax providers endpoint. Null uses the installation default.","nullable":true},"default":{"type":"boolean","description":"Setting true demotes the previous default market of the store."},"position":{"type":"integer","description":"Sort order within the store; lower comes first."},"supported_locales":{"type":"array","items":{"type":"string"},"description":"Locales available in this market. The default locale is always included."},"country_codes":{"type":"array","items":{"$ref":"#/components/schemas/CountryCode"},"description":"ISO 3166-1 alpha-2 codes of the countries in this market. At least one is required."}}},"MeUpdateParams":{"type":"object","properties":{"selected_locale":{"type":"string","description":"The dashboard display language."},"first_name":{"type":"string"},"last_name":{"type":"string"},"avatar_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` to set the avatar, or null to remove it. Omit it to keep the current photo.","nullable":true}}},"MediaCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"attachment":{"type":"string","description":"The file itself, sent as multipart form data. JSON clients upload first and send `signed_id`."},"url":{"type":"string","description":"Fetch an image from this URL, in the background. Images only: an external video uses `external_video_url`."},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the media file itself."},"source_media_id":{"type":"string","description":"Place a file that is already in the library. The new row shares the source file rather than copying it, and takes its own alt, position and variant links from here."},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Variants to link this product-level media to. Variants of other products are dropped."}}},"MediaLibraryCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"attachment":{"type":"string","description":"The file itself, sent as multipart form data. JSON clients upload first and send `signed_id`."},"url":{"type":"string","description":"Fetch an image from this URL, in the background. Images only: an external video uses `external_video_url`."},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the media file itself."},"source_media_id":{"type":"string","description":"Place a file that is already in the library. The new row shares the source file rather than copying it, and takes its own alt, position and variant links from here."},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Variants to link this product-level media to. Variants of other products are dropped."}}},"MediaLibraryUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"attachment":{"type":"string","description":"The file itself, sent as multipart form data. JSON clients upload first and send `signed_id`."},"url":{"type":"string","description":"Fetch an image from this URL, in the background. Images only: an external video uses `external_video_url`."},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the media file itself."},"source_media_id":{"type":"string","description":"Place a file that is already in the library. The new row shares the source file rather than copying it, and takes its own alt, position and variant links from here."},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Variants to link this product-level media to. Variants of other products are dropped."}}},"MediaUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"attachment":{"type":"string","description":"The file itself, sent as multipart form data. JSON clients upload first and send `signed_id`."},"url":{"type":"string","description":"Fetch an image from this URL, in the background. Images only: an external video uses `external_video_url`."},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the media file itself."},"source_media_id":{"type":"string","description":"Place a file that is already in the library. The new row shares the source file rather than copying it, and takes its own alt, position and variant links from here."},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Variants to link this product-level media to. Variants of other products are dropped."}}},"OptionTypeCreateParams":{"type":"object","properties":{"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"integer"},"filterable":{"type":"boolean"},"kind":{"type":"string","enum":["dropdown","color_swatch","buttons"]},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValueParams"},"description":"Inline option values. Values left out of the list on update are destroyed, so send the full set every time."}},"required":["name","label"]},"OptionTypeUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"integer"},"filterable":{"type":"boolean"},"kind":{"type":"string","enum":["dropdown","color_swatch","buttons"]},"option_values":{"type":"array","items":{"$ref":"#/components/schemas/OptionValueParams"},"description":"Inline option values. Values left out of the list on update are destroyed, so send the full set every time."}}},"OptionValueParams":{"type":"object","properties":{"id":{"type":"string","description":"Present for existing values. Omit to create a new one."},"name":{"type":"string"},"label":{"type":"string"},"position":{"type":"integer"},"color_code":{"type":"string","description":"Hex color. Only meaningful when the option type's `kind` is `color_swatch`.","nullable":true},"image_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`, or null to remove the image.","nullable":true}}},"OrderCancelParams":{"type":"object","properties":{"cancel_reason_id":{"type":"string","description":"Why the order was canceled: the id of one of the store's cancellation reasons."},"cancel_note":{"type":"string","description":"Staff-facing note about the cancellation."},"refund_payments":{"type":"boolean","description":"Whether this order's share of a payment shared across a split checkout is handed back."},"refund_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"How much of that share to return. Defaults to all of it; refused on an order whose payment is not shared."},"notify_customer":{"type":"boolean","description":"Send the order cancellation email after canceling."}}},"OrderCompleteParams":{"type":"object","properties":{"payment_pending":{"type":"boolean"},"notify_customer":{"type":"boolean","description":"Send the order confirmation email after completion."}}},"OrderCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"email":{"type":"string"},"customer_id":{"type":"string"},"use_customer_default_address":{"type":"boolean","description":"With `customer_id`, copies the customer's saved billing and shipping addresses onto the order."},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}]},"market_id":{"type":"string"},"channel_id":{"type":"string","description":"Defaults to the store primary channel when omitted."},"locale":{"type":"string"},"customer_note":{"type":"string","description":"Public, customer-visible note."},"internal_note":{"type":"string","description":"Staff-only note. Rich text HTML; reads come back as this plus `internal_note_html`."},"po_number":{"type":"string","description":"The buyer's own purchase-order reference. Searchable alongside the order number, and rendered on every order-facing document."},"po_document_signed_id":{"type":"string","description":"The `signed_id` of the buyer's purchase order, from `files.upload()` with `visibility: 'private'`. Null removes the document the order carries.","nullable":true},"shipping_address_id":{"type":"string","description":"An existing address of the customer."},"billing_address_id":{"type":"string","description":"An existing address of the customer."},"preferred_stock_location_id":{"type":"string","description":"Stock location to prefer for fulfillment. Order Routing's built-in preferred-location rule ranks it first; routing falls back to the next rule when the location can't cover the cart."},"company_id":{"type":"string","description":"Makes the order a company purchase, with that company's catalog prices and tax treatment. Null makes a draft a plain customer order again.","nullable":true},"coupon_code":{"type":"string","description":"Applied non-fatally: an invalid code does not block creation."},"metadata":{"type":"object","additionalProperties":true},"tags":{"type":"array","items":{"type":"string"}},"shipping_address":{"$ref":"#/components/schemas/AddressInputParams"},"billing_address":{"$ref":"#/components/schemas/AddressInputParams"},"items":{"type":"array","items":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer"},"price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Negotiated unit price; stamps `price_source: 'manual'`. Null reverts the line to catalog pricing. Draft orders only.","nullable":true},"metadata":{"type":"object","additionalProperties":true}},"required":["variant_id"]},"description":"Line items to upsert, keyed by variant. An entry sets that variant's quantity, creating the line item when the order has none; `quantity: 0` removes it. Variants you do not send are left alone."}}},"OrderRoutingRuleCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Wire shorthand for the rule kind, from the order routing rule types endpoint."},"active":{"type":"boolean"},"position":{"type":"integer","description":"1-based priority in the channel's rule list. Omitted on create, the rule goes last; a new position reorders the rest of the list around it."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's preference schema."}},"required":["type"]},"OrderRoutingRuleUpdateParams":{"type":"object","properties":{"active":{"type":"boolean"},"position":{"type":"integer","description":"1-based priority in the channel's rule list. Omitted on create, the rule goes last; a new position reorders the rest of the list around it."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's preference schema."}}},"OrderUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"email":{"type":"string"},"customer_id":{"type":"string"},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}]},"market_id":{"type":"string"},"channel_id":{"type":"string","description":"Defaults to the store primary channel when omitted."},"locale":{"type":"string"},"customer_note":{"type":"string","description":"Public, customer-visible note."},"internal_note":{"type":"string","description":"Staff-only note. Rich text HTML; reads come back as this plus `internal_note_html`."},"po_number":{"type":"string","description":"The buyer's own purchase-order reference. Searchable alongside the order number, and rendered on every order-facing document."},"po_document_signed_id":{"type":"string","description":"The `signed_id` of the buyer's purchase order, from `files.upload()` with `visibility: 'private'`. Null removes the document the order carries.","nullable":true},"preferred_stock_location_id":{"type":"string","description":"Stock location to prefer for fulfillment. Order Routing's built-in preferred-location rule ranks it first; routing falls back to the next rule when the location can't cover the cart."},"company_id":{"type":"string","description":"Makes the order a company purchase, with that company's catalog prices and tax treatment. Null makes a draft a plain customer order again.","nullable":true},"metadata":{"type":"object","additionalProperties":true},"tags":{"type":"array","items":{"type":"string"}},"shipping_address":{"$ref":"#/components/schemas/AddressInputParams"},"billing_address":{"$ref":"#/components/schemas/AddressInputParams"},"items":{"type":"array","items":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer"},"price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Negotiated unit price; stamps `price_source: 'manual'`. Null reverts the line to catalog pricing. Draft orders only.","nullable":true},"metadata":{"type":"object","additionalProperties":true}},"required":["variant_id"]},"description":"Line items to upsert, keyed by variant. An entry sets that variant's quantity, creating the line item when the order has none; `quantity: 0` removes it. Variants you do not send are left alone."}}},"PackageTypeCreateParams":{"type":"object","properties":{"name":{"type":"string","description":"Unique within the store."},"kind":{"type":"string","enum":["box","envelope","carton","pallet","container"],"description":"What this packaging is: the box parcels ship in, or the carton, pallet or container a wholesale order leaves on."},"length":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"],"description":"Unit the three dimensions are in; falls back to the store's unit system.","nullable":true},"weight":{"type":"number","description":"The empty package's own weight, added to content weight on every quote.","nullable":true},"max_weight":{"type":"number","description":"What the package can hold, not the same as its own weight.","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"],"nullable":true},"default":{"type":"boolean","description":"The box every parcel quote is built on. Setting this demotes whichever row held it."},"metadata":{"type":"object","additionalProperties":true}},"required":["name","kind"]},"PackageTypeUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"Unique within the store."},"kind":{"type":"string","enum":["box","envelope","carton","pallet","container"],"description":"What this packaging is: the box parcels ship in, or the carton, pallet or container a wholesale order leaves on."},"length":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"],"description":"Unit the three dimensions are in; falls back to the store's unit system.","nullable":true},"weight":{"type":"number","description":"The empty package's own weight, added to content weight on every quote.","nullable":true},"max_weight":{"type":"number","description":"What the package can hold, not the same as its own weight.","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"],"nullable":true},"default":{"type":"boolean","description":"The box every parcel quote is built on. Setting this demotes whichever row held it."},"metadata":{"type":"object","additionalProperties":true}}},"PasswordResetParams":{"type":"object","properties":{"password":{"type":"string"},"password_confirmation":{"type":"string"}},"required":["password","password_confirmation"]},"PasswordResetRequestParams":{"type":"object","properties":{"email":{"type":"string","format":"email"},"redirect_url":{"type":"string","description":"The page the emailed reset link points at, with the reset token appended. Honored only on the dashboard origin, for an account that is staff of the store; ignored otherwise."}},"required":["email"]},"PaymentCaptureParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Captures part of the authorized amount. Defaults to all of it."}}},"PaymentCreateParams":{"type":"object","properties":{"payment_method_id":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Defaults to the order total left after store credit."},"source_id":{"type":"string","description":"A saved payment source of the order's customer (a credit card), for an off-session charge. Used only by payment methods that require a source."}},"required":["payment_method_id"]},"PaymentMethodCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"Wire shorthand from the payment method types endpoint."},"name":{"type":"string"},"description":{"type":"string","nullable":true},"active":{"type":"boolean"},"storefront_visible":{"type":"boolean","description":"False keeps the method to the dashboard; true also offers it on the storefront."},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"],"description":"When customers are charged for this method. Null inherits the store setting.","nullable":true},"position":{"type":"integer"},"metadata":{"type":"object","additionalProperties":true},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the provider's preference schema, from the payment method types endpoint."}},"required":["type","name"]},"PaymentMethodUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"active":{"type":"boolean"},"storefront_visible":{"type":"boolean","description":"False keeps the method to the dashboard; true also offers it on the storefront."},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"],"description":"When customers are charged for this method. Null inherits the store setting.","nullable":true},"position":{"type":"integer"},"metadata":{"type":"object","additionalProperties":true},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the provider's preference schema, from the payment method types endpoint."}}},"PolicyCreateParams":{"type":"object","properties":{"name":{"type":"string"},"slug":{"type":"string"},"body":{"type":"string","nullable":true}},"required":["name"]},"PolicyUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"slug":{"type":"string"},"body":{"type":"string","nullable":true}}},"PriceAdjustmentTierParams":{"type":"object","properties":{"min_quantity":{"type":"integer","description":"Above 1; quantity 1 is the list's own `price_adjustment_percentage`."},"percentage":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Signed: negative discounts, positive marks up."}},"required":["min_quantity","percentage"]},"PriceBulkDestroyParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}}},"required":["ids"]},"PriceBulkUpsertParams":{"type":"object","properties":{"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceBulkUpsertRowParams"},"description":"Send an empty list to change nothing."}},"required":["prices"]},"PriceBulkUpsertRowParams":{"type":"object","properties":{"id":{"type":"string","description":"Present: updates that row. Absent: upserts on `(variant_id, currency, price_list_id, min_quantity)`.","nullable":true},"variant_id":{"type":"string"},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}]},"price_list_id":{"type":"string","description":"Omit or null for a base price.","nullable":true},"min_quantity":{"type":"integer","description":"The rung of the variant's ladder. Omit for the bottom rung; anything above 1 requires a `price_list_id`. A variant carries at most ten rungs on one list per currency."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"required":["variant_id","currency"]},"PriceCreateParams":{"type":"object","properties":{"variant_id":{"type":"string"},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}]},"min_quantity":{"type":"integer","description":"The quantity a line must reach for this price to apply. Omit for the bottom rung of the ladder. Anything above 1 requires a `price_list_id`."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"price_list_id":{"type":"string","description":"Omit or null for a base price; a price list for a list override.","nullable":true}},"required":["variant_id","currency"]},"PriceListCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"position":{"type":"integer"},"starts_at":{"type":"string","format":"date-time","description":"Pair with `ends_at` to schedule the list: activating a list whose start is in the future marks it `scheduled`.","nullable":true},"ends_at":{"type":"string","format":"date-time","nullable":true},"match_policy":{"type":"string","enum":["all","any"],"description":"`all`: every rule must match. `any`: one matching rule is enough."},"price_adjustment_percentage":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Signed: negative discounts off base prices, positive marks up.","nullable":true},"adjust_compare_at":{"type":"boolean"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PriceListRuleParams"},"description":"The complete rule set: rules are matched by `id` and updated, new ones are built, and rules left out are removed."},"price_adjustment_tiers":{"type":"array","items":{"$ref":"#/components/schemas/PriceAdjustmentTierParams"},"description":"Quantity bands on the list's percentage. The payload is the whole ladder: a band left out is removed."},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceListPriceOverrideParams"},"description":"Per-variant price overrides. Each row upserts, so the variants it names become part of the list. Curating whole products goes through the nested products endpoint instead."}},"required":["name"]},"PriceListPriceOverrideParams":{"type":"object","properties":{"id":{"type":"string","description":"Updates this price row. Without it, the row upserts on `(variant_id, currency, min_quantity)`."},"variant_id":{"type":"string"},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}]},"min_quantity":{"type":"integer","description":"The rung of the variant's ladder. Omit for the bottom rung."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}}},"PriceListRuleParams":{"type":"object","properties":{"id":{"type":"string","description":"Present for existing rules. Omit to create a new one.","nullable":true},"type":{"type":"string","description":"Wire shorthand for the rule kind, from the price rule types endpoint."},"preferences":{"type":"object","additionalProperties":true,"description":"The rule kind's settings, keyed by preference name."}},"required":["type"]},"PriceListUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"position":{"type":"integer"},"starts_at":{"type":"string","format":"date-time","description":"Pair with `ends_at` to schedule the list: activating a list whose start is in the future marks it `scheduled`.","nullable":true},"ends_at":{"type":"string","format":"date-time","nullable":true},"match_policy":{"type":"string","enum":["all","any"],"description":"`all`: every rule must match. `any`: one matching rule is enough."},"price_adjustment_percentage":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Signed: negative discounts off base prices, positive marks up.","nullable":true},"adjust_compare_at":{"type":"boolean"},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PriceListRuleParams"},"description":"The complete rule set: rules are matched by `id` and updated, new ones are built, and rules left out are removed."},"price_adjustment_tiers":{"type":"array","items":{"$ref":"#/components/schemas/PriceAdjustmentTierParams"},"description":"Quantity bands on the list's percentage. The payload is the whole ladder: a band left out is removed."},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceListPriceOverrideParams"},"description":"Per-variant price overrides. Each row upserts, so the variants it names become part of the list. Curating whole products goes through the nested products endpoint instead."}}},"PriceParams":{"type":"object","properties":{"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}]},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"A canonical decimal string (`\"1234.56\"`: period decimal, no grouping). The API does not parse localized input."},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true}},"required":["currency","amount"]},"PriceUpdateParams":{"type":"object","properties":{"variant_id":{"type":"string"},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}]},"min_quantity":{"type":"integer","description":"The quantity a line must reach for this price to apply. Omit for the bottom rung of the ladder. Anything above 1 requires a `price_list_id`."},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"compare_at_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"price_list_id":{"type":"string","description":"Omit or null for a base price; a price list for a list override.","nullable":true}}},"ProductBulkCategoriesParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"category_ids":{"type":"array","items":{"type":"string"}}},"required":["ids","category_ids"]},"ProductBulkChannelsParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"channel_ids":{"type":"array","items":{"type":"string"}}},"required":["ids","channel_ids"]},"ProductBulkCollectionsParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"collection_ids":{"type":"array","items":{"type":"string"}}},"required":["ids","collection_ids"]},"ProductBulkDestroyParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"},"description":"Products the caller cannot delete are skipped."}},"required":["ids"]},"ProductBulkStatusParams":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"string"}},"status":{"type":"string","enum":["draft","active","archived"],"description":"Products in review are skipped and counted in `skipped_in_review_count`."}},"required":["ids","status"]},"ProductCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"slug":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["draft","active","archived"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"tax_category_id":{"type":"string"},"product_type_id":{"type":"string","description":"The product type this product is created from (`pt_...`). Its option types and categories seed onto the product and its custom field definitions drive the product form. Editing the type later never rewrites existing products.","nullable":true},"delivery_profile_id":{"type":"string","description":"The delivery profile deciding how this product ships (`fp_...`); null falls back to the store default.","nullable":true},"promotionable":{"type":"boolean"},"tags":{"type":"array","items":{"type":"string"}},"category_ids":{"type":"array","items":{"type":"string"}},"collection_ids":{"type":"array","items":{"type":"string"},"description":"Manual collections this product belongs to. Automatic collections are kept as they are, since their rules decide membership."},"metadata":{"type":"object","additionalProperties":true},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Shorthand for a simple (no-options) product: per-currency prices that forward to the product's sole variant. For products with options, set prices per variant under `variants` instead. Don't pass both."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."},"media":{"type":"array","items":{"$ref":"#/components/schemas/ProductMediaParams"},"description":"Media written with the product. Entries with `id` update an existing asset; entries with `signed_id` attach a fresh upload; an external video needs only its URL."},"digital_assets":{"type":"array","items":{"$ref":"#/components/schemas/ProductDigitalAssetParams"},"description":"Downloadable files written with the product. Each entry carries a `signed_id` (an upload to private storage) or a `provider_type` (a provider-backed asset), and attaches to the default variant unless `variant_id` is given. An `id` updates that asset in place, so replaying the list does not duplicate it; removal uses the nested digital assets endpoint."},"product_publications":{"type":"array","items":{"$ref":"#/components/schemas/ProductPublicationParams"}},"variants":{"type":"array","items":{"$ref":"#/components/schemas/ProductVariantParams"},"description":"Every purchasable attribute (sku, prices, stock, weight, dimensions) lives on variants. An entry without `options` upserts onto the default variant of a simple product; pass `id` to update an existing variant."}},"required":["name"]},"ProductDigitalAssetParams":{"type":"object","properties":{"id":{"type":"string"},"signed_id":{"type":"string"},"variant_id":{"type":"string"},"provider_type":{"type":"string","description":"A provider shorthand from the digital asset providers endpoint."},"provider_settings":{"type":"object","additionalProperties":true,"description":"Values for the provider's settings schema, keyed by field name."},"authorized_clicks":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true},"authorized_days":{"type":"integer","description":"Null means the store's download settings apply.","nullable":true}}},"ProductMediaParams":{"type":"object","properties":{"id":{"type":"string"},"signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`."},"source_media_id":{"type":"string","description":"Copies an asset from the media library."},"alt":{"type":"string","nullable":true},"position":{"type":"integer"},"media_type":{"type":"string","enum":["image","video","external_video"],"description":"Defaults to `image`. `video` needs a `signed_id`; `external_video` needs an `external_video_url`."},"external_video_url":{"type":"string","description":"YouTube or Vimeo link. Required when `media_type` is `external_video`.","nullable":true},"poster_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for a video's poster frame."},"focal_point_x":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"focal_point_y":{"type":"number","description":"Where the image is anchored when cropped, from 0 to 1.","nullable":true},"variant_ids":{"type":"array","items":{"type":"string"},"description":"Replaces the variants this media is linked to. An empty list clears them."}}},"ProductMembershipParams":{"type":"object","properties":{"product_ids":{"type":"array","items":{"type":"string"},"description":"Products from other stores, or ones the caller cannot see, are ignored."}},"required":["product_ids"]},"ProductMembershipRepositionParams":{"type":"object","properties":{"new_position":{"type":"integer","description":"0-based index among the parent's products."}},"required":["new_position"]},"ProductPublicationParams":{"type":"object","properties":{"id":{"type":"string"},"channel_id":{"type":"string"},"published_at":{"type":"string","format":"date-time","nullable":true},"unpublished_at":{"type":"string","format":"date-time","nullable":true}}},"ProductRejectParams":{"type":"object","properties":{"reason":{"type":"string","description":"Why the submission was turned down. Sent back to the seller."}}},"ProductTypeCreateParams":{"type":"object","properties":{"name":{"type":"string"},"delivery_profile_id":{"type":"string","description":"Delivery profile stamped onto products created with this type. Null leaves new products on the store default profile.","nullable":true},"option_type_ids":{"type":"array","items":{"type":"string"},"description":"Option types seeded onto products that get this type. Use apply to products to backfill existing ones."},"category_ids":{"type":"array","items":{"type":"string"},"description":"Categories seeded onto products that get this type. Categories from other stores are ignored."},"custom_field_definitions":{"type":"array","items":{"$ref":"#/components/schemas/ProductTypeCustomFieldDefinitionParams"},"description":"The custom field definitions the product form shows. Definitions not listed are removed from the type."}},"required":["name"]},"ProductTypeCustomFieldDefinitionParams":{"type":"object","properties":{"id":{"type":"string","description":"The custom field definition."},"required":{"type":"boolean"},"sort_order":{"type":"integer"}},"required":["id"]},"ProductTypeUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"delivery_profile_id":{"type":"string","description":"Delivery profile stamped onto products created with this type. Null leaves new products on the store default profile.","nullable":true},"option_type_ids":{"type":"array","items":{"type":"string"},"description":"Option types seeded onto products that get this type. Use apply to products to backfill existing ones."},"category_ids":{"type":"array","items":{"type":"string"},"description":"Categories seeded onto products that get this type. Categories from other stores are ignored."},"custom_field_definitions":{"type":"array","items":{"$ref":"#/components/schemas/ProductTypeCustomFieldDefinitionParams"},"description":"The custom field definitions the product form shows. Definitions not listed are removed from the type."}}},"ProductUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"description":{"type":"string","description":"Rich text HTML. Reads come back as this (plain text) plus `description_html`."},"slug":{"type":"string"},"status":{"anyOf":[{"type":"string","enum":["draft","active","archived"]},{"type":"string"}],"description":"The values listed are the built-in ones; extensions may add more."},"meta_title":{"type":"string"},"meta_description":{"type":"string"},"meta_keywords":{"type":"string"},"tax_category_id":{"type":"string"},"product_type_id":{"type":"string","description":"The product type this product is created from (`pt_...`). Its option types and categories seed onto the product and its custom field definitions drive the product form. Editing the type later never rewrites existing products.","nullable":true},"delivery_profile_id":{"type":"string","description":"The delivery profile deciding how this product ships (`fp_...`); null falls back to the store default.","nullable":true},"promotionable":{"type":"boolean"},"tags":{"type":"array","items":{"type":"string"}},"category_ids":{"type":"array","items":{"type":"string"}},"collection_ids":{"type":"array","items":{"type":"string"},"description":"Manual collections this product belongs to. Automatic collections are kept as they are, since their rules decide membership."},"metadata":{"type":"object","additionalProperties":true},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Shorthand for a simple (no-options) product: per-currency prices that forward to the product's sole variant. For products with options, set prices per variant under `variants` instead. Don't pass both."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."},"media":{"type":"array","items":{"$ref":"#/components/schemas/ProductMediaParams"},"description":"Media written with the product. Entries with `id` update an existing asset; entries with `signed_id` attach a fresh upload; an external video needs only its URL."},"digital_assets":{"type":"array","items":{"$ref":"#/components/schemas/ProductDigitalAssetParams"},"description":"Downloadable files written with the product. Each entry carries a `signed_id` (an upload to private storage) or a `provider_type` (a provider-backed asset), and attaches to the default variant unless `variant_id` is given. An `id` updates that asset in place, so replaying the list does not duplicate it; removal uses the nested digital assets endpoint."},"product_publications":{"type":"array","items":{"$ref":"#/components/schemas/ProductPublicationParams"}},"variants":{"type":"array","items":{"$ref":"#/components/schemas/ProductVariantParams"},"description":"Every purchasable attribute (sku, prices, stock, weight, dimensions) lives on variants. An entry without `options` upserts onto the default variant of a simple product; pass `id` to update an existing variant."}}},"ProductVariantParams":{"type":"object","properties":{"id":{"type":"string"},"sku":{"type":"string"},"barcode":{"type":"string"},"cost_price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"cost_currency":{"$ref":"#/components/schemas/CurrencyCode"},"weight":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"depth":{"type":"number","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"hs_code":{"type":"string"},"customs_description":{"type":"string"},"country_of_origin":{"$ref":"#/components/schemas/CountryCode"},"minimum_order_quantity":{"type":"integer","nullable":true},"order_multiple":{"type":"integer","nullable":true},"purchase_unit":{"type":"string"},"units_per_carton":{"type":"integer","description":"How many units fill one carton.","nullable":true},"carton_package_type_id":{"type":"string","description":"The carton this variant is packed into: a package type of kind `carton`. Its dimensions are shared by every product packed the same way, so a corrected carton size fixes all of them at once.","nullable":true},"carton_weight":{"type":"number","description":"What one packed carton weighs, in the variant's weight unit.","nullable":true},"cartons_per_pallet":{"type":"integer","description":"How many cartons stack on one pallet.","nullable":true},"seller_id":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"track_inventory":{"type":"boolean"},"preorderable":{"type":"boolean","description":"Sell this variant before it's in stock. Adds the pre-order label and ships-by promise; the cap comes from `backorder_limit`, an incoming stock count, or backorder."},"preorder_ships_at":{"type":"string","format":"date-time","description":"The \"ships by\" date shown to customers while the variant is a pre-order. Once it passes, the variant is no longer a pre-order. Null clears it.","nullable":true},"backorder_limit":{"type":"integer","description":"Maximum units sellable beyond available stock, capping backorders and pre-orders. Null is unlimited.","nullable":true},"tax_category_id":{"type":"string"},"position":{"type":"integer"},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Per-currency prices. Upserted by currency."},"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevelParams"},"description":"Stock per location. Upserted by location; omitted locations are removed."},"options":{"type":"array","items":{"$ref":"#/components/schemas/VariantOptionParams"},"description":"One pair per option type the variant takes part in (size, color). Option types and values are created when missing."}}},"PromotionActionCalculatorParams":{"type":"object","properties":{"type":{"type":"string","description":"The calculator kind, from `GET /promotion_actions/calculators`. Changing it swaps the calculator."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the calculator's settings, such as `amount` or `flat_percent`."}}},"PromotionActionCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"The action kind, from `GET /promotion_actions/types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the action kind's settings schema, from `GET /promotion_actions/types`."},"calculator":{"allOf":[{"$ref":"#/components/schemas/PromotionActionCalculatorParams"}],"description":"For adjustment actions."},"line_items":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionLineItemParams"},"description":"For `create_line_items`: the variants to add and their quantities. Variants left out are removed."}},"required":["type"]},"PromotionActionDraftParams":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","description":"The action kind, from `GET /promotion_actions/types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the action kind's settings schema, from `GET /promotion_actions/types`."},"calculator":{"allOf":[{"$ref":"#/components/schemas/PromotionActionCalculatorParams"}],"description":"For adjustment actions."},"line_items":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionLineItemParams"},"description":"For `create_line_items`: the variants to add and their quantities. Variants left out are removed."}},"required":["type"]},"PromotionActionLineItemParams":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["variant_id","quantity"]},"PromotionActionUpdateParams":{"type":"object","properties":{"preferences":{"type":"object","additionalProperties":true,"description":"Values for the action kind's settings schema, from `GET /promotion_actions/types`."},"calculator":{"allOf":[{"$ref":"#/components/schemas/PromotionActionCalculatorParams"}],"description":"For adjustment actions."},"line_items":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionLineItemParams"},"description":"For `create_line_items`: the variants to add and their quantities. Variants left out are removed."}}},"PromotionCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"code":{"type":"string","description":"Required for single-code coupon promotions. Ignored when `multi_codes` is true.","nullable":true},"path":{"type":"string","nullable":true},"starts_at":{"type":"string","format":"date-time","nullable":true},"expires_at":{"type":"string","format":"date-time","nullable":true},"usage_limit":{"type":"integer","nullable":true},"match_policy":{"type":"string","enum":["all","any"]},"kind":{"type":"string","enum":["coupon_code","automatic"],"description":"`coupon_code` needs a code (or `multi_codes`); `automatic` applies without one."},"multi_codes":{"type":"boolean","description":"Generates `number_of_codes` codes starting with `code_prefix`."},"number_of_codes":{"type":"integer","nullable":true},"code_prefix":{"type":"string","nullable":true},"promotion_category_id":{"type":"string","nullable":true},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PromotionRuleDraftParams"},"description":"The rules the promotion should have: entries with `id` update, entries without are created, and rules left out are removed."},"actions":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionDraftParams"},"description":"The actions the promotion should have, matched the same way as `rules`."}},"required":["name"]},"PromotionRuleCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"The rule kind, from `GET /promotion_rules/types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's settings schema, from `GET /promotion_rules/types`."},"product_ids":{"type":"array","items":{"type":"string"},"description":"For the `product` rule."},"category_ids":{"type":"array","items":{"type":"string"},"description":"For the `category` rule."},"customer_ids":{"type":"array","items":{"type":"string"},"description":"For the `user` rule: the customers who qualify."}},"required":["type"]},"PromotionRuleDraftParams":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","description":"The rule kind, from `GET /promotion_rules/types`."},"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's settings schema, from `GET /promotion_rules/types`."},"product_ids":{"type":"array","items":{"type":"string"},"description":"For the `product` rule."},"category_ids":{"type":"array","items":{"type":"string"},"description":"For the `category` rule."},"customer_ids":{"type":"array","items":{"type":"string"},"description":"For the `user` rule: the customers who qualify."}},"required":["type"]},"PromotionRuleUpdateParams":{"type":"object","properties":{"preferences":{"type":"object","additionalProperties":true,"description":"Values for the rule kind's settings schema, from `GET /promotion_rules/types`."},"product_ids":{"type":"array","items":{"type":"string"},"description":"For the `product` rule."},"category_ids":{"type":"array","items":{"type":"string"},"description":"For the `category` rule."},"customer_ids":{"type":"array","items":{"type":"string"},"description":"For the `user` rule: the customers who qualify."}}},"PromotionUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"code":{"type":"string","description":"Required for single-code coupon promotions. Ignored when `multi_codes` is true.","nullable":true},"path":{"type":"string","nullable":true},"starts_at":{"type":"string","format":"date-time","nullable":true},"expires_at":{"type":"string","format":"date-time","nullable":true},"usage_limit":{"type":"integer","nullable":true},"match_policy":{"type":"string","enum":["all","any"]},"kind":{"type":"string","enum":["coupon_code","automatic"],"description":"`coupon_code` needs a code (or `multi_codes`); `automatic` applies without one."},"multi_codes":{"type":"boolean","description":"Generates `number_of_codes` codes starting with `code_prefix`."},"number_of_codes":{"type":"integer","nullable":true},"code_prefix":{"type":"string","nullable":true},"promotion_category_id":{"type":"string","nullable":true},"rules":{"type":"array","items":{"$ref":"#/components/schemas/PromotionRuleDraftParams"},"description":"The rules the promotion should have: entries with `id` update, entries without are created, and rules left out are removed."},"actions":{"type":"array","items":{"$ref":"#/components/schemas/PromotionActionDraftParams"},"description":"The actions the promotion should have, matched the same way as `rules`."}}},"PurchaseOrderCancelParams":{"type":"object","properties":{"reason":{"type":"string","description":"Appended to the order's notes."}}},"PurchaseOrderCreateParams":{"type":"object","properties":{"supplier_id":{"type":"string"},"destination_location_id":{"type":"string"},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"Defaults to the store's currency; set it for a foreign-currency order.","nullable":true},"expected_at":{"type":"string","format":"date","description":"The day the supplier promised. `null` clears it.","nullable":true},"cancel_by":{"type":"string","format":"date","description":"The day after which the goods are no longer wanted. `null` clears it.","nullable":true},"reference":{"type":"string","description":"The supplier's own order number. `null` clears it.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/PurchaseOrderItemParams"},"description":"Sending the list replaces whatever the order currently holds."}},"required":["supplier_id","destination_location_id"]},"PurchaseOrderItemParams":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity_ordered":{"type":"integer"},"unit_cost":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"What the merchant agreed to pay per unit."}},"required":["variant_id","quantity_ordered"]},"PurchaseOrderUpdateParams":{"type":"object","properties":{"supplier_id":{"type":"string"},"destination_location_id":{"type":"string"},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"Defaults to the store's currency; set it for a foreign-currency order.","nullable":true},"expected_at":{"type":"string","format":"date","description":"The day the supplier promised. `null` clears it.","nullable":true},"cancel_by":{"type":"string","format":"date","description":"The day after which the goods are no longer wanted. `null` clears it.","nullable":true},"reference":{"type":"string","description":"The supplier's own order number. `null` clears it.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/PurchaseOrderItemParams"},"description":"Sending the list replaces whatever the order currently holds."},"metadata":{"type":"object","additionalProperties":true,"nullable":true}}},"ReasonCreateParams":{"type":"object","properties":{"name":{"type":"string"},"active":{"type":"boolean","description":"Whether the reason is offered on new records."}},"required":["name"]},"ReasonUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"active":{"type":"boolean","description":"Whether the reason is offered on new records."}}},"ReceivableCloseParams":{"type":"object","properties":{"reason":{"type":"string","description":"Why the balance is not coming.","nullable":true}}},"RefundCreateParams":{"type":"object","properties":{"payment_id":{"type":"string"},"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$"},"refund_reason_id":{"type":"string","description":"Defaults to the store's first refund reason."}},"required":["payment_id","amount"]},"ReportingQueryParams":{"type":"object","properties":{"metrics":{"type":"array","items":{"type":"string"},"description":"Registered metric names, from the reporting schema endpoint."},"dimensions":{"type":"array","items":{},"description":"Up to 2 dimensions to break the metrics down by. Each is a dimension name, or `{ name, grain, include_empty }`: `grain` (`hour`, `day`, `week`, `month`) buckets a time dimension, and `include_empty` lists members with no matching rows where the schema entry supports it."},"filters":{"type":"array","items":{"type":"object","properties":{"dimension":{"type":"string"},"op":{"type":"string","enum":["eq","in"]},"value":{"description":"One value for `eq`, a list for `in`."}},"required":["dimension","op","value"]},"description":"Narrows the rows by dimension value."},"metric_filters":{"type":"array","items":{"type":"object","properties":{"metric":{"type":"string"},"op":{"type":"string","enum":["eq","gt","gte","lt","lte"]},"value":{"type":"number"}},"required":["metric","op","value"]},"description":"Filters on an aggregate, such as `units_sold = 0`. Narrows the rows only; the totals stay the period's real figure. The metric must also appear in `metrics`, and cannot be a derived one."},"time_range":{"type":"object","properties":{"preset":{"type":"string"},"since":{"type":"string"},"until":{"type":"string"}},"description":"A named preset (`last_month`, `week_to_date`, any `last_<n>_<days|weeks|months>`), or ISO 8601 dates or times in `since` and `until` (a bare date covers the store's whole day). Defaults to the last 30 days, in the store's time zone."},"compare":{"type":"string","enum":["previous_period","previous_year"]},"sort":{"type":"string","description":"A metric name; prefix it with `-` to sort descending."},"limit":{"type":"integer","description":"At most 1000."},"currency":{"$ref":"#/components/schemas/CurrencyCode"}},"required":["metrics"]},"ReturnCancelParams":{"type":"object","properties":{"reason":{"type":"string","description":"A note on why the return was canceled."}}},"ReturnCreateParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"fulfillment_item_id":{"type":"string"},"quantity":{"type":"integer"}},"required":["fulfillment_item_id","quantity"]},"description":"Fulfilled units coming back, and how many of each."},"stock_location_id":{"type":"string","description":"Where the goods come back to. Defaults to the location that shipped them."},"reason_id":{"type":"string","description":"One of the store's return reasons."},"memo":{"type":"string"}},"required":["items"]},"ReturnReceiveParams":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"return_line_item_id":{"type":"string"},"quantity":{"type":"integer"},"resellable":{"type":"boolean","description":"Goods that cannot be resold are received but never restocked. Defaults to true."}},"required":["return_line_item_id","quantity"]},"description":"What actually arrived. Omit to receive everything as requested and resellable; send rows for a partial or damaged receipt."}}},"ReturnRefundParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Defaults to the value of what was actually received."},"refund_method":{"type":"string","enum":["original_payment","store_credit"],"description":"`store_credit` issues credit immediately; `original_payment` (the default) refunds through the gateway that took the money."}}},"ReturnUpdateParams":{"type":"object","properties":{"stock_location_id":{"type":"string","description":"Where the goods come back to. Defaults to the location that shipped them."},"reason_id":{"type":"string","description":"One of the store's return reasons."},"memo":{"type":"string"},"metadata":{"type":"object","additionalProperties":true}}},"RoleCreateParams":{"type":"object","properties":{"name":{"type":"string","description":"Unique role name, the machine identifier shown capitalized in the dashboard."},"description":{"type":"string","nullable":true},"permissions":{"type":"array","items":{"type":"string"},"description":"Permission keys (`read_orders`, `write_products`, ...) from the permissions endpoint. You can only grant keys you hold yourself."}},"required":["name"]},"RoleUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"Unique role name, the machine identifier shown capitalized in the dashboard."},"description":{"type":"string","nullable":true},"permissions":{"type":"array","items":{"type":"string"},"description":"Permission keys (`read_orders`, `write_products`, ...) from the permissions endpoint. You can only grant keys you hold yourself."}}},"SavedReportCreateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"query":{"type":"object","additionalProperties":true,"description":"A reporting query, validated against the reporting registry on save."}},"required":["name","query"]},"SavedReportUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"query":{"type":"object","additionalProperties":true,"description":"A reporting query, validated against the reporting registry on save."}}},"SellerAddressParams":{"type":"object","properties":{"first_name":{"type":"string"},"last_name":{"type":"string"},"company":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string"},"city":{"type":"string"},"postal_code":{"type":"string"},"phone":{"type":"string"},"label":{"type":"string"},"zipcode":{"type":"string","description":"Legacy spelling of `postal_code`; send only one of the two."},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"ISO 3166-1 alpha-2 code, such as `US`."},"state_code":{"type":"string","description":"The state or province abbreviation, such as `NY`."},"state_name":{"type":"string","description":"For countries without states in the database."}}},"SellerApproveParams":{"type":"object","properties":{"override_requirements":{"type":"boolean","description":"Admits a seller whose onboarding checklist is unfinished: the operator's deliberate exception, which the `seller.approved` event records along with what was outstanding."}}},"SellerCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"slug":{"type":"string","description":"URL-safe slug, derived from the name when omitted."},"contact_email":{"type":"string","nullable":true},"billing_email":{"type":"string","nullable":true},"about":{"type":"string","description":"Sanitized HTML: the seller's public description.","nullable":true},"logo_signed_id":{"type":"string","description":"A `signed_id` from the files upload endpoint to set the image, `null` to remove it, or omit the key to leave it untouched. The same applies to `square_logo_signed_id` and `cover_photo_signed_id`.","nullable":true},"square_logo_signed_id":{"type":"string","nullable":true},"cover_photo_signed_id":{"type":"string","nullable":true},"tax_remittance":{"type":"string","enum":["seller","platform"]},"payouts_schedule_interval":{"type":"string","enum":["daily","weekly","biweekly","monthly","manual"],"nullable":true},"minimum_payout_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"holiday_mode_until":{"type":"string","format":"date-time","description":"Set while the seller is away: the catalog stays but stops selling.","nullable":true},"legal_name":{"type":"string","nullable":true},"registration_number":{"type":"string","nullable":true},"metadata":{"type":"object","additionalProperties":true},"billing_address":{"allOf":[{"$ref":"#/components/schemas/SellerAddressParams"}],"description":"The seller's own billing address, written inline. There is no `billing_address_id`: an address belongs to whoever it was created for, so it is never referenced by id."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}},"required":["name"]},"SellerInviteParams":{"type":"object","properties":{"email":{"type":"string"},"role_id":{"type":"string","description":"A role this seller owns; defaults to the seller's own admin role.","nullable":true}},"required":["email"]},"SellerPayoutCompleteParams":{"type":"object","properties":{"reference":{"type":"string","description":"The provider's own id for the settlement, when one made it."}}},"SellerRejectParams":{"type":"object","properties":{"reason":{"type":"string"}}},"SellerReopenOnboardingParams":{"type":"object","properties":{"note":{"type":"string","description":"What the seller has to fix."}}},"SellerRequirementCreateParams":{"type":"object","properties":{"type":{"type":"string","description":"The kind, from the seller requirement types endpoint."},"name":{"type":"string","description":"What the seller sees. Required for kinds that can be added more than once, since the wording is the only thing telling them apart. Left blank on the others, the kind names itself."},"description":{"type":"string","description":"Instructions shown to the seller."},"position":{"type":"integer","description":"Place in the checklist."},"active":{"type":"boolean"},"required":{"type":"boolean","description":"Whether this blocks approval. Off means recommended."},"preferences":{"type":"object","additionalProperties":true,"description":"Configuration for this kind, per its type's `schema`."},"metadata":{"type":"object","additionalProperties":true},"custom_field_definition_ids":{"type":"array","items":{"type":"string"},"description":"Custom field definitions this requirement asks the seller to fill in (`required_custom_fields` kind)."}},"required":["type"]},"SellerRequirementReviewParams":{"type":"object","properties":{"review_note":{"type":"string","description":"Kept with the decision. On a rejection it is the reason sent back to the seller."}}},"SellerRequirementUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"What the seller sees. Required for kinds that can be added more than once, since the wording is the only thing telling them apart. Left blank on the others, the kind names itself."},"description":{"type":"string","description":"Instructions shown to the seller."},"position":{"type":"integer","description":"Place in the checklist."},"active":{"type":"boolean"},"required":{"type":"boolean","description":"Whether this blocks approval. Off means recommended."},"preferences":{"type":"object","additionalProperties":true,"description":"Configuration for this kind, per its type's `schema`."},"metadata":{"type":"object","additionalProperties":true},"custom_field_definition_ids":{"type":"array","items":{"type":"string"},"description":"Custom field definitions this requirement asks the seller to fill in (`required_custom_fields` kind)."}}},"SellerRequirementWaiveParams":{"type":"object","properties":{"requirement_id":{"type":"string","description":"The requirement the seller is excused from."},"review_note":{"type":"string","description":"Why the seller is excused. Kept with the decision."}},"required":["requirement_id"]},"SellerSuspendParams":{"type":"object","properties":{"reason":{"type":"string"}}},"SellerUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"slug":{"type":"string","description":"URL-safe slug, derived from the name when omitted."},"contact_email":{"type":"string","nullable":true},"billing_email":{"type":"string","nullable":true},"about":{"type":"string","description":"Sanitized HTML: the seller's public description.","nullable":true},"logo_signed_id":{"type":"string","description":"A `signed_id` from the files upload endpoint to set the image, `null` to remove it, or omit the key to leave it untouched. The same applies to `square_logo_signed_id` and `cover_photo_signed_id`.","nullable":true},"square_logo_signed_id":{"type":"string","nullable":true},"cover_photo_signed_id":{"type":"string","nullable":true},"tax_remittance":{"type":"string","enum":["seller","platform"]},"payouts_schedule_interval":{"type":"string","enum":["daily","weekly","biweekly","monthly","manual"],"nullable":true},"minimum_payout_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"holiday_mode_until":{"type":"string","format":"date-time","description":"Set while the seller is away: the catalog stays but stops selling.","nullable":true},"legal_name":{"type":"string","nullable":true},"registration_number":{"type":"string","nullable":true},"metadata":{"type":"object","additionalProperties":true},"billing_address":{"allOf":[{"$ref":"#/components/schemas/SellerAddressParams"}],"description":"The seller's own billing address, written inline. There is no `billing_address_id`: an address belongs to whoever it was created for, so it is never referenced by id."},"custom_fields":{"type":"array","items":{"$ref":"#/components/schemas/CustomFieldValueParams"},"description":"Custom field values, each validated against its definition."}}},"SetupParams":{"type":"object","properties":{"setup_token":{"type":"string","description":"The one-time token from the install output."},"email":{"type":"string","format":"email"},"password":{"type":"string"},"password_confirmation":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"store_name":{"type":"string"},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"ISO 3166-1 alpha-2 country the store sells from. It determines the default market, the warehouse, the delivery zones and the currency."},"locale":{"type":"string","description":"Storefront locale. Defaults to the country's own language."},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"ISO 4217 currency. Defaults to the country's own currency: pass one only when the store prices in something else."},"sample_data":{"type":"boolean","description":"Load the demo catalog, customers and orders in the background once the admin account exists. The load takes minutes, so the response does not wait for it."}},"required":["setup_token","email","password","country_code"]},"ShippingLabelCreateParams":{"type":"object","properties":{"file_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()`. Its presence records a label bought elsewhere instead of buying one; without it the body is ignored and the label is bought through the carrier."},"tracking_number":{"type":"string","description":"The number printed on an uploaded label. Required with `file_signed_id`."},"carrier":{"type":"string","description":"Free text; a forwarder's name is as valid as a carrier slug. Detected from the number when omitted."},"service":{"type":"string","description":"Carrier service the label was bought at."},"cost":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"What the merchant paid the carrier. Accounting data only; it never touches the order's shipping charge."},"currency":{"allOf":[{"$ref":"#/components/schemas/CurrencyCode"}],"description":"Currency of the cost."},"file_format":{"type":"string","enum":["pdf","png","zpl"],"description":"Taken from the file when omitted."},"tracking_url":{"type":"string","description":"Tracking page for the consignment the label mints."}}},"StockLevelBulkUpsertParams":{"type":"object","properties":{"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevelBulkUpsertRowParams"},"description":"Send an empty list to change nothing."}},"required":["stock_levels"]},"StockLevelBulkUpsertRowParams":{"type":"object","properties":{"variant_id":{"type":"string"},"stock_location_id":{"type":"string"},"count_on_hand":{"type":"integer","description":"The absolute level the external system reports.","nullable":true},"adjustment":{"type":"integer","description":"A relative change, for feeds that report movements rather than levels. Each row needs `count_on_hand` or `adjustment`.","nullable":true},"backorderable":{"type":"boolean","nullable":true}},"required":["variant_id","stock_location_id"]},"StockLevelParams":{"type":"object","properties":{"id":{"type":"string"},"stock_location_id":{"type":"string","description":"The location holding the stock (`sloc_...`)."},"count_on_hand":{"type":"integer","description":"Units physically at the location, not units available to sell: stock promised to placed orders counts until it ships. Sent as the count the shelf should end at; the API records the difference as an adjustment in the stock history."},"backorderable":{"type":"boolean","description":"Whether this location sells the variant beyond what it holds."}},"required":["stock_location_id","count_on_hand"]},"StockLevelUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"count_on_hand":{"type":"integer","description":"The count the shelf should end at: a whole number of zero or more. The API records the difference as an `adjusted` movement, so the correction appears in the stock history."},"adjustment":{"type":"integer","description":"A signed change to the shelf instead of a target count, applied to the count the API holds at that moment and recorded the same way. Cannot be sent together with `count_on_hand`."},"backorderable":{"type":"boolean","description":"Whether this location sells the variant beyond what it holds."},"reason":{"type":"string","description":"Labels the correction in the stock history. Defaults to \"Manual adjustment\"."},"metadata":{"type":"object","additionalProperties":true}}},"StockLocationCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"admin_name":{"type":"string","description":"Internal name shown only in the admin.","nullable":true},"active":{"type":"boolean"},"default":{"type":"boolean","description":"Setting to true demotes the previous default."},"kind":{"anyOf":[{"type":"string","enum":["warehouse","store","fulfillment_center"]},{"type":"string"}],"description":"Categorizes the location. The values listed are the built-in ones; extensions may add more."},"propagate_all_variants":{"type":"boolean"},"backorderable_default":{"type":"boolean"},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"zipcode":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"ISO-3166 alpha-2 country code.","nullable":true},"state_code":{"type":"string","description":"State or province abbreviation, resolved against the selected country's states.","nullable":true},"state_name":{"type":"string","description":"Free-text state for countries that don't have a states list.","nullable":true},"pickup_enabled":{"type":"boolean"},"pickup_stock_policy":{"type":"string","enum":["local","any"],"description":"`local` collects only items at this location; `any` lets items transfer in from other locations (ship-to-store)."},"pickup_ready_in_minutes":{"type":"integer","nullable":true},"returns_enabled":{"type":"boolean","description":"Whether customers may send returns to this location."},"pickup_instructions":{"type":"string","nullable":true}},"required":["name"]},"StockLocationUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"name":{"type":"string"},"admin_name":{"type":"string","description":"Internal name shown only in the admin.","nullable":true},"active":{"type":"boolean"},"default":{"type":"boolean","description":"Setting to true demotes the previous default."},"kind":{"anyOf":[{"type":"string","enum":["warehouse","store","fulfillment_center"]},{"type":"string"}],"description":"Categorizes the location. The values listed are the built-in ones; extensions may add more."},"propagate_all_variants":{"type":"boolean"},"backorderable_default":{"type":"boolean"},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"zipcode":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"ISO-3166 alpha-2 country code.","nullable":true},"state_code":{"type":"string","description":"State or province abbreviation, resolved against the selected country's states.","nullable":true},"state_name":{"type":"string","description":"Free-text state for countries that don't have a states list.","nullable":true},"pickup_enabled":{"type":"boolean"},"pickup_stock_policy":{"type":"string","enum":["local","any"],"description":"`local` collects only items at this location; `any` lets items transfer in from other locations (ship-to-store)."},"pickup_ready_in_minutes":{"type":"integer","nullable":true},"returns_enabled":{"type":"boolean","description":"Whether customers may send returns to this location."},"pickup_instructions":{"type":"string","nullable":true}}},"StockReceiptCreateParams":{"type":"object","properties":{"reference":{"type":"string","description":"The supplier's delivery note, or the carrier's reference.","nullable":true},"received_at":{"type":"string","format":"date-time","description":"When the goods were counted in. Defaults to now.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockReceiptItemParams"},"description":"Omit to book in everything still outstanding, intact. Naming lines, even none, records exactly what the dock counted: `quantity_accepted` reaches the shelf; `quantity_rejected` is refused, recorded with a `rejection_reason` and never stocked."}}},"StockReceiptItemParams":{"type":"object","properties":{"id":{"type":"string","description":"The purchase order or transfer line."},"quantity_accepted":{"type":"integer"},"quantity_rejected":{"type":"integer"},"rejection_reason":{"type":"string","enum":["damaged","wrong_item","expired","other"],"nullable":true},"notes":{"type":"string","nullable":true}},"required":["id"]},"StockTransferCancelParams":{"type":"object","properties":{"on_in_transit":{"type":"string","enum":["restock","write_off"],"description":"Required once the units have left the source: either they come back (`restock`) or they are written off as lost (`write_off`)."},"reason":{"type":"string","description":"Recorded against the written-off lines.","nullable":true}}},"StockTransferCreateParams":{"type":"object","properties":{"source_location_id":{"type":"string"},"destination_location_id":{"type":"string"},"reference":{"type":"string","description":"The merchant's own label for the trip. `null` clears it.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockTransferItemParams"},"description":"A draft may open empty and gain lines as the merchant packs. Sending the list replaces whatever the draft currently holds."}},"required":["source_location_id","destination_location_id"]},"StockTransferItemParams":{"type":"object","properties":{"variant_id":{"type":"string"},"quantity_shipped":{"type":"integer"}},"required":["variant_id","quantity_shipped"]},"StockTransferMarkInTransitParams":{"type":"object","properties":{"force":{"type":"boolean","description":"Ship even if it drives the source below zero."}}},"StockTransferUpdateParams":{"type":"object","properties":{"source_location_id":{"type":"string"},"destination_location_id":{"type":"string"},"reference":{"type":"string","description":"The merchant's own label for the trip. `null` clears it.","nullable":true},"notes":{"type":"string","nullable":true},"items":{"type":"array","items":{"$ref":"#/components/schemas/StockTransferItemParams"},"description":"A draft may open empty and gain lines as the merchant packs. Sending the list replaces whatever the draft currently holds."},"metadata":{"type":"object","additionalProperties":true,"nullable":true}}},"StoreCreditApplyParams":{"type":"object","properties":{"amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Defaults to the customer's available store credit, up to the order total."}}},"StoreUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"admin_locale":{"type":"string"},"timezone":{"type":"string"},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"unit_system":{"type":"string","enum":["metric","imperial"]},"storefront_access":{"type":"string","enum":["public","prices_hidden","login_required"],"description":"The store-wide default for what anonymous visitors can see. Channels fall back to it when they don't set their own."},"storefront_url":{"type":"string","description":"The storefront's public URL, the base for links in customer emails. Saving it also completes the storefront setup task.","nullable":true},"guest_checkout":{"type":"boolean","description":"The store-wide default for guest checkout. Channels fall back to it."},"always_include_confirm_step":{"type":"boolean","description":"Always show a confirmation step in checkout, even when no payment method requires one."},"company_field_enabled":{"type":"boolean","description":"Shows a company field on address forms."},"address_requires_company":{"type":"boolean","description":"Makes a company name mandatory on addresses."},"address_requires_phone":{"type":"boolean","description":"Makes a phone number mandatory on customer addresses."},"capture_method":{"type":"string","enum":["checkout","on_dispatch","manual"],"description":"The store-wide default for when a customer is charged rather than only authorized. A payment method's own setting wins when set."},"track_inventory_levels":{"type":"boolean","description":"Counts on-hand quantities. Off means everything is treated as always available."},"stock_reservations_enabled":{"type":"boolean","description":"Holds stock for shoppers while they check out, so the same item can't be sold twice."},"low_stock_threshold":{"type":"integer","description":"On-hand units at or below which a tracked variant counts as low stock on the home screen; 0 turns the warning off."},"tax_using_ship_address":{"type":"boolean","description":"Calculates tax from the shipping address. When false, tax is calculated from the billing address."},"track_price_history":{"type":"boolean","description":"Records price changes for the EU Omnibus lowest-price-in-30-days display."},"show_products_without_price":{"type":"boolean","description":"Whether products with no price in the shopper's currency still appear in listings."},"disable_sku_validation":{"type":"boolean","description":"Lets more than one variant share the same SKU."},"order_routing_strategy":{"type":"string","description":"The store-wide order routing strategy shorthand. Channels fall back to it."},"pricing_provider":{"type":"string","description":"Where prices come from: a registered provider key, or `internal`."},"inventory_provider":{"type":"string","description":"Where stock levels come from: a registered provider key, or `internal`."},"pricing_provider_failure_policy":{"type":"string","enum":["fallback","strict"],"description":"`strict` refuses to price when the provider cannot answer; `fallback` uses the catalog."},"inventory_provider_failure_policy":{"type":"string","enum":["fallback","strict"],"description":"`fallback` sells on the local stock snapshot when the provider cannot answer; `strict` refuses."},"payout_provider":{"type":"string","description":"Blank means the built-in provider: the marketplace settles by hand."},"default_payouts_schedule_interval":{"type":"string","enum":["daily","weekly","biweekly","monthly","manual"]},"default_minimum_payout_amount":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"In the store's currency."},"auto_approve_sellers":{"type":"boolean","description":"Admits a seller as soon as they finish onboarding, with no operator review."},"auto_approve_seller_products":{"type":"boolean","description":"Puts a seller product on sale the moment it is submitted, with no review."},"send_seller_transactional_emails":{"type":"boolean","description":"When false, transactional seller emails (approval, payouts and so on) are not sent."},"default_commission_tax_rate":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"Tax charged on commission as a fraction (`\"0.23\"` is 23%), when neither the commission rate nor the tax provider names one."},"document_number_format":{"type":"string","description":"How document numbers are produced: `sequential` or `random`. Applies to every numbered document."},"order_number_prefix":{"type":"string","description":"Leads every order number. Uppercase letters, digits, dashes and # only."},"order_number_suffix":{"type":"string","description":"Ends every order number. Uppercase letters, digits, dashes and # only."},"order_number_sequence_start":{"type":"integer","description":"The first sequential order number. Only applies before the store's first order."},"limit_digital_download_count":{"type":"boolean","description":"Whether a digital download link stops working after a number of clicks."},"digital_asset_authorized_clicks":{"type":"integer","description":"How many clicks a download link allows, unless the file sets its own."},"limit_digital_download_days":{"type":"boolean","description":"Whether a digital download link expires after a number of days."},"digital_asset_authorized_days":{"type":"integer","description":"How many days a download link stays valid, unless the file sets its own."},"mail_from_address":{"type":"string","description":"Sender address of every transactional email."},"customer_support_email":{"type":"string","description":"Customer-facing reply-to address shown in the storefront and email footers.","nullable":true},"new_order_notifications_email":{"type":"string","description":"Recipient of \"new order placed\" staff notifications.","nullable":true},"send_consumer_transactional_emails":{"type":"boolean","description":"When false, transactional customer emails (order confirmation and so on) are not sent."},"email_accent_color":{"type":"string","description":"Customer email buttons and links, as `#RRGGBB`. Blank keeps the outlined buttons emails ship with.","nullable":true},"email_background_color":{"type":"string","description":"Customer email page background, as `#RRGGBB`.","nullable":true},"email_card_color":{"type":"string","description":"Customer email card behind the content, as `#RRGGBB`.","nullable":true},"email_text_color":{"type":"string","description":"Customer email body text, as `#RRGGBB`.","nullable":true},"email_heading_color":{"type":"string","description":"Customer email headings and emphasized text, as `#RRGGBB`.","nullable":true},"email_font":{"type":"string","description":"Customer email font: `inter`, `system`, `helvetica`, `georgia`, `roboto`, `lato` or `merriweather`.","nullable":true},"logo_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the store logo, or null to remove it.","nullable":true},"mailer_logo_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` for the logo in transactional emails, or null to remove it.","nullable":true}}},"SupplierCreateParams":{"type":"object","properties":{"name":{"type":"string"},"contact_name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"nullable":true},"postal_code":{"type":"string","nullable":true},"metadata":{"type":"object","additionalProperties":true,"nullable":true}},"required":["name"]},"SupplierUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"contact_name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phone":{"type":"string","nullable":true},"notes":{"type":"string","nullable":true},"address1":{"type":"string","nullable":true},"address2":{"type":"string","nullable":true},"city":{"type":"string","nullable":true},"state_name":{"type":"string","nullable":true},"state_code":{"type":"string","nullable":true},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"nullable":true},"postal_code":{"type":"string","nullable":true},"metadata":{"type":"object","additionalProperties":true,"nullable":true}}},"TaxCategoryCreateParams":{"type":"object","properties":{"name":{"type":"string"},"tax_code":{"type":"string","nullable":true},"description":{"type":"string","nullable":true},"is_default":{"type":"boolean"}},"required":["name"]},"TaxCategoryUpdateParams":{"type":"object","properties":{"name":{"type":"string"},"tax_code":{"type":"string","nullable":true},"description":{"type":"string","nullable":true},"is_default":{"type":"boolean"}}},"TaxExemptionCertificateParams":{"type":"object","properties":{"certificate_number":{"type":"string","description":"Required when creating."},"reason_code":{"type":"string","description":"Becomes the tax provider's entity use code. Required when creating."},"issuing_authority":{"type":"string","nullable":true},"issued_at":{"type":"string","format":"date-time","nullable":true},"expires_at":{"type":"string","format":"date-time","nullable":true},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"Where the certificate holds. Omit it and `state_code` for one valid everywhere.","nullable":true},"state_code":{"type":"string","nullable":true},"document_signed_id":{"type":"string","description":"A `signed_id` from `files.upload()` with `visibility: 'private'`."},"metadata":{"type":"object","additionalProperties":true}}},"TaxIdentifierParams":{"type":"object","properties":{"kind":{"type":"string","description":"The registration the number belongs to, such as `eu_vat` or `gb_vat`. Any kind is accepted; one with a registered validator is checked by it. Built-in: `eu_vat`. Extensions may register more. Required when creating."},"value":{"type":"string","description":"Required when creating."}}},"TaxRateParams":{"type":"object","properties":{"name":{"type":"string","description":"Customer-facing rate name."},"rate":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"The rate as a fraction. Send this or `rate_percent`."},"rate_percent":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","description":"The rate as a percentage."},"included_in_price":{"type":"boolean"},"show_rate_in_label":{"type":"boolean"},"tax_category_id":{"type":"string"},"country_code":{"allOf":[{"$ref":"#/components/schemas/CountryCode"}],"description":"ISO country code. A rate naming no country taxes everywhere.","nullable":true},"state_code":{"type":"string","description":"State abbreviation within that country.","nullable":true},"metadata":{"type":"object","additionalProperties":true}}},"TranslationBatchEntryParams":{"type":"object","properties":{"resource_type":{"type":"string","description":"Translatable resource type token, e.g. `option_type`."},"resource_id":{"type":"string"},"values":{"type":"object","additionalProperties":true,"description":"Translated fields keyed by locale code, then by field name."}},"required":["resource_type","resource_id","values"]},"TranslationBatchParams":{"type":"object","properties":{"translations":{"type":"array","items":{"$ref":"#/components/schemas/TranslationBatchEntryParams"},"description":"At least one entry. All entries are saved, or none are."}},"required":["translations"]},"VariantCreateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"sku":{"type":"string"},"barcode":{"type":"string"},"cost_price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"cost_currency":{"$ref":"#/components/schemas/CurrencyCode"},"weight":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"depth":{"type":"number","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"hs_code":{"type":"string"},"customs_description":{"type":"string"},"country_of_origin":{"$ref":"#/components/schemas/CountryCode"},"minimum_order_quantity":{"type":"integer","nullable":true},"order_multiple":{"type":"integer","nullable":true},"purchase_unit":{"type":"string"},"units_per_carton":{"type":"integer","description":"How many units fill one carton.","nullable":true},"carton_package_type_id":{"type":"string","description":"The carton this variant is packed into: a package type of kind `carton`. Its dimensions are shared by every product packed the same way, so a corrected carton size fixes all of them at once.","nullable":true},"carton_weight":{"type":"number","description":"What one packed carton weighs, in the variant's weight unit.","nullable":true},"cartons_per_pallet":{"type":"integer","description":"How many cartons stack on one pallet.","nullable":true},"seller_id":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"track_inventory":{"type":"boolean"},"preorderable":{"type":"boolean","description":"Sell this variant before it's in stock. Adds the pre-order label and ships-by promise; the cap comes from `backorder_limit`, an incoming stock count, or backorder."},"preorder_ships_at":{"type":"string","format":"date-time","description":"The \"ships by\" date shown to customers while the variant is a pre-order. Once it passes, the variant is no longer a pre-order. Null clears it.","nullable":true},"backorder_limit":{"type":"integer","description":"Maximum units sellable beyond available stock, capping backorders and pre-orders. Null is unlimited.","nullable":true},"tax_category_id":{"type":"string"},"position":{"type":"integer"},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Per-currency prices. Upserted by currency."},"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevelParams"},"description":"Stock per location. Upserted by location; omitted locations are removed."},"options":{"type":"array","items":{"$ref":"#/components/schemas/VariantOptionParams"},"description":"One pair per option type the variant takes part in (size, color). Option types and values are created when missing. On update, omit to leave the option values untouched."}},"required":["options"]},"VariantOptionParams":{"type":"object","properties":{"name":{"type":"string"},"value":{"type":"string"}},"required":["name","value"]},"VariantUpdateParams":{"type":"object","properties":{"external_references":{"type":"object","additionalProperties":true,"description":"Identities the record has in external systems, keyed by system: the same `{ system: external_id }` map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of `{ system, external_id }` entries is accepted too."},"sku":{"type":"string"},"barcode":{"type":"string"},"cost_price":{"type":"string","format":"decimal","pattern":"^-?\\d+(\\.\\d+)?$","nullable":true},"cost_currency":{"$ref":"#/components/schemas/CurrencyCode"},"weight":{"type":"number","nullable":true},"height":{"type":"number","nullable":true},"width":{"type":"number","nullable":true},"depth":{"type":"number","nullable":true},"weight_unit":{"type":"string","enum":["g","kg","lb","oz"]},"dimensions_unit":{"type":"string","enum":["mm","cm","in","ft"]},"hs_code":{"type":"string"},"customs_description":{"type":"string"},"country_of_origin":{"$ref":"#/components/schemas/CountryCode"},"minimum_order_quantity":{"type":"integer","nullable":true},"order_multiple":{"type":"integer","nullable":true},"purchase_unit":{"type":"string"},"units_per_carton":{"type":"integer","description":"How many units fill one carton.","nullable":true},"carton_package_type_id":{"type":"string","description":"The carton this variant is packed into: a package type of kind `carton`. Its dimensions are shared by every product packed the same way, so a corrected carton size fixes all of them at once.","nullable":true},"carton_weight":{"type":"number","description":"What one packed carton weighs, in the variant's weight unit.","nullable":true},"cartons_per_pallet":{"type":"integer","description":"How many cartons stack on one pallet.","nullable":true},"seller_id":{"type":"string"},"delivery_profile_id":{"type":"string","nullable":true},"track_inventory":{"type":"boolean"},"preorderable":{"type":"boolean","description":"Sell this variant before it's in stock. Adds the pre-order label and ships-by promise; the cap comes from `backorder_limit`, an incoming stock count, or backorder."},"preorder_ships_at":{"type":"string","format":"date-time","description":"The \"ships by\" date shown to customers while the variant is a pre-order. Once it passes, the variant is no longer a pre-order. Null clears it.","nullable":true},"backorder_limit":{"type":"integer","description":"Maximum units sellable beyond available stock, capping backorders and pre-orders. Null is unlimited.","nullable":true},"tax_category_id":{"type":"string"},"position":{"type":"integer"},"prices":{"type":"array","items":{"$ref":"#/components/schemas/PriceParams"},"description":"Per-currency prices. Upserted by currency."},"stock_levels":{"type":"array","items":{"$ref":"#/components/schemas/StockLevelParams"},"description":"Stock per location. Upserted by location; omitted locations are removed."},"options":{"type":"array","items":{"$ref":"#/components/schemas/VariantOptionParams"},"description":"One pair per option type the variant takes part in (size, color). Option types and values are created when missing. On update, omit to leave the option values untouched."}}},"WebhookEndpointCreateParams":{"type":"object","properties":{"name":{"type":"string","description":"A label shown in the dashboard list.","nullable":true},"url":{"type":"string","description":"HTTPS destination URL. It cannot resolve to a private IP address outside development."},"active":{"type":"boolean","description":"Defaults to true on create. Prefer the disable and enable endpoints to pause one."},"subscriptions":{"type":"array","items":{"type":"string"},"description":"Event names this endpoint receives. An empty list or `[\"*\"]` subscribes to every event; otherwise list exact names (`order.completed`) or patterns (`order.*`)."}},"required":["url"]},"WebhookEndpointDisableParams":{"type":"object","properties":{"reason":{"type":"string","description":"Shown next to the disabled indicator. Defaults to \"Manually disabled\"."}}},"WebhookEndpointUpdateParams":{"type":"object","properties":{"name":{"type":"string","description":"A label shown in the dashboard list.","nullable":true},"url":{"type":"string","description":"HTTPS destination URL. It cannot resolve to a private IP address outside development."},"active":{"type":"boolean","description":"Defaults to true on create. Prefer the disable and enable endpoints to pause one."},"subscriptions":{"type":"array","items":{"type":"string"},"description":"Event names this endpoint receives. An empty list or `[\"*\"]` subscribes to every event; otherwise list exact names (`order.completed`) or patterns (`order.*`)."}}}}}}\ No newline at end of filediff --git a/packages/dashboard-core/src/api-client.ts b/packages/dashboard-core/src/api-client.tsindex 537673e186..2cb433a0b8 100644--- a/packages/dashboard-core/src/api-client.ts+++ b/packages/dashboard-core/src/api-client.ts@@ -14,7 +14,7 @@* promise the seller panel methods its API does not have.*/-import type { PermissionRule, UploadFileOptions } from '@spree/admin-sdk'+import type { CountryCode, PermissionRule, UploadFileOptions } from '@spree/admin-sdk'/** What a panel may change on the signed-in person's own account. */export interface PanelAccountParams {@@ -572,7 +572,7 @@ export interface PanelStockLocation {zipcode?: string | nullphone?: string | nullcompany?: string | null- country_code?: string | null+ country_code?: CountryCode | nullstate_code?: string | nullstate_name?: string | null/** Rendered read-only in the table; either panel's serializer derives it. */@@ -614,7 +614,7 @@ export type PanelStockLocationCreateParams = PanelStockLocationParams & { name:* install.*/export interface PanelCountry {- iso: string+ iso: CountryCodeiso3: stringname: stringstates_required?: booleandiff --git a/packages/dashboard-core/src/components/address-form-dialog.test.ts b/packages/dashboard-core/src/components/address-form-dialog.test.tsindex be0484327b..68ddd00a3d 100644--- a/packages/dashboard-core/src/components/address-form-dialog.test.ts+++ b/packages/dashboard-core/src/components/address-form-dialog.test.ts@@ -17,9 +17,9 @@ describe('resolveAddressCountryCode', () => {expect(resolveAddressCountryCode({ country_code: null }, 'FR')).toBe('FR')})- it('stays empty when neither the address nor the store has a country', () => {- expect(resolveAddressCountryCode(null, null)).toBe('')- expect(resolveAddressCountryCode(undefined, undefined)).toBe('')- expect(resolveAddressCountryCode({ country_code: '' }, '')).toBe('')+ it('stays unset when neither the address nor the store has a country', () => {+ expect(resolveAddressCountryCode(null, null)).toBeUndefined()+ expect(resolveAddressCountryCode(undefined, undefined)).toBeUndefined()+ expect(resolveAddressCountryCode({ country_code: '' }, '')).toBeUndefined()})})diff --git a/packages/dashboard-core/src/components/address-form-dialog.tsx b/packages/dashboard-core/src/components/address-form-dialog.tsxindex 9b60208be1..6386f2a6b6 100644--- a/packages/dashboard-core/src/components/address-form-dialog.tsx+++ b/packages/dashboard-core/src/components/address-form-dialog.tsx@@ -1,4 +1,5 @@import { zodResolver } from '@hookform/resolvers/zod'+import type { CountryCode } from '@spree/admin-sdk'import {Button,Checkbox,@@ -17,10 +18,11 @@ import {SheetTitle,} from '@spree/dashboard-ui'import { useEffect, useRef } from 'react'-import { Controller, useForm } from 'react-hook-form'+import { Controller, type DefaultValues, useForm } from 'react-hook-form'import { useTranslation } from 'react-i18next'import { z } from 'zod/v4'import { mapSpreeErrorsToForm } from '../lib/form-errors'+import { countryCodeSchema, isCountryCode } from '../lib/iso-codes'import { useOptionalStore } from '../providers/store-provider'import { CountryCombobox } from './country-combobox'import { StateCombobox, useCountryStates } from './country-state-fields'@@ -33,7 +35,7 @@ export interface AddressParams {address2: stringcity: stringpostal_code: string- country_code: string+ country_code: CountryCodestate_code: stringphone: stringlabel?: string@@ -55,10 +57,7 @@ const addressFormFields = {.string().trim().min(1, { error: requiredMessage('address.postal_code') }),- country_code: z- .string()- .trim()- .min(1, { error: requiredMessage('country_code') }),+ country_code: countryCodeSchema,state_code: z.string(),phone: z.string(),label: z.string(),@@ -139,14 +138,15 @@ export interface EditableAddress {export function resolveAddressCountryCode(address: EditableAddress | null | undefined,storeDefaultCountryCode?: string | null,-): string {- return address?.country_code || storeDefaultCountryCode || ''+): CountryCode | undefined {+ const countryCode = address?.country_code || storeDefaultCountryCode+ return isCountryCode(countryCode) ? countryCode : undefined}function buildDefaults(address: EditableAddress | null | undefined,storeDefaultCountryCode?: string | null,-): AddressFormValues {+): DefaultValues<AddressFormValues> {return {first_name: address?.first_name ?? '',last_name: address?.last_name ?? '',@@ -228,7 +228,7 @@ export function AddressFormDialog({// picked a different country is not overwritten.useEffect(() => {if (address?.country_code) return- if (!storeDefaultCountryCode) return+ if (!isCountryCode(storeDefaultCountryCode)) returnif (form.getValues('country_code')) returnform.setValue('country_code', storeDefaultCountryCode)}, [address?.country_code, storeDefaultCountryCode, form])diff --git a/packages/dashboard-core/src/components/country-combobox.tsx b/packages/dashboard-core/src/components/country-combobox.tsxindex d794ef0cc4..3528f43892 100644--- a/packages/dashboard-core/src/components/country-combobox.tsx+++ b/packages/dashboard-core/src/components/country-combobox.tsx@@ -1,3 +1,4 @@+import type { CountryCode } from '@spree/admin-sdk'import {Combobox,ComboboxButtonTrigger,@@ -18,8 +19,9 @@ import { useCallback, useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useCountries } from '../hooks/use-countries'import { useDisplayName } from '../hooks/use-display-name'+import { isCountryCode } from '../lib/iso-codes'-export type CountryOption = { iso: string; iso3: string; name: string }+export type CountryOption = { iso: CountryCode; iso3: string; name: string }/*** Resolves a country's display name in the admin UI language (keyed on the@@ -118,7 +120,8 @@ export function CountryCombobox({/** Forwarded to the trigger so a `<FieldLabel htmlFor>` can target it. */id?: stringvalue: string | null | undefined- onValueChange: (iso: string) => void+ /** Fires with the picked code, or `''` when the selection is cleared. */+ onValueChange: (iso: CountryCode | '') => void/** Forwarded to the trigger so RHF's `<Controller>` can track touched state. */onBlur?: () => void/** Trigger text while nothing is selected. */@@ -204,9 +207,9 @@ export function CountryMultiCombobox({disabled = false,}: {/** Selected 2-letter ISO codes. */- value: string[]+ value: readonly string[]/** Fires with the next array of ISO codes. */- onValueChange: (isos: string[]) => void+ onValueChange: (isos: CountryCode[]) => voidplaceholder?: stringemptyText?: stringdisabled?: boolean@@ -222,7 +225,10 @@ export function CountryMultiCombobox({// strings. Selected ISOs not yet present in `items` (list still loading)// fall back to a stub so chips don't vanish on first render.const selected = useMemo<CountryOption[]>(- () => value.map((iso) => items.find((c) => c.iso === iso) ?? { iso, iso3: '', name: iso }),+ () =>+ value+ .filter(isCountryCode)+ .map((iso) => items.find((c) => c.iso === iso) ?? { iso, iso3: '', name: iso }),[value, items],)diff --git a/packages/dashboard-core/src/components/currency-select.tsx b/packages/dashboard-core/src/components/currency-select.tsxindex ad693dd03e..a72c25d68e 100644--- a/packages/dashboard-core/src/components/currency-select.tsx+++ b/packages/dashboard-core/src/components/currency-select.tsx@@ -1,3 +1,4 @@+import type { CurrencyCode } from '@spree/admin-sdk'import {Combobox,ComboboxButtonTrigger,@@ -11,6 +12,7 @@ import {import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { useDisplayName } from '../hooks/use-display-name'+import { isCurrencyCode } from '../lib/iso-codes'import { useOptionalStore } from '../providers/store-provider'export { ALL_CURRENCY_CODES } from '../lib/currencies'@@ -29,14 +31,14 @@ interface CurrencySelectProps {/** Controlled value. Pair with `onChange` to lift state out. */value?: string/** Fires on every selection change. */- onChange?: (currency: string) => void+ onChange?: (currency: CurrencyCode) => void/*** Currency codes to pick from. Defaults to the current store's* `supported_currencies`. Pass `ALL_CURRENCY_CODES` (or any custom list) for* contexts where the merchant chooses a currency the store doesn't yet* support — e.g. a market's currency.*/- options?: string[]+ options?: readonly CurrencyCode[]/*** Announces the field as required to assistive technology (`aria-required`).* It does not enforce anything: the trigger is a button, so there is no@@ -106,10 +108,10 @@ export function CurrencySelect({// falls back to the store's currencies rather than an empty picker.const items = useMemo(() => {const base = options?.length ? options : currencies- return value && !base.includes(value) ? [value, ...base] : base+ return isCurrencyCode(value) && !base.includes(value) ? [value, ...base] : base}, [options, currencies, value])- const handleChange = (next: string) => {+ const handleChange = (next: CurrencyCode) => {if (!isControlled) setInternalValue(next)onChange?.(next)}@@ -122,7 +124,7 @@ export function CurrencySelect({// Case-insensitive match against the code and its localized name so typing// "EUR" or "Euro" both find it.- const filter = (code: string, query: string) => {+ const filter = (code: CurrencyCode, query: string) => {const q = query.trim().toLowerCase()if (!q) return truereturn code.toLowerCase().includes(q) || renderOption(code).toLowerCase().includes(q)@@ -137,10 +139,14 @@ export function CurrencySelect({{hiddenInput}<Comboboxitems={items}- value={value}- onValueChange={(next: string | null) => handleChange(next ?? '')}- itemToStringLabel={(code: string | null) => (code ? renderOption(code) : '')}- itemToStringValue={(code: string | null) => code ?? ''}+ value={isCurrencyCode(value) ? value : null}+ // Nothing on the picker clears it, so a null selection is not a choice+ // to report.+ onValueChange={(next: CurrencyCode | null) => {+ if (next) handleChange(next)+ }}+ itemToStringLabel={(code: CurrencyCode | null) => (code ? renderOption(code) : '')}+ itemToStringValue={(code: CurrencyCode | null) => code ?? ''}filter={filter}disabled={disabled}>@@ -169,7 +175,7 @@ export function CurrencySelect({/><ComboboxEmpty>{t('admin.components.currency_select.empty')}</ComboboxEmpty><ComboboxList>- {(code: string) => (+ {(code: CurrencyCode) => (<ComboboxItem key={code} value={code}>{renderOption(code)}</ComboboxItem>diff --git a/packages/dashboard-core/src/components/preferences-form.tsx b/packages/dashboard-core/src/components/preferences-form.tsxindex 216e814ad1..511ca44e7e 100644--- a/packages/dashboard-core/src/components/preferences-form.tsx+++ b/packages/dashboard-core/src/components/preferences-form.tsx@@ -1,3 +1,4 @@+import type { CurrencyCode } from '@spree/admin-sdk'import {compareMoney,isDecimalString,@@ -152,7 +153,7 @@ interface PreferencesFormProps {* would let a currency the store does not trade in be saved, and a* calculator set to one quotes no rate at all.*/- currencyOptions?: string[]+ currencyOptions?: readonly CurrencyCode[]/*** Render date/datetime pickers inline instead of in a Popover portal.* Set this when the form is inside a `<Sheet>` — Base UI's Popover fails@@ -215,7 +216,7 @@ interface PreferenceFieldProps {label?: stringonChange: (value: unknown) => voidredactPasswords?: boolean- currencyOptions?: string[]+ currencyOptions?: readonly CurrencyCode[]inlineDatePickers?: boolean/** The currency a money preference is in, when the record names one. */currency?: stringdiff --git a/packages/dashboard-core/src/index.ts b/packages/dashboard-core/src/index.tsindex c4508cc7ef..df362dd7db 100644--- a/packages/dashboard-core/src/index.ts+++ b/packages/dashboard-core/src/index.ts@@ -101,6 +101,7 @@ export * from './lib/fulfillment-items'// `i18n.addResourceBundle`) get it via the named re-export.export * from './lib/i18n'export * from './lib/import-types'+export * from './lib/iso-codes'export * from './lib/label-upload-form'export * from './lib/money'export * from './lib/nav-registry'diff --git a/packages/dashboard-core/src/lib/currencies.ts b/packages/dashboard-core/src/lib/currencies.tsindex 8f999cff94..ce24f82775 100644--- a/packages/dashboard-core/src/lib/currencies.ts+++ b/packages/dashboard-core/src/lib/currencies.ts@@ -1,3 +1,6 @@+import type { CurrencyCode } from '@spree/admin-sdk'+import { isCurrencyCode } from './iso-codes'+/*** Every ISO 4217 currency code the runtime knows about — the active-currency* counterpart to the Rails admin's `Money::Currency.table` list. Used for@@ -6,9 +9,9 @@* runtimes without `Intl.supportedValuesOf`, so callers fall back to* `supported_currencies`.*/-export const ALL_CURRENCY_CODES: string[] = (() => {+export const ALL_CURRENCY_CODES: CurrencyCode[] = (() => {try {- return Intl.supportedValuesOf('currency')+ return Intl.supportedValuesOf('currency').filter(isCurrencyCode)} catch {return []}diff --git a/packages/dashboard-core/src/lib/form-mappers.ts b/packages/dashboard-core/src/lib/form-mappers.tsindex 8b6ff0658c..0968ba37df 100644--- a/packages/dashboard-core/src/lib/form-mappers.ts+++ b/packages/dashboard-core/src/lib/form-mappers.ts@@ -1,3 +1,4 @@+import type { CountryCode } from '@spree/admin-sdk'import type { PanelAccountParams } from '../api-client'/**@@ -91,7 +92,7 @@ export function editableAddressToStockLocationParams(values: {address2?: string | nullcity?: string | nullpostal_code?: string | null- country_code?: string | null+ country_code?: CountryCode | nullstate_code?: string | nullphone?: string | null}) {diff --git a/packages/dashboard-core/src/lib/iso-codes.ts b/packages/dashboard-core/src/lib/iso-codes.tsnew file mode 100644index 0000000000..274bee49c5--- /dev/null+++ b/packages/dashboard-core/src/lib/iso-codes.ts@@ -0,0 +1,32 @@+import type { CountryCode, CurrencyCode } from '@spree/admin-sdk'+import i18n from 'i18next'+import { z } from 'zod/v4'++/**+ * Whether a value has the shape of an ISO 3166-1 alpha-2 country code.+ *+ * Shape only: the server holds the authoritative list and rejects a code it+ * does not know, so the dashboard does not ship a second copy of it. This is+ * the one place a plain string becomes a `CountryCode`.+ */+export function isCountryCode(value: unknown): value is CountryCode {+ return typeof value === 'string' && /^[A-Z]{2}$/.test(value)+}++/** Whether a value has the shape of an ISO 4217 currency code. See `isCountryCode`. */+export function isCurrencyCode(value: unknown): value is CurrencyCode {+ return typeof value === 'string' && /^[A-Z]{3}$/.test(value)+}++/**+ * A required country field. A form that allows leaving it blank widens it+ * with `.or(z.literal(''))` and sends `value || null` (or `|| undefined`).+ */+export const countryCodeSchema = z.custom<CountryCode>(isCountryCode, {+ error: () => i18n.t('admin.validation.country_required'),+})++/** A required currency field. See `countryCodeSchema`. */+export const currencyCodeSchema = z.custom<CurrencyCode>(isCurrencyCode, {+ error: () => i18n.t('admin.validation.currency_required'),+})diff --git a/packages/dashboard-core/src/products/product-bulk-price-editor.tsx b/packages/dashboard-core/src/products/product-bulk-price-editor.tsxindex cedaaf5329..32dbe3bc17 100644--- a/packages/dashboard-core/src/products/product-bulk-price-editor.tsx+++ b/packages/dashboard-core/src/products/product-bulk-price-editor.tsx@@ -1,3 +1,4 @@+import type { CurrencyCode } from '@spree/admin-sdk'import type { ProductFormValues, VariantPriceFormValues } from '@spree/dashboard-core'import { type BulkPriceRow, BulkPriceTable } from '@spree/dashboard-ui'import { useCallback, useMemo } from 'react'@@ -13,7 +14,7 @@ interface Props {// eslint-disable-next-line @typescript-eslint/no-explicit-anyform: UseFormReturn<ProductFormValues, any, any>/** ISO currency code (e.g. "USD", "EUR"). */- currency: string+ currency: CurrencyCode/** Display label for the product, used as the table's section header. */productName: string}diff --git a/packages/dashboard-core/src/products/product-form-cards.tsx b/packages/dashboard-core/src/products/product-form-cards.tsxindex f8f7109c82..d1c5041b06 100644--- a/packages/dashboard-core/src/products/product-form-cards.tsx+++ b/packages/dashboard-core/src/products/product-form-cards.tsx@@ -13,6 +13,7 @@ import {useSortable,} from '@dnd-kit/sortable'import { CSS } from '@dnd-kit/utilities'+import type { CurrencyCode } from '@spree/admin-sdk'import type { MediaType, ProductFormValues } from '@spree/dashboard-core'import {getApiClient,@@ -198,8 +199,8 @@ export function PricesCard({* StoreProvider; a seller's tenant is a seller and the store is derived* server-side, so it passes the currencies its profile reports.*/- currencies?: string[]- defaultCurrency?: string+ currencies?: CurrencyCode[]+ defaultCurrency?: CurrencyCode}) {const { t } = useTranslation()const store = useOptionalStore()@@ -208,7 +209,7 @@ export function PricesCard({// Not `useState(defaultCurrency)` alone: the store (or the seller's profile)// arrives after the first render, so a state seeded from the fallback would// stick and price everything in the wrong currency.- const [selectedCurrency, setCurrency] = useState<string | null>(null)+ const [selectedCurrency, setCurrency] = useState<CurrencyCode | null>(null)const currency = selectedCurrency ?? defaultCurrency// Until the real default arrives there is no currency to price in, and an@@ -224,7 +225,10 @@ export function PricesCard({{t('admin.common.prices')}</CardTitle>{currencies.length > 1 && (- <Select value={currency} onValueChange={setCurrency}>+ <Select+ value={currency}+ onValueChange={(next) => setCurrency(currencies.find((code) => code === next) ?? null)}+ ><SelectTrigger size="sm" className="w-24"><SelectValue /></SelectTrigger>diff --git a/packages/dashboard-core/src/products/product-form-mapping.ts b/packages/dashboard-core/src/products/product-form-mapping.tsindex 8f9ed88418..3dc4349718 100644--- a/packages/dashboard-core/src/products/product-form-mapping.ts+++ b/packages/dashboard-core/src/products/product-form-mapping.ts@@ -46,16 +46,21 @@ export function variantToFormValues(variant: PanelVariant, position: number): Vatax_category_id: variant.tax_category_id ?? null,// Base prices only: this array is posted back as the variant's base// prices, so a price-list row taken in here returns as the shop price.- prices: (variant.prices ?? [])- .filter((p) => p.currency != null && p.price_list_id == null)- .map((p) => ({- currency: p.currency as string,- // Keep amounts as the canonical decimal strings the API returns; the- // price editor shows them in the admin's number format and normalizes- // edits back before they reach the form.- amount: p.amount != null ? String(p.amount) : '',- compare_at_amount: p.compare_at_amount != null ? String(p.compare_at_amount) : null,- })),+ prices: (variant.prices ?? []).flatMap(+ ({ currency, price_list_id, amount, compare_at_amount }) =>+ currency != null && price_list_id == null+ ? [+ {+ currency,+ // Keep amounts as the canonical decimal strings the API returns;+ // the price editor shows them in the admin's number format and+ // normalizes edits back before they reach the form.+ amount: amount != null ? String(amount) : '',+ compare_at_amount: compare_at_amount != null ? String(compare_at_amount) : null,+ },+ ]+ : [],+ ),stock_levels: (variant.stock_levels ?? []).map((si) => ({id: si.id,stock_location_id: si.stock_location_id ?? si.stock_location?.id ?? '',diff --git a/packages/dashboard-core/src/products/product-schema.ts b/packages/dashboard-core/src/products/product-schema.tsindex 284def375e..97755a509f 100644--- a/packages/dashboard-core/src/products/product-schema.ts+++ b/packages/dashboard-core/src/products/product-schema.ts@@ -1,6 +1,7 @@import { requiredMessage } from '@spree/dashboard-ui'import i18n from 'i18next'import { z } from 'zod/v4'+import { countryCodeSchema, currencyCodeSchema } from '../lib/iso-codes'import { normalizeQuantityRule } from './normalize-quantity'import { isSupportedVideoUrl } from './video-url'@@ -36,7 +37,7 @@ export type VariantOptionPair = z.infer<typeof variantOptionPairSchema>// Form-side prices are canonical decimal STRINGS ("1234.56"), never numbers:// `Number(...)` coercion loses precision and turns `"1.234,56"` into `NaN`.export const variantPriceFormSchema = z.object({- currency: z.string(),+ currency: currencyCodeSchema,amount: z.string(),compare_at_amount: z.string().nullable().optional(),})@@ -58,7 +59,7 @@ export const variantFormSchema = z.object({weight_unit: z.string().nullable().optional(),dimensions_unit: z.string().nullable().optional(),hs_code: z.string().nullable().optional(),- country_of_origin: z.string().nullable().optional(),+ country_of_origin: countryCodeSchema.nullable().optional(),customs_description: z.string().nullable().optional(),// Held as strings so an unusable entry can be reported rather than// silently coerced away: normalizing `0` straight to null would clear thediff --git a/packages/dashboard-core/src/products/product-types.ts b/packages/dashboard-core/src/products/product-types.tsindex 8323ba3f75..3a204f9fe7 100644--- a/packages/dashboard-core/src/products/product-types.ts+++ b/packages/dashboard-core/src/products/product-types.ts@@ -1,3 +1,5 @@+import type { CountryCode, CurrencyCode } from '@spree/admin-sdk'+/*** What the shared product form reads off a product, its variants and its* media.@@ -42,12 +44,12 @@ export interface PanelVariant {price?: { amount?: string | null; currency?: string | null } | nullprices?: Array<{amount?: string | null- currency?: string | null+ currency?: CurrencyCode | nullcompare_at_amount?: string | nullprice_list_id?: string | null}>cost_price?: string | null- cost_currency?: string | null+ cost_currency?: CurrencyCode | nullweight?: number | nullheight?: number | nullwidth?: number | null@@ -55,7 +57,7 @@ export interface PanelVariant {weight_unit?: string | nulldimensions_unit?: string | nullhs_code?: string | null- country_of_origin?: string | null+ country_of_origin?: CountryCode | nullcustoms_description?: string | nullminimum_order_quantity?: number | nullorder_multiple?: number | nulldiff --git a/packages/dashboard-core/src/providers/store-provider.tsx b/packages/dashboard-core/src/providers/store-provider.tsxindex 31d6318f11..de10e6f45c 100644--- a/packages/dashboard-core/src/providers/store-provider.tsx+++ b/packages/dashboard-core/src/providers/store-provider.tsx@@ -1,4 +1,4 @@-import type { Store } from '@spree/admin-sdk'+import type { CurrencyCode, Store } from '@spree/admin-sdk'import { useQuery } from '@tanstack/react-query'import { createContext, type ReactNode, useContext, useEffect, useRef } from 'react'import { adminClient } from '../client'@@ -19,14 +19,14 @@ interface StoreContextValue {store: Store | nullstoreId: stringisLoading: boolean- currencies: string[]+ currencies: CurrencyCode[]/** Locales this store is configured to translate content into. */locales: string[]/** Every locale a merchant may translate content into — the full canonical* set, independent of which locales the store currently uses. Drives locale* pickers so a new locale can always be added. */availableLocales: string[]- defaultCurrency: string+ defaultCurrency: CurrencyCodedefaultLocale: string/** ISO country the store sells from — used to pre-fill new address forms. */defaultCountry: stringdiff --git a/packages/dashboard-core/src/schemas/stock-location.ts b/packages/dashboard-core/src/schemas/stock-location.tsindex 02ddd07bed..b0bb282cd4 100644--- a/packages/dashboard-core/src/schemas/stock-location.ts+++ b/packages/dashboard-core/src/schemas/stock-location.ts@@ -2,6 +2,7 @@ import { requiredMessage } from '@spree/dashboard-ui'import { z } from 'zod/v4'import type { PanelStockLocation, PanelStockLocationCreateParams } from '../api-client'import { blankToUndefined, emptyToUndefined } from '../lib/form-mappers'+import { countryCodeSchema } from '../lib/iso-codes'// Labels live in `en.json` under `admin.stock_locations.kinds.*` and// `admin.stock_locations.pickup_stock_policies.*`. Consumers map these@@ -27,7 +28,7 @@ export const stockLocationFormSchema = z.object({zipcode: z.string().optional(),phone: z.string().optional(),company: z.string().optional(),- country_code: z.string().optional(),+ country_code: countryCodeSchema.or(z.literal('')).optional(),state_code: z.string().optional(),state_name: z.string().optional(),pickup_enabled: z.boolean(),@@ -114,7 +115,7 @@ export function formValuesToParams(v: StockLocationFormValues): PanelStockLocatizipcode: blankToUndefined(v.zipcode),phone: blankToUndefined(v.phone),company: blankToUndefined(v.company),- country_code: blankToUndefined(v.country_code),+ country_code: v.country_code || undefined,state_code: blankToUndefined(v.state_code),state_name: blankToUndefined(v.state_name),pickup_enabled: v.pickup_enabled,diff --git a/packages/dashboard/src/components/spree/bulk-price-editor/bulk-price-editor-dialog.tsx b/packages/dashboard/src/components/spree/bulk-price-editor/bulk-price-editor-dialog.tsxindex 0510516aba..2812a81fe9 100644--- a/packages/dashboard/src/components/spree/bulk-price-editor/bulk-price-editor-dialog.tsx+++ b/packages/dashboard/src/components/spree/bulk-price-editor/bulk-price-editor-dialog.tsx@@ -119,8 +119,9 @@ export function BulkPriceEditorDialog({// Currency switch discards pending edits — the working set is per-currency.const handleCurrencyChange = useCallback(- async (next: string) => {- if (next === currency) return+ async (value: string) => {+ const next = currencies.find((code) => code === value)+ if (!next || next === currency) returnif (editorState.dirtyCount > 0) {const ok = await confirm({title: t('admin.pages.products.price_lists.edit_prices.discard_confirm.title'),@@ -135,7 +136,7 @@ export function BulkPriceEditorDialog({}setCurrency(next)},- [currency, editorState, confirm, t],+ [currencies, currency, editorState, confirm, t],)const title = t('admin.pages.products.price_lists.edit_prices.title', { name: priceList.name })diff --git a/packages/dashboard/src/components/spree/bulk-price-editor/bulk-price-editor.tsx b/packages/dashboard/src/components/spree/bulk-price-editor/bulk-price-editor.tsxindex 428471d623..a647ff1747 100644--- a/packages/dashboard/src/components/spree/bulk-price-editor/bulk-price-editor.tsx+++ b/packages/dashboard/src/components/spree/bulk-price-editor/bulk-price-editor.tsx@@ -1,4 +1,4 @@-import type { PriceBulkUpsertRowParams } from '@spree/admin-sdk'+import type { CurrencyCode, PriceBulkUpsertRowParams } from '@spree/admin-sdk'import {adminClient,currencyParts,@@ -99,7 +99,7 @@ function stableFilterKey(filter: FilterShape): string {export interface BulkPriceEditorProps {/** Filter by a specific price list. Omit to edit base prices. */priceListId?: string- currency: string+ currency: CurrencyCode/** Extra Ransack predicates spread into the index call — e.g.* `{ variant_product_id_eq: 'prod_xxx' }` for a per-product editor.* Keys starting with `price_list_id` are stripped (the editor ownsdiff --git a/packages/dashboard/src/components/spree/catalog-terms-card.tsx b/packages/dashboard/src/components/spree/catalog-terms-card.tsxindex 385aa67d79..2f084dc28b 100644--- a/packages/dashboard/src/components/spree/catalog-terms-card.tsx+++ b/packages/dashboard/src/components/spree/catalog-terms-card.tsx@@ -156,10 +156,9 @@ function OrderMinimums({}const usedCurrencies = rows.map((row) => row.currency)- const nextCurrency =- [store?.default_currency, ...(store?.supported_currencies ?? [])]- .filter((code): code is string => !!code)- .find((code) => !usedCurrencies.includes(code)) ?? ''+ const nextCurrency = [store?.default_currency, ...(store?.supported_currencies ?? [])]+ .filter((code) => code !== undefined)+ .find((code) => !usedCurrencies.includes(code))return (<section className="flex flex-col gap-3">@@ -183,7 +182,9 @@ function OrderMinimums({size="sm"className="shrink-0"disabled={!nextCurrency}- onClick={() => update([...rows, { currency: nextCurrency, amount: '' }])}+ onClick={() =>+ nextCurrency && update([...rows, { currency: nextCurrency, amount: '' }])+ }><PlusIcon className="size-4" />{t('admin.actions.add')}diff --git a/packages/dashboard/src/components/spree/orders/fulfillment-label-upload-dialog.tsx b/packages/dashboard/src/components/spree/orders/fulfillment-label-upload-dialog.tsxindex 03aa5796ee..d799792968 100644--- a/packages/dashboard/src/components/spree/orders/fulfillment-label-upload-dialog.tsx+++ b/packages/dashboard/src/components/spree/orders/fulfillment-label-upload-dialog.tsx@@ -1,4 +1,5 @@import { zodResolver } from '@hookform/resolvers/zod'+import type { CurrencyCode } from '@spree/admin-sdk'import {EMPTY_FILE_UPLOAD_VALUE,FileUploadField,@@ -25,7 +26,7 @@ export function FulfillmentLabelUploadDialog({}: {orderId: stringfulfillmentId: string- currency?: string+ currency?: CurrencyCodeopen: booleanonOpenChange: (open: boolean) => void}) {diff --git a/packages/dashboard/src/components/spree/purchase-order-form.tsx b/packages/dashboard/src/components/spree/purchase-order-form.tsxindex 3d680d1859..c84b5b3953 100644--- a/packages/dashboard/src/components/spree/purchase-order-form.tsx+++ b/packages/dashboard/src/components/spree/purchase-order-form.tsx@@ -1,4 +1,4 @@-import type { Supplier } from '@spree/admin-sdk'+import type { CurrencyCode, Supplier } from '@spree/admin-sdk'import { isDecimalString } from '@spree/admin-sdk'import {CurrencySelect,@@ -36,7 +36,7 @@ import { type VariantLine, VariantLineEditor } from './variant-line-editor'export interface PurchaseOrderFormValues {supplierId: stringdestinationId: string- currency?: string+ currency?: CurrencyCodeexpectedAt?: stringcancelBy?: stringreference: string@@ -97,7 +97,7 @@ export function PurchaseOrderForm({const [supplierId, setSupplierId] = useState(initial.supplierId)const [destinationId, setDestinationId] = useState(initial.destinationId)- const [currency, setCurrency] = useState<string | undefined>(initial.currency)+ const [currency, setCurrency] = useState<CurrencyCode | undefined>(initial.currency)const [expectedAt, setExpectedAt] = useState<string | undefined>(initial.expectedAt)const [cancelBy, setCancelBy] = useState<string | undefined>(initial.cancelBy)const [reference, setReference] = useState(initial.reference)diff --git a/packages/dashboard/src/components/spree/shipping/delivery-method-form.tsx b/packages/dashboard/src/components/spree/shipping/delivery-method-form.tsxindex 2bb9420149..c509f94ad3 100644--- a/packages/dashboard/src/components/spree/shipping/delivery-method-form.tsx+++ b/packages/dashboard/src/components/spree/shipping/delivery-method-form.tsx@@ -13,6 +13,7 @@ import {currencyParts,defaultPreferences,filterPreferenceSchema,+ isCurrencyCode,PreferencesForm,ResourceMultiAutocomplete,Subject,@@ -962,7 +963,10 @@ function CurrencyAmountsField({const extraCodes = Object.keys(amounts).join(',')const codes = useMemo(() => {const supported = currencies.length > 0 ? currencies : [defaultCurrency]- const extra = extraCodes.split(',').filter((code) => code && !supported.includes(code))+ const extra = extraCodes+ .split(',')+ .filter(isCurrencyCode)+ .filter((code) => !supported.includes(code))return [defaultCurrency, ...supported.filter((code) => code !== defaultCurrency), ...extra]}, [currencies, defaultCurrency, extraCodes])diff --git a/packages/dashboard/src/components/spree/shipping/delivery-zone-region-picker.tsx b/packages/dashboard/src/components/spree/shipping/delivery-zone-region-picker.tsxindex 0cd0f122bc..7cdb88ec2f 100644--- a/packages/dashboard/src/components/spree/shipping/delivery-zone-region-picker.tsx+++ b/packages/dashboard/src/components/spree/shipping/delivery-zone-region-picker.tsx@@ -1,4 +1,4 @@-import type { DeliveryZone } from '@spree/admin-sdk'+import type { CountryCode, DeliveryZone } from '@spree/admin-sdk'import { useStore } from '@spree/dashboard-core'import {Button,@@ -58,7 +58,7 @@ export function DeliveryZoneRegionPicker({const claimed = useMemo(() => claimedByOtherZones(siblingZones), [siblingZones])const rows = useMemo<CountryRow[]>(() => {- const byIso = new Map<string, CountryRow>()+ const byIso = new Map<CountryCode, CountryRow>()for (const country of marketCountries) {byIso.set(country.iso, {@@ -98,7 +98,7 @@ export function DeliveryZoneRegionPicker({onChange(writeSelection({ ...selection, ...next }))}- function toggleCountry(iso: string, checked: boolean) {+ function toggleCountry(iso: CountryCode, checked: boolean) {if (checked) {apply(supersedeCountry(selection, iso))return@@ -114,7 +114,7 @@ export function DeliveryZoneRegionPicker({* of a wholly-selected country: that country member has to become an* explicit member per remaining state before one can be dropped.*/- function toggleState(iso: string, abbr: string, checked: boolean, allAbbrs: string[]) {+ function toggleState(iso: CountryCode, abbr: string, checked: boolean, allAbbrs: string[]) {const countries = new Set(selection.countries)const states = new Map(selection.states)const wholeCountry = countries.has(iso)@@ -414,7 +414,11 @@ function PostalRulesSection({<Selectitems={countryOptions}value={rule.country_code ?? ''}- onValueChange={(next) => update(index, { country_code: next as string })}+ onValueChange={(next) =>+ update(index, {+ country_code: countryOptions.find((option) => option.value === next)?.value,+ })+ }><SelectTrigger className="flex-1"><SelectValue>diff --git a/packages/dashboard/src/components/spree/shipping/delivery-zone-selection.ts b/packages/dashboard/src/components/spree/shipping/delivery-zone-selection.tsindex cf38b7b8dd..255664eff8 100644--- a/packages/dashboard/src/components/spree/shipping/delivery-zone-selection.ts+++ b/packages/dashboard/src/components/spree/shipping/delivery-zone-selection.ts@@ -1,4 +1,4 @@-import type { DeliveryZone } from '@spree/admin-sdk'+import type { CountryCode, DeliveryZone } from '@spree/admin-sdk'import type { DeliveryZoneMemberValues } from '../../../schemas/delivery-zone'/**@@ -7,7 +7,7 @@ import type { DeliveryZoneMemberValues } from '../../../schemas/delivery-zone'* older member is never silently dropped on the next save.*/export interface CountryRow {- iso: string+ iso: CountryCodename: stringstatesRequired: boolean/** The zone kept this country but no market covers it any more. */@@ -19,15 +19,15 @@ export interface CountryRow {/** What the member list means, expressed the way the picker manipulates it. */export interface Selection {/** ISOs selected as a whole country. */- countries: Set<string>+ countries: Set<CountryCode>/** ISO → selected state abbreviations, for partially selected countries. */- states: Map<string, Set<string>>+ states: Map<CountryCode, Set<string>>postalRules: DeliveryZoneMemberValues[]}export function readSelection(members: DeliveryZoneMemberValues[]): Selection {- const countries = new Set<string>()- const states = new Map<string, Set<string>>()+ const countries = new Set<CountryCode>()+ const states = new Map<CountryCode, Set<string>>()const postalRules: DeliveryZoneMemberValues[] = []for (const member of members) {@@ -74,7 +74,7 @@ export function writeSelection(selection: Selection): DeliveryZoneMemberValues[]* country already matches every address a narrower member could — leaving* those behind would persist config that can never change an outcome.*/-export function supersedeCountry(selection: Selection, iso: string): Selection {+export function supersedeCountry(selection: Selection, iso: CountryCode): Selection {const countries = new Set(selection.countries)const states = new Map(selection.states)@@ -89,8 +89,8 @@ export function supersedeCountry(selection: Selection, iso: string): Selection {}export function claimedByOtherZones(siblingZones: DeliveryZone[]) {- const countries = new Set<string>()- const states = new Map<string, Set<string>>()+ const countries = new Set<CountryCode>()+ const states = new Map<CountryCode, Set<string>>()for (const zone of siblingZones) {for (const member of zone.members ?? []) {diff --git a/packages/dashboard/src/routes/_authenticated/$storeId/loyalty/gift-cards.tsx b/packages/dashboard/src/routes/_authenticated/$storeId/loyalty/gift-cards.tsxindex 07ccac350d..74d97c382b 100644--- a/packages/dashboard/src/routes/_authenticated/$storeId/loyalty/gift-cards.tsx+++ b/packages/dashboard/src/routes/_authenticated/$storeId/loyalty/gift-cards.tsx@@ -278,7 +278,6 @@ function EditGiftCardSheet({code: '',// `amount` is a STRING — hydrated from the API's canonical decimal.amount: '',- currency: '',expires_at: '',customer_id: '',},diff --git a/packages/dashboard/src/routes/_authenticated/$storeId/settings/markets.tsx b/packages/dashboard/src/routes/_authenticated/$storeId/settings/markets.tsxindex ba1b84c5ea..3cf8f649ed 100644--- a/packages/dashboard/src/routes/_authenticated/$storeId/settings/markets.tsx+++ b/packages/dashboard/src/routes/_authenticated/$storeId/settings/markets.tsx@@ -36,7 +36,7 @@ import { PlusIcon } from '@spree/dashboard-ui/icons'import { useQueryClient } from '@tanstack/react-query'import { createFileRoute, useNavigate } from '@tanstack/react-router'import { useEffect, useMemo } from 'react'-import { Controller, type UseFormReturn, useForm } from 'react-hook-form'+import { Controller, type DefaultValues, type UseFormReturn, useForm } from 'react-hook-form'import { useTranslation } from 'react-i18next'import { z } from 'zod/v4'import { TaxProviderField } from '../../../../components/spree/tax-provider-field'@@ -159,7 +159,7 @@ function CreateMarketSheet({// Seed the form with the store defaults so a typical "Europe" / "ROW"// setup is mostly pre-filled — the merchant only edits name + countries.- const initialDefaults: MarketFormValues = useMemo(+ const initialDefaults: DefaultValues<MarketFormValues> = useMemo(() => ({...MARKET_DEFAULTS,currency: defaultCurrency,diff --git a/packages/dashboard/src/routes/setup.tsx b/packages/dashboard/src/routes/setup.tsxindex 3804bc765e..3b39f1fc6f 100644--- a/packages/dashboard/src/routes/setup.tsx+++ b/packages/dashboard/src/routes/setup.tsx@@ -129,7 +129,6 @@ function SetupForm({password: '',password_confirmation: '',store_name: '',- country_code: '',locale: 'en',currency: 'USD',sample_data: true,diff --git a/packages/dashboard/src/schemas/auth.ts b/packages/dashboard/src/schemas/auth.tsindex c49982e536..9a958e4f5d 100644--- a/packages/dashboard/src/schemas/auth.ts+++ b/packages/dashboard/src/schemas/auth.ts@@ -1,4 +1,4 @@-import { i18n } from '@spree/dashboard-core'+import { countryCodeSchema, currencyCodeSchema, i18n } from '@spree/dashboard-core'import { z } from 'zod/v4'// Lazy message factories — Zod v4 accepts `{ error: () => string }` as an@@ -69,9 +69,9 @@ export const setupFormSchema = zpassword: z.string().min(8, { error: passwordMinLength }),password_confirmation: z.string(),store_name: z.string().min(1, { error: () => i18n.t('admin.validation.store_name_required') }),- country_code: z.string().min(1, { error: () => i18n.t('admin.validation.country_required') }),+ country_code: countryCodeSchema,locale: z.string().min(1),- currency: z.string().min(1, { error: () => i18n.t('admin.validation.currency_required') }),+ currency: currencyCodeSchema,sample_data: z.boolean(),}).refine((data) => data.password === data.password_confirmation, {diff --git a/packages/dashboard/src/schemas/catalog.ts b/packages/dashboard/src/schemas/catalog.tsindex d3e42ed851..4d26f60b82 100644--- a/packages/dashboard/src/schemas/catalog.ts+++ b/packages/dashboard/src/schemas/catalog.ts@@ -1,4 +1,4 @@-import type { CatalogParams, PriceList } from '@spree/admin-sdk'+import type { CatalogParams, CurrencyCode, PriceList } from '@spree/admin-sdk'import { compareMoney, negateMoney } from '@spree/admin-sdk'import {blankToNull,@@ -204,7 +204,7 @@ export type StagedProductTerms = Record<string, ProductTermEntry>*/export interface OrderMinimumEntry {id?: string- currency: string+ currency: CurrencyCodeamount: string}diff --git a/packages/dashboard/src/schemas/company.ts b/packages/dashboard/src/schemas/company.tsindex 13f05b051f..2f70877b95 100644--- a/packages/dashboard/src/schemas/company.ts+++ b/packages/dashboard/src/schemas/company.ts@@ -3,7 +3,7 @@ import type {TaxExemptionCertificateParams,TaxIdentifierParams,} from '@spree/admin-sdk'-import { blankToNull, signedIdParam } from '@spree/dashboard-core'+import { blankToNull, countryCodeSchema, signedIdParam } from '@spree/dashboard-core'import { requiredMessage } from '@spree/dashboard-ui'import { z } from 'zod/v4'@@ -61,7 +61,7 @@ export const TAX_IDENTIFIER_KINDS = ['eu_vat', 'gb_vat', 'ch_vat', 'au_abn', 'usexport const taxExemptionCertificateFormSchema = z.object({certificate_number: z.string().min(1, { error: requiredMessage('certificate_number') }),reason_code: z.string().min(1, { error: requiredMessage('reason_code') }),- country_code: z.string().optional(),+ country_code: countryCodeSchema.or(z.literal('')).optional(),state_code: z.string().optional(),issued_at: z.string().optional(),expires_at: z.string().optional(),@@ -102,7 +102,7 @@ export function taxExemptionCertificateValuesToParams(return {certificate_number: values.certificate_number,reason_code: values.reason_code,- country_code: blankToNull(values.country_code),+ country_code: values.country_code || null,state_code: blankToNull(values.state_code),issued_at: blankToNull(values.issued_at),expires_at: blankToNull(values.expires_at),diff --git a/packages/dashboard/src/schemas/delivery-zone.ts b/packages/dashboard/src/schemas/delivery-zone.tsindex 4539bf9ccb..9d39c6b4f4 100644--- a/packages/dashboard/src/schemas/delivery-zone.ts+++ b/packages/dashboard/src/schemas/delivery-zone.ts@@ -1,10 +1,11 @@+import { countryCodeSchema } from '@spree/dashboard-core'import { z } from 'zod/v4'export const MEMBER_TYPES = ['country', 'state', 'postal_code'] as constexport const deliveryZoneMemberSchema = z.object({member_type: z.enum(MEMBER_TYPES),- country_code: z.string().optional(),+ country_code: countryCodeSchema.or(z.literal('')).optional(),state_code: z.string().optional(),postal_code_prefix: z.string().optional(),postal_code_from: z.string().optional(),diff --git a/packages/dashboard/src/schemas/gift-card.ts b/packages/dashboard/src/schemas/gift-card.tsindex 6173b76fce..b7a85ec4a0 100644--- a/packages/dashboard/src/schemas/gift-card.ts+++ b/packages/dashboard/src/schemas/gift-card.ts@@ -3,7 +3,13 @@ import type {GiftCardCreateParams,GiftCardUpdateParams,} from '@spree/admin-sdk'-import { blankToNull, blankToUndefined, i18n, isPositiveMoney } from '@spree/dashboard-core'+import {+ blankToNull,+ blankToUndefined,+ currencyCodeSchema,+ i18n,+ isPositiveMoney,+} from '@spree/dashboard-core'import { z } from 'zod/v4'// Mirrors `Spree::Config[:gift_card_batch_limit]`. Hardcoded for now; if the@@ -14,8 +20,6 @@ export const BATCH_LIMIT = 50_000// catalog has had a chance to initialize and so locale changes pick up.const amountPositive = () => i18n.t('admin.pages.promotions.gift_cards.validation.amount_positive')const prefixRequired = () => i18n.t('admin.pages.promotions.gift_cards.validation.prefix_required')-const currencyRequired = () =>- i18n.t('admin.pages.promotions.gift_cards.validation.currency_required')// Amounts stay strings, from a number input that always yields a canonical// value ("49.5"), and are sent as typed.@@ -27,7 +31,7 @@ export const giftCardCreateFormSchema = z// When `quantity > 1` it becomes the required batch `prefix`.code: z.string().optional(),amount: positiveAmountString,- currency: z.string().min(1, { error: currencyRequired }),+ currency: currencyCodeSchema,expires_at: z.string().optional(),customer_id: z.string().optional(),quantity: z.coerce.number().int().min(1).max(BATCH_LIMIT),@@ -47,7 +51,7 @@ export type GiftCardCreateFormValues = z.infer<typeof giftCardCreateFormSchema>export const giftCardEditFormSchema = z.object({code: z.string().optional(),amount: positiveAmountString,- currency: z.string().min(1, { error: currencyRequired }),+ currency: currencyCodeSchema,expires_at: z.string().optional(),customer_id: z.string().optional(),})diff --git a/packages/dashboard/src/schemas/market.ts b/packages/dashboard/src/schemas/market.tsindex bdd5ed8d09..51eb64ee7a 100644--- a/packages/dashboard/src/schemas/market.ts+++ b/packages/dashboard/src/schemas/market.ts@@ -1,24 +1,28 @@import type { MarketCreateParams, MarketUpdateParams } from '@spree/admin-sdk'+import { countryCodeSchema, currencyCodeSchema } from '@spree/dashboard-core'import { requiredMessage } from '@spree/dashboard-ui'+import type { DefaultValues } from 'react-hook-form'import { z } from 'zod/v4'export const marketFormSchema = z.object({name: z.string().min(1, { error: requiredMessage('name') }),- currency: z.string().min(1, { error: requiredMessage('market.currency') }),+ currency: currencyCodeSchema,default_locale: z.string().min(1, { error: requiredMessage('market.default_locale') }),supported_locales: z.array(z.string()),tax_inclusive: z.boolean(),default: z.boolean(),- country_codes: z.array(z.string()).min(1, { error: requiredMessage('market.country_codes') }),+ country_codes: z+ .array(countryCodeSchema)+ .min(1, { error: requiredMessage('market.country_codes') }),// Empty means the installation default rather than "no tax".tax_provider: z.string().optional(),})export type MarketFormValues = z.infer<typeof marketFormSchema>-export const MARKET_DEFAULTS: MarketFormValues = {+// No currency: a new market takes the store's, and an edited one its own.+export const MARKET_DEFAULTS: DefaultValues<MarketFormValues> = {name: '',- currency: '',default_locale: '',supported_locales: [],tax_inclusive: false,diff --git a/packages/dashboard/src/schemas/store-credit.ts b/packages/dashboard/src/schemas/store-credit.tsindex 1397c71feb..6094665241 100644--- a/packages/dashboard/src/schemas/store-credit.ts+++ b/packages/dashboard/src/schemas/store-credit.ts@@ -1,4 +1,4 @@-import { i18n } from '@spree/dashboard-core'+import { currencyCodeSchema, i18n } from '@spree/dashboard-core'import { requiredMessage } from '@spree/dashboard-ui'import { z } from 'zod/v4'@@ -25,7 +25,7 @@ const amountField = zexport const issueStoreCreditFormSchema = z.object({customer_id: z.string().min(1, { error: requiredMessage('customer_id') }),amount: amountField,- currency: z.string().min(1, { error: requiredMessage('currency') }),+ currency: currencyCodeSchema,memo: z.string(),})diff --git a/packages/dashboard/src/schemas/tax-rate.ts b/packages/dashboard/src/schemas/tax-rate.tsindex 2af9ce86cf..94a867eb6f 100644--- a/packages/dashboard/src/schemas/tax-rate.ts+++ b/packages/dashboard/src/schemas/tax-rate.ts@@ -1,5 +1,5 @@import { compareMoney, isDecimalString, type TaxRateParams } from '@spree/admin-sdk'-import { blankToNull } from '@spree/dashboard-core'+import { blankToNull, countryCodeSchema } from '@spree/dashboard-core'import { decimalPlacesMessage, requiredMessage } from '@spree/dashboard-ui'import { z } from 'zod/v4'@@ -19,7 +19,7 @@ export const taxRateFormSchema = z.object({// Required: a rate always taxes exactly one category.tax_category_id: z.string().min(1, { error: requiredMessage('tax_rate.tax_category_id') }),// Empty means the rate applies everywhere, so neither field is required.- country_code: z.string().optional(),+ country_code: countryCodeSchema.or(z.literal('')).optional(),state_code: z.string().optional(),included_in_price: z.boolean(),show_rate_in_label: z.boolean(),@@ -47,7 +47,7 @@ export function taxRateValuesToParams(values: TaxRateFormValues): TaxRateParamsname: values.name,rate_percent: values.rate_percent,tax_category_id: values.tax_category_id,- country_code: blankToNull(values.country_code),+ country_code: values.country_code || null,state_code: blankToNull(values.state_code),included_in_price: values.included_in_price,show_rate_in_label: values.show_rate_in_label,diff --git a/packages/sdk-core/src/params-types.ts b/packages/sdk-core/src/params-types.tsindex b1b9b22c2b..96acecea8f 100644--- a/packages/sdk-core/src/params-types.ts+++ b/packages/sdk-core/src/params-types.ts@@ -28,9 +28,14 @@ export interface ParamsSpec {const isRequestSchema = (name: string) => name.endsWith('Params')+// ISO code lists the request schemas reference by name. The response types+// generated beside these files declare the same named types, so a request+// imports them from there rather than repeating them.+const SHARED_CODE_LISTS = new Set(['CountryCode', 'CurrencyCode'])+function refName(ref: string): string {const name = ref.replace('#/components/schemas/', '')- if (!isRequestSchema(name)) {+ if (!isRequestSchema(name) && !SHARED_CODE_LISTS.has(name)) {throw new Error(`A request schema references ${name}, which is not a request schema`)}return name@@ -153,7 +158,10 @@ export function renderParamsTypes(spec: ParamsSpec): Map<string, string> {const schema = schemas[name]const out = [HEADER]const imports = [...references(schema)].filter((reference) => reference !== name).sort()- for (const reference of imports) out.push(`import type { ${reference} } from './${reference}'`)+ for (const reference of imports) {+ const from = SHARED_CODE_LISTS.has(reference) ? '../generated' : `./${reference}`+ out.push(`import type { ${reference} } from '${from}'`)+ }if (imports.length) out.push('')out.push(...docComment(schema.description, ''))out.push(`export type ${name} = ${objectType(schema, '')}`)diff --git a/packages/sdk/src/types/generated/Address.ts b/packages/sdk/src/types/generated/Address.tsindex 10786c0254..9c148d4801 100644--- a/packages/sdk/src/types/generated/Address.ts+++ b/packages/sdk/src/types/generated/Address.ts@@ -1,6 +1,7 @@-// Typelizer digest 74acc83c57bda0444feb047b2b068770+// Typelizer digest 15acc4cfc3359b91e23399b84030ffa6//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'interface Address {id: string;@@ -15,7 +16,7 @@ interface Address {phone: string | null;company: string | null;country_name: string;- country_code: string;+ country_code: CountryCode;state_text: string | null;state_code: string | null;quick_checkout: boolean;diff --git a/packages/sdk/src/types/generated/Cart.ts b/packages/sdk/src/types/generated/Cart.tsindex b94b7476c4..bc0b644449 100644--- a/packages/sdk/src/types/generated/Cart.ts+++ b/packages/sdk/src/types/generated/Cart.ts@@ -1,7 +1,7 @@-// Typelizer digest fba264576de3aae53256157dd6c60202+// Typelizer digest 6a558481eadbd2f3d1569efb61bdae03//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {FreightSummary, AppliedPromotion, Fee, LineItem, Fulfillment, Payment, Address, PaymentMethod, GiftCard, Market} from '@/types'+import type {FreightSummary, AppliedPromotion, Fee, LineItem, Fulfillment, Payment, Address, PaymentMethod, GiftCard, Market, CurrencyCode} from '@/types'interface Cart {id: string;@@ -19,7 +19,7 @@ interface Cart {email: string | null;customer_note: string | null;po_number: string | null;- currency: string;+ currency: CurrencyCode;locale: string | null;total_quantity: number;warnings: Array<{code: string, message: string, line_item_id?: string, variant_id?: string, item_index?: number}>;diff --git a/packages/sdk/src/types/generated/Country.ts b/packages/sdk/src/types/generated/Country.tsindex 42f756a4fb..fce90edd94 100644--- a/packages/sdk/src/types/generated/Country.ts+++ b/packages/sdk/src/types/generated/Country.ts@@ -1,10 +1,10 @@-// Typelizer digest 6e35bb28fc74637d6a28153ea857b182+// Typelizer digest 22cd8a8d7e67bf8a9331d3361c74a773//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Market, State} from '@/types'+import type {Market, State, CountryCode} from '@/types'interface Country {- iso: string;+ iso: CountryCode;iso3: string;name: string;states_required: boolean;diff --git a/packages/sdk/src/types/generated/Currency.ts b/packages/sdk/src/types/generated/Currency.tsindex 0f41222630..f358402396 100644--- a/packages/sdk/src/types/generated/Currency.ts+++ b/packages/sdk/src/types/generated/Currency.ts@@ -1,9 +1,10 @@-// Typelizer digest 192978bfebb834035dc1d1035c54fb18+// Typelizer digest c5ceb18cc58e74b1b8433a553e6f4169//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface Currency {- iso_code: string;+ iso_code: CurrencyCode;name: string;symbol: string;decimal_places: number;diff --git a/packages/sdk/src/types/generated/DeliveryZoneMember.ts b/packages/sdk/src/types/generated/DeliveryZoneMember.tsindex a689c1c9ba..9bb7676293 100644--- a/packages/sdk/src/types/generated/DeliveryZoneMember.ts+++ b/packages/sdk/src/types/generated/DeliveryZoneMember.ts@@ -1,11 +1,12 @@-// Typelizer digest 56619ff44dc207a863384d4174f024d2+// Typelizer digest 9dc33211c5d7e6c2ef2ff2f009d1e892//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'interface DeliveryZoneMember {id: string;member_type: 'country' | 'state' | 'postal_code';- country_code: string | null;+ country_code: CountryCode | null;state_code: string | null;postal_code_prefix: string | null;postal_code_from: string | null;diff --git a/packages/sdk/src/types/generated/Enums.ts b/packages/sdk/src/types/generated/Enums.tsindex b9f4a65f0c..26b584922e 100644--- a/packages/sdk/src/types/generated/Enums.ts+++ b/packages/sdk/src/types/generated/Enums.ts@@ -1,7 +1,9 @@-// Typelizer digest 7990f0d28160ada81fe4ad35dcedf819+// Typelizer digest 916cafe3405c6aeb2ef2db2e82e2247e//// DO NOT MODIFY: This file was automatically generated by Typelizer.export type ClaimStatus = 'open' | 'approved' | 'resolved' | 'denied' | 'canceled' | (string & {});+export type CountryCode = 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO' | 'AR' | 'AS' | 'AT' | 'AU' | 'AW' | 'AZ' | 'BA' | 'BB' | 'BD' | 'BE' | 'BF' | 'BG' | 'BH' | 'BI' | 'BJ' | 'BL' | 'BM' | 'BN' | 'BO' | 'BQ' | 'BR' | 'BS' | 'BT' | 'BW' | 'BY' | 'BZ' | 'CA' | 'CC' | 'CD' | 'CF' | 'CG' | 'CH' | 'CI' | 'CK' | 'CL' | 'CM' | 'CN' | 'CO' | 'CR' | 'CU' | 'CV' | 'CW' | 'CX' | 'CY' | 'CZ' | 'DE' | 'DJ' | 'DK' | 'DM' | 'DO' | 'DZ' | 'EC' | 'EE' | 'EG' | 'ER' | 'ES' | 'ET' | 'FI' | 'FJ' | 'FK' | 'FM' | 'FO' | 'FR' | 'GA' | 'GB' | 'GD' | 'GE' | 'GF' | 'GG' | 'GH' | 'GI' | 'GL' | 'GM' | 'GN' | 'GP' | 'GQ' | 'GR' | 'GT' | 'GU' | 'GW' | 'GY' | 'HK' | 'HN' | 'HR' | 'HT' | 'HU' | 'ID' | 'IE' | 'IL' | 'IM' | 'IN' | 'IQ' | 'IR' | 'IS' | 'IT' | 'JE' | 'JM' | 'JO' | 'JP' | 'KE' | 'KG' | 'KH' | 'KI' | 'KM' | 'KN' | 'KP' | 'KR' | 'KW' | 'KY' | 'KZ' | 'LA' | 'LB' | 'LC' | 'LI' | 'LK' | 'LR' | 'LS' | 'LT' | 'LU' | 'LV' | 'LY' | 'MA' | 'MC' | 'MD' | 'ME' | 'MF' | 'MG' | 'MH' | 'MK' | 'ML' | 'MM' | 'MN' | 'MO' | 'MP' | 'MQ' | 'MR' | 'MS' | 'MT' | 'MU' | 'MV' | 'MW' | 'MX' | 'MY' | 'MZ' | 'NA' | 'NC' | 'NE' | 'NF' | 'NG' | 'NI' | 'NL' | 'NO' | 'NP' | 'NR' | 'NU' | 'NZ' | 'OM' | 'PA' | 'PE' | 'PF' | 'PG' | 'PH' | 'PK' | 'PL' | 'PM' | 'PN' | 'PR' | 'PS' | 'PT' | 'PW' | 'PY' | 'QA' | 'RE' | 'RO' | 'RS' | 'RU' | 'RW' | 'SA' | 'SB' | 'SC' | 'SD' | 'SE' | 'SG' | 'SH' | 'SI' | 'SJ' | 'SK' | 'SL' | 'SM' | 'SN' | 'SO' | 'SR' | 'SS' | 'ST' | 'SV' | 'SX' | 'SY' | 'SZ' | 'TC' | 'TD' | 'TG' | 'TH' | 'TJ' | 'TK' | 'TL' | 'TM' | 'TN' | 'TO' | 'TR' | 'TT' | 'TV' | 'TW' | 'TZ' | 'UA' | 'UG' | 'US' | 'UY' | 'UZ' | 'VA' | 'VC' | 'VE' | 'VG' | 'VI' | 'VN' | 'VU' | 'WF' | 'WS' | 'YE' | 'YT' | 'ZA' | 'ZM' | 'ZW';+export type CurrencyCode = 'AED' | 'AFN' | 'ALL' | 'AMD' | 'ANG' | 'AOA' | 'ARS' | 'AUD' | 'AWG' | 'AZN' | 'BAM' | 'BBD' | 'BDT' | 'BGN' | 'BHD' | 'BIF' | 'BMD' | 'BND' | 'BOB' | 'BRL' | 'BSD' | 'BTN' | 'BWP' | 'BYN' | 'BYR' | 'BZD' | 'CAD' | 'CDF' | 'CHF' | 'CLF' | 'CLP' | 'CNY' | 'COP' | 'CRC' | 'CUC' | 'CUP' | 'CVE' | 'CZK' | 'DJF' | 'DKK' | 'DOP' | 'DZD' | 'EEK' | 'EGP' | 'ERN' | 'ETB' | 'EUR' | 'FJD' | 'FKP' | 'GBP' | 'GEL' | 'GHS' | 'GIP' | 'GMD' | 'GNF' | 'GTQ' | 'GYD' | 'HKD' | 'HNL' | 'HRK' | 'HTG' | 'HUF' | 'IDR' | 'ILS' | 'INR' | 'IQD' | 'IRR' | 'ISK' | 'JMD' | 'JOD' | 'JPY' | 'KES' | 'KGS' | 'KHR' | 'KMF' | 'KPW' | 'KRW' | 'KWD' | 'KYD' | 'KZT' | 'LAK' | 'LBP' | 'LKR' | 'LRD' | 'LSL' | 'LTL' | 'LVL' | 'LYD' | 'MAD' | 'MDL' | 'MGA' | 'MKD' | 'MMK' | 'MNT' | 'MOP' | 'MRO' | 'MRU' | 'MTL' | 'MUR' | 'MVR' | 'MWK' | 'MXN' | 'MYR' | 'MZN' | 'NAD' | 'NGN' | 'NIO' | 'NOK' | 'NPR' | 'NZD' | 'OMR' | 'PAB' | 'PEN' | 'PGK' | 'PHP' | 'PKR' | 'PLN' | 'PYG' | 'QAR' | 'RON' | 'RSD' | 'RUB' | 'RWF' | 'SAR' | 'SBD' | 'SCR' | 'SDG' | 'SEK' | 'SGD' | 'SHP' | 'SKK' | 'SLE' | 'SLL' | 'SOS' | 'SRD' | 'SSP' | 'STD' | 'STN' | 'SVC' | 'SYP' | 'SZL' | 'THB' | 'TJS' | 'TMM' | 'TMT' | 'TND' | 'TOP' | 'TRY' | 'TTD' | 'TWD' | 'TZS' | 'UAH' | 'UGX' | 'USD' | 'UYI' | 'UYU' | 'UYW' | 'UZS' | 'VED' | 'VEF' | 'VES' | 'VND' | 'VUV' | 'WST' | 'XAF' | 'XCD' | 'XCG' | 'XOF' | 'XPF' | 'YER' | 'ZAR' | 'ZMK' | 'ZMW' | 'ZWD' | 'ZWG' | 'ZWL' | 'ZWN' | 'ZWR';export type DataRequestStatus = 'pending' | 'processing' | 'completed' | 'failed' | (string & {});export type ExchangeStatus = 'requested' | 'approved' | 'received' | 'fulfilled' | 'canceled' | (string & {});export type FeeKind = 'surcharge' | 'handling' | 'gift_wrap' | 'cod' | 'payment' | 'duty' | 'exchange' | (string & {});diff --git a/packages/sdk/src/types/generated/GiftCard.ts b/packages/sdk/src/types/generated/GiftCard.tsindex bb472ed6e9..1a2ca125b2 100644--- a/packages/sdk/src/types/generated/GiftCard.ts+++ b/packages/sdk/src/types/generated/GiftCard.ts@@ -1,13 +1,13 @@-// Typelizer digest d0b64e59fa1c4cd4c5ed2d9e220c9456+// Typelizer digest b8216ce884a74f5aac69a40c70861969//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {GiftCardStatus} from '@/types'+import type {GiftCardStatus, CurrencyCode} from '@/types'interface GiftCard {id: string;code: string;status: GiftCardStatus;- currency: string;+ currency: CurrencyCode;amount: string | null;amount_used: string | null;amount_authorized: string | null;diff --git a/packages/sdk/src/types/generated/GiftCardBatch.ts b/packages/sdk/src/types/generated/GiftCardBatch.tsindex 449a91e5c4..0ca376a0c3 100644--- a/packages/sdk/src/types/generated/GiftCardBatch.ts+++ b/packages/sdk/src/types/generated/GiftCardBatch.ts@@ -1,11 +1,12 @@-// Typelizer digest 784b5e96992dd0313dd9e127def57ba3+// Typelizer digest fae514b2ad11fb5d712283798c7f4f24//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface GiftCardBatch {id: string;codes_count: number;- currency: string | null;+ currency: CurrencyCode | null;prefix: string | null;created_at: string;updated_at: string;diff --git a/packages/sdk/src/types/generated/Import.ts b/packages/sdk/src/types/generated/Import.tsindex f6be72d062..86553bc8a4 100644--- a/packages/sdk/src/types/generated/Import.ts+++ b/packages/sdk/src/types/generated/Import.ts@@ -1,4 +1,4 @@-// Typelizer digest d2300d38c3c521bfff29c27049cfd9e7+// Typelizer digest 3d735df6662c77e7119c0a26d2d259a5//// DO NOT MODIFY: This file was automatically generated by Typelizer.import type {ImportStatus} from '@/types'@@ -14,10 +14,6 @@ interface Import {status: ImportStatus;store_id: string | null;seller_id: string | null;- /** @deprecated Read `store_id` / `seller_id`. Removed in 6.1. */- owner_type: string | null;- /** @deprecated Read `store_id` / `seller_id`. Removed in 6.1. */- owner_id: string | null;user_id: string | null;}diff --git a/packages/sdk/src/types/generated/LineItem.ts b/packages/sdk/src/types/generated/LineItem.tsindex ef6274d369..2eb43cb9b9 100644--- a/packages/sdk/src/types/generated/LineItem.ts+++ b/packages/sdk/src/types/generated/LineItem.ts@@ -1,7 +1,7 @@-// Typelizer digest 4a3f5b43b6b9595123494ab00b94fad4+// Typelizer digest e5780d5c48fcd785f454412d9b87ebfc//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Seller, OptionValue, DigitalLink, TaxLine} from '@/types'+import type {Seller, OptionValue, DigitalLink, TaxLine, CurrencyCode} from '@/types'interface LineItem {id: string;@@ -10,7 +10,7 @@ interface LineItem {preorder: boolean;preorder_ships_at: string | null;quantity: number;- currency: string;+ currency: CurrencyCode;name: string;slug: string;options_text: string;diff --git a/packages/sdk/src/types/generated/Market.ts b/packages/sdk/src/types/generated/Market.tsindex cba577cb2e..137eba425a 100644--- a/packages/sdk/src/types/generated/Market.ts+++ b/packages/sdk/src/types/generated/Market.ts@@ -1,16 +1,16 @@-// Typelizer digest e769280f2ba5ee4b22acacb3cba72406+// Typelizer digest f589778921b953a313a64e7e7fcfc11d//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Country} from '@/types'+import type {Country, CurrencyCode, CountryCode} from '@/types'interface Market {id: string;name: string;- currency: string;+ currency: CurrencyCode;default_locale: string;tax_inclusive: boolean;default: boolean;- country_codes: Array<string>;+ country_codes: Array<CountryCode>;/** @deprecated Use `country_codes`. Removed in 6.1. */country_isos: Array<string>;supported_locales: Array<string>;diff --git a/packages/sdk/src/types/generated/Order.ts b/packages/sdk/src/types/generated/Order.tsindex 0af0629f15..41b71deccb 100644--- a/packages/sdk/src/types/generated/Order.ts+++ b/packages/sdk/src/types/generated/Order.ts@@ -1,7 +1,7 @@-// Typelizer digest 782e161272dacdb4b23abeeb615445cf+// Typelizer digest 4d39933f6969ae65f4bf9248169d0f54//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {AppliedPromotion, Fee, LineItem, Fulfillment, Payment, Address, GiftCard, Market} from '@/types'+import type {AppliedPromotion, Fee, LineItem, Fulfillment, Payment, Address, GiftCard, Market, CurrencyCode} from '@/types'interface Order {id: string;@@ -18,7 +18,7 @@ interface Order {email: string;customer_note: string | null;po_number: string | null;- currency: string;+ currency: CurrencyCode;locale: string | null;total_quantity: number;coupon_code: string | null;diff --git a/packages/sdk/src/types/generated/OrderGroup.ts b/packages/sdk/src/types/generated/OrderGroup.tsindex 98f762a5a9..8090946671 100644--- a/packages/sdk/src/types/generated/OrderGroup.ts+++ b/packages/sdk/src/types/generated/OrderGroup.ts@@ -1,13 +1,13 @@-// Typelizer digest 8b9679aa201b1aaba0dcbd7ca831b7ec+// Typelizer digest 4652f4e56c7e1ce5a74c3604e7500a67//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Address, Order} from '@/types'+import type {Address, Order, CurrencyCode} from '@/types'interface OrderGroup {id: string;number: string;email: string | null;- currency: string;+ currency: CurrencyCode;total: string | null;display_total: string | null;item_total: string | null;diff --git a/packages/sdk/src/types/generated/PaymentSession.ts b/packages/sdk/src/types/generated/PaymentSession.tsindex 71470ea5ae..3550eeb4a0 100644--- a/packages/sdk/src/types/generated/PaymentSession.ts+++ b/packages/sdk/src/types/generated/PaymentSession.ts@@ -1,12 +1,12 @@-// Typelizer digest f37382488804941aef29390f19d3e21a+// Typelizer digest ff05d9ccf62599ade7aebdb179721be7//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {PaymentMethod, Payment, PaymentSessionStatus} from '@/types'+import type {PaymentMethod, Payment, PaymentSessionStatus, CurrencyCode} from '@/types'interface PaymentSession {id: string;status: PaymentSessionStatus;- currency: string;+ currency: CurrencyCode;external_id: string;external_data: Record<string, unknown>;customer_external_id: string | null;diff --git a/packages/sdk/src/types/generated/Price.ts b/packages/sdk/src/types/generated/Price.tsindex b8aca6d779..66f7edc9a1 100644--- a/packages/sdk/src/types/generated/Price.ts+++ b/packages/sdk/src/types/generated/Price.ts@@ -1,10 +1,11 @@-// Typelizer digest 486832c830acf82a1754edef271452b9+// Typelizer digest ca70fe414df158856b4a5a5bed77a9ca//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface Price {id: string;- currency: string | null;+ currency: CurrencyCode | null;amount: string | null;compare_at_amount: string | null;display_amount: string | null;diff --git a/packages/sdk/src/types/generated/PriceHistory.ts b/packages/sdk/src/types/generated/PriceHistory.tsindex 52873033bb..7dcca49ebd 100644--- a/packages/sdk/src/types/generated/PriceHistory.ts+++ b/packages/sdk/src/types/generated/PriceHistory.ts@@ -1,10 +1,11 @@-// Typelizer digest 5e2279c98b06b1d7edd6179b2023e704+// Typelizer digest ad87dcafc61af2c9f2b3f9fa2e73beac//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface PriceHistory {id: string;- currency: string;+ currency: CurrencyCode;amount: string | null;display_amount: string;recorded_at: string;diff --git a/packages/sdk/src/types/generated/ProductFilterPriceRange.ts b/packages/sdk/src/types/generated/ProductFilterPriceRange.tsindex d1dde424ec..2b3cfcc508 100644--- a/packages/sdk/src/types/generated/ProductFilterPriceRange.ts+++ b/packages/sdk/src/types/generated/ProductFilterPriceRange.ts@@ -1,13 +1,14 @@-// Typelizer digest b6efe85fb4f4d2cd1e49361ac4fceca7+// Typelizer digest 6a48e51c021f3d9980ebcfe45edf0543//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface ProductFilterPriceRange {id: string;type: 'price_range';min: string;max: string;- currency: string;+ currency: CurrencyCode;}export default ProductFilterPriceRange;diff --git a/packages/sdk/src/types/generated/StockLocation.ts b/packages/sdk/src/types/generated/StockLocation.tsindex b259c99595..31e694aec1 100644--- a/packages/sdk/src/types/generated/StockLocation.ts+++ b/packages/sdk/src/types/generated/StockLocation.ts@@ -1,6 +1,7 @@-// Typelizer digest 3b49ffc67852ba0c1859e13fee9e7c23+// Typelizer digest 4b297977629c3ebddfeaa9ce7bf11757//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'interface StockLocation {id: string;@@ -8,7 +9,7 @@ interface StockLocation {address1: string | null;city: string | null;zipcode: string | null;- country_code: string | null;+ country_code: CountryCode | null;country_name: string | null;state_code: string | null;state_text: string | null;diff --git a/packages/sdk/src/types/generated/StoreCredit.ts b/packages/sdk/src/types/generated/StoreCredit.tsindex e90a01675f..5057aee7a1 100644--- a/packages/sdk/src/types/generated/StoreCredit.ts+++ b/packages/sdk/src/types/generated/StoreCredit.ts@@ -1,6 +1,7 @@-// Typelizer digest 250523f4e58d2c266aecc3c7d388d257+// Typelizer digest 97d4a98a16dd189897a339512788c177//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'interface StoreCredit {id: string;@@ -10,7 +11,7 @@ interface StoreCredit {display_amount: string | null;display_amount_used: string | null;display_amount_remaining: string | null;- currency: string;+ currency: CurrencyCode;}export default StoreCredit;diff --git a/packages/sdk/src/types/generated/index.ts b/packages/sdk/src/types/generated/index.tsindex 2ef16b56fd..1e948d06e1 100644--- a/packages/sdk/src/types/generated/index.ts+++ b/packages/sdk/src/types/generated/index.ts@@ -1,7 +1,7 @@-// Typelizer digest 5bc3efa86f6c9405fc4a497b233395f3+// Typelizer digest af9d744ea87c9a3aa35bc58722115738//// DO NOT MODIFY: This file was automatically generated by Typelizer.-export type { ClaimStatus, DataRequestStatus, ExchangeStatus, FeeKind, FulfillmentStatus, GiftCardStatus, ImportRowStatus, ImportStatus, InvitationStatus, PaymentSessionStatus, PaymentSetupSessionStatus, PaymentStatus, ProductSubmissionStatus, ReturnStatus, ShippingLabelStatus } from './Enums'+export type { ClaimStatus, CountryCode, CurrencyCode, DataRequestStatus, ExchangeStatus, FeeKind, FulfillmentStatus, GiftCardStatus, ImportRowStatus, ImportStatus, InvitationStatus, PaymentSessionStatus, PaymentSetupSessionStatus, PaymentStatus, ProductSubmissionStatus, ReturnStatus, ShippingLabelStatus } from './Enums'export type { default as Address } from './Address'export type { default as AppliedPromotion } from './AppliedPromotion'export type { default as Base } from './Base'diff --git a/packages/sdk/src/types/params/AddressParams.ts b/packages/sdk/src/types/params/AddressParams.tsindex 06ba2c3475..01c9f16601 100644--- a/packages/sdk/src/types/params/AddressParams.ts+++ b/packages/sdk/src/types/params/AddressParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type AddressParams = {first_name?: stringlast_name?: string@@ -10,7 +12,7 @@ export type AddressParams = {postal_code?: stringphone?: string/** ISO 3166-1 alpha-2 country code, such as `US` or `DE`. */- country_code?: string+ country_code?: CountryCode/** ISO 3166-2 subdivision code without the country prefix, such as `CA` or `NY`. */state_code?: string/** The state name, for countries without predefined states. */diff --git a/packages/sdk/src/types/params/CartAddressParams.ts b/packages/sdk/src/types/params/CartAddressParams.tsindex 4cb5da440a..2c07a0d185 100644--- a/packages/sdk/src/types/params/CartAddressParams.ts+++ b/packages/sdk/src/types/params/CartAddressParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type CartAddressParams = {/** An existing address of the customer to use. The other fields are then ignored. */id?: string@@ -12,7 +14,7 @@ export type CartAddressParams = {postal_code?: stringphone?: string/** ISO 3166-1 alpha-2 country code, such as `US` or `DE`. */- country_code?: string+ country_code?: CountryCode/** ISO 3166-2 subdivision code without the country prefix, such as `CA` or `NY`. */state_code?: string/** The state name, for countries without predefined states. */diff --git a/packages/sdk/src/types/params/CompanyAddressParams.ts b/packages/sdk/src/types/params/CompanyAddressParams.tsindex da9404cd90..3230d28531 100644--- a/packages/sdk/src/types/params/CompanyAddressParams.ts+++ b/packages/sdk/src/types/params/CompanyAddressParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type CompanyAddressParams = {first_name?: stringlast_name?: string@@ -13,7 +15,7 @@ export type CompanyAddressParams = {/** Legacy spelling of `postal_code`; send only one of the two. */zipcode?: string/** ISO 3166-1 alpha-2 code, such as `US`. */- country_code?: string+ country_code?: CountryCode/** The state or province abbreviation, such as `NY`. */state_code?: string/** For countries without states in the database. */diff --git a/packages/sdk/src/types/params/CreateCartParams.ts b/packages/sdk/src/types/params/CreateCartParams.tsindex 3a4d194111..4b5a1e9149 100644--- a/packages/sdk/src/types/params/CreateCartParams.ts+++ b/packages/sdk/src/types/params/CreateCartParams.ts@@ -1,13 +1,14 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.import type { CartAddressParams } from './CartAddressParams'+import type { CurrencyCode } from '../generated'import type { LineItemInputParams } from './LineItemInputParams'export type CreateCartParams = {email?: stringcustomer_note?: stringmarket_id?: string- currency?: string+ currency?: CurrencyCodelocale?: string/** An existing address to ship to. */shipping_address_id?: stringdiff --git a/packages/sdk/src/types/params/UpdateCartParams.ts b/packages/sdk/src/types/params/UpdateCartParams.tsindex 7973f43f0b..b852330755 100644--- a/packages/sdk/src/types/params/UpdateCartParams.ts+++ b/packages/sdk/src/types/params/UpdateCartParams.ts@@ -1,13 +1,14 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.import type { CartAddressParams } from './CartAddressParams'+import type { CurrencyCode } from '../generated'import type { LineItemInputParams } from './LineItemInputParams'export type UpdateCartParams = {email?: stringcustomer_note?: stringmarket_id?: string- currency?: string+ currency?: CurrencyCodelocale?: string/** An existing address to ship to. */shipping_address_id?: stringdiff --git a/packages/sdk/src/zod/generated/Import.ts b/packages/sdk/src/zod/generated/Import.tsindex ab4db15658..1512baa2d2 100644--- a/packages/sdk/src/zod/generated/Import.ts+++ b/packages/sdk/src/zod/generated/Import.ts@@ -11,8 +11,6 @@ export const ImportSchema = z.object({status: z.string(),store_id: z.string().nullable(),seller_id: z.string().nullable(),- owner_type: z.string().nullable(),- owner_id: z.string().nullable(),user_id: z.string().nullable(),});diff --git a/packages/seller-dashboard/src/components/orders/fulfillment-label-upload-dialog.tsx b/packages/seller-dashboard/src/components/orders/fulfillment-label-upload-dialog.tsxindex 4a793b9b33..173a8944f0 100644--- a/packages/seller-dashboard/src/components/orders/fulfillment-label-upload-dialog.tsx+++ b/packages/seller-dashboard/src/components/orders/fulfillment-label-upload-dialog.tsx@@ -9,6 +9,7 @@ import {mapSpreeErrorsToForm,} from '@spree/dashboard-core'import { LabelUploadDialog } from '@spree/dashboard-ui'+import type { CurrencyCode } from '@spree/seller-sdk'import { useState } from 'react'import { useForm } from 'react-hook-form'import { useTranslation } from 'react-i18next'@@ -25,7 +26,7 @@ export function FulfillmentLabelUploadDialog({}: {orderId: stringfulfillmentId: string- currency: string+ currency: CurrencyCodeopen: booleanonOpenChange: (open: boolean) => void}) {diff --git a/packages/seller-dashboard/src/hooks/use-fulfillments.ts b/packages/seller-dashboard/src/hooks/use-fulfillments.tsindex 3608f03dc6..d291f14a30 100644--- a/packages/seller-dashboard/src/hooks/use-fulfillments.ts+++ b/packages/seller-dashboard/src/hooks/use-fulfillments.ts@@ -1,5 +1,6 @@import { useResourceKeyBuilder } from '@spree/dashboard-core'import { toastManager } from '@spree/dashboard-ui'+import type { CurrencyCode } from '@spree/seller-sdk'import { useMutation, useQueryClient } from '@tanstack/react-query'import { sellerClient } from '../api-client'@@ -132,7 +133,7 @@ export function useFulfillmentActions(orderId: string) {carrier?: stringservice?: stringcost?: string- currency?: string+ currency?: CurrencyCode}) => sellerClient().orders.fulfillments.labels.create(orderId, fulfillmentId, params),)diff --git a/packages/seller-sdk/src/seller-client.ts b/packages/seller-sdk/src/seller-client.tsindex 1fec071b82..9eb8235773 100644--- a/packages/seller-sdk/src/seller-client.ts+++ b/packages/seller-sdk/src/seller-client.ts@@ -12,6 +12,7 @@ import type {AuthTokens,Balance,Claim,+ CountryCode,Delivery,DeliveryMethod,DeliveryProfile,@@ -1414,7 +1415,7 @@ export type SellerExportType = 'orders' | 'products'/** A country as the address form needs it. */export interface SellerCountry {- iso: string+ iso: CountryCodeiso3: stringname: stringstates_required?: booleandiff --git a/packages/seller-sdk/src/types/generated/Address.ts b/packages/seller-sdk/src/types/generated/Address.tsindex c1f242f8bf..ae908ecda7 100644--- a/packages/seller-sdk/src/types/generated/Address.ts+++ b/packages/seller-sdk/src/types/generated/Address.ts@@ -1,6 +1,7 @@-// Typelizer digest 74acc83c57bda0444feb047b2b068770+// Typelizer digest d8c33e5067e489004c37bc9a6825cc8e//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CountryCode} from '@/types'type Address = {id: string;@@ -15,16 +16,12 @@ type Address = {phone: string | null;company: string | null;country_name: string;- country_code: string;+ country_code: CountryCode;state_text: string | null;state_code: string | null;quick_checkout: boolean;is_default_billing: boolean;is_default_shipping: boolean;- /** @deprecated Use `state_code`. Removed in 6.1. */- state_abbr: string | null;- /** @deprecated Use `country_code`. Removed in 6.1. */- country_iso: string;state_name: string | null;}diff --git a/packages/seller-sdk/src/types/generated/Balance.ts b/packages/seller-sdk/src/types/generated/Balance.tsindex 882bdf18e1..9cb5cdf457 100644--- a/packages/seller-sdk/src/types/generated/Balance.ts+++ b/packages/seller-sdk/src/types/generated/Balance.ts@@ -1,10 +1,11 @@-// Typelizer digest 723b0f4b15c2068f53f6e116d4b3c35f+// Typelizer digest 32741d363dad0777257d353566768dce//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'type Balance = {- currency: string;- settlement_currency: string;+ currency: CurrencyCode;+ settlement_currency: CurrencyCode;converted: boolean;earned: string;pending: string;diff --git a/packages/seller-sdk/src/types/generated/Enums.ts b/packages/seller-sdk/src/types/generated/Enums.tsindex cf7e722986..99f2223fbe 100644--- a/packages/seller-sdk/src/types/generated/Enums.ts+++ b/packages/seller-sdk/src/types/generated/Enums.ts@@ -1,7 +1,9 @@-// Typelizer digest 4cedf973173371c6009e1ecc1f7b954f+// Typelizer digest 7ee29a9547f9a61bf1a0ece2e3a8c141//// DO NOT MODIFY: This file was automatically generated by Typelizer.export type ClaimStatus = 'open' | 'approved' | 'resolved' | 'denied' | 'canceled' | (string & {});+export type CountryCode = 'AD' | 'AE' | 'AF' | 'AG' | 'AI' | 'AL' | 'AM' | 'AO' | 'AR' | 'AS' | 'AT' | 'AU' | 'AW' | 'AZ' | 'BA' | 'BB' | 'BD' | 'BE' | 'BF' | 'BG' | 'BH' | 'BI' | 'BJ' | 'BL' | 'BM' | 'BN' | 'BO' | 'BQ' | 'BR' | 'BS' | 'BT' | 'BW' | 'BY' | 'BZ' | 'CA' | 'CC' | 'CD' | 'CF' | 'CG' | 'CH' | 'CI' | 'CK' | 'CL' | 'CM' | 'CN' | 'CO' | 'CR' | 'CU' | 'CV' | 'CW' | 'CX' | 'CY' | 'CZ' | 'DE' | 'DJ' | 'DK' | 'DM' | 'DO' | 'DZ' | 'EC' | 'EE' | 'EG' | 'ER' | 'ES' | 'ET' | 'FI' | 'FJ' | 'FK' | 'FM' | 'FO' | 'FR' | 'GA' | 'GB' | 'GD' | 'GE' | 'GF' | 'GG' | 'GH' | 'GI' | 'GL' | 'GM' | 'GN' | 'GP' | 'GQ' | 'GR' | 'GT' | 'GU' | 'GW' | 'GY' | 'HK' | 'HN' | 'HR' | 'HT' | 'HU' | 'ID' | 'IE' | 'IL' | 'IM' | 'IN' | 'IQ' | 'IR' | 'IS' | 'IT' | 'JE' | 'JM' | 'JO' | 'JP' | 'KE' | 'KG' | 'KH' | 'KI' | 'KM' | 'KN' | 'KP' | 'KR' | 'KW' | 'KY' | 'KZ' | 'LA' | 'LB' | 'LC' | 'LI' | 'LK' | 'LR' | 'LS' | 'LT' | 'LU' | 'LV' | 'LY' | 'MA' | 'MC' | 'MD' | 'ME' | 'MF' | 'MG' | 'MH' | 'MK' | 'ML' | 'MM' | 'MN' | 'MO' | 'MP' | 'MQ' | 'MR' | 'MS' | 'MT' | 'MU' | 'MV' | 'MW' | 'MX' | 'MY' | 'MZ' | 'NA' | 'NC' | 'NE' | 'NF' | 'NG' | 'NI' | 'NL' | 'NO' | 'NP' | 'NR' | 'NU' | 'NZ' | 'OM' | 'PA' | 'PE' | 'PF' | 'PG' | 'PH' | 'PK' | 'PL' | 'PM' | 'PN' | 'PR' | 'PS' | 'PT' | 'PW' | 'PY' | 'QA' | 'RE' | 'RO' | 'RS' | 'RU' | 'RW' | 'SA' | 'SB' | 'SC' | 'SD' | 'SE' | 'SG' | 'SH' | 'SI' | 'SJ' | 'SK' | 'SL' | 'SM' | 'SN' | 'SO' | 'SR' | 'SS' | 'ST' | 'SV' | 'SX' | 'SY' | 'SZ' | 'TC' | 'TD' | 'TG' | 'TH' | 'TJ' | 'TK' | 'TL' | 'TM' | 'TN' | 'TO' | 'TR' | 'TT' | 'TV' | 'TW' | 'TZ' | 'UA' | 'UG' | 'US' | 'UY' | 'UZ' | 'VA' | 'VC' | 'VE' | 'VG' | 'VI' | 'VN' | 'VU' | 'WF' | 'WS' | 'YE' | 'YT' | 'ZA' | 'ZM' | 'ZW';+export type CurrencyCode = 'AED' | 'AFN' | 'ALL' | 'AMD' | 'ANG' | 'AOA' | 'ARS' | 'AUD' | 'AWG' | 'AZN' | 'BAM' | 'BBD' | 'BDT' | 'BGN' | 'BHD' | 'BIF' | 'BMD' | 'BND' | 'BOB' | 'BRL' | 'BSD' | 'BTN' | 'BWP' | 'BYN' | 'BYR' | 'BZD' | 'CAD' | 'CDF' | 'CHF' | 'CLF' | 'CLP' | 'CNY' | 'COP' | 'CRC' | 'CUC' | 'CUP' | 'CVE' | 'CZK' | 'DJF' | 'DKK' | 'DOP' | 'DZD' | 'EEK' | 'EGP' | 'ERN' | 'ETB' | 'EUR' | 'FJD' | 'FKP' | 'GBP' | 'GEL' | 'GHS' | 'GIP' | 'GMD' | 'GNF' | 'GTQ' | 'GYD' | 'HKD' | 'HNL' | 'HRK' | 'HTG' | 'HUF' | 'IDR' | 'ILS' | 'INR' | 'IQD' | 'IRR' | 'ISK' | 'JMD' | 'JOD' | 'JPY' | 'KES' | 'KGS' | 'KHR' | 'KMF' | 'KPW' | 'KRW' | 'KWD' | 'KYD' | 'KZT' | 'LAK' | 'LBP' | 'LKR' | 'LRD' | 'LSL' | 'LTL' | 'LVL' | 'LYD' | 'MAD' | 'MDL' | 'MGA' | 'MKD' | 'MMK' | 'MNT' | 'MOP' | 'MRO' | 'MRU' | 'MTL' | 'MUR' | 'MVR' | 'MWK' | 'MXN' | 'MYR' | 'MZN' | 'NAD' | 'NGN' | 'NIO' | 'NOK' | 'NPR' | 'NZD' | 'OMR' | 'PAB' | 'PEN' | 'PGK' | 'PHP' | 'PKR' | 'PLN' | 'PYG' | 'QAR' | 'RON' | 'RSD' | 'RUB' | 'RWF' | 'SAR' | 'SBD' | 'SCR' | 'SDG' | 'SEK' | 'SGD' | 'SHP' | 'SKK' | 'SLE' | 'SLL' | 'SOS' | 'SRD' | 'SSP' | 'STD' | 'STN' | 'SVC' | 'SYP' | 'SZL' | 'THB' | 'TJS' | 'TMM' | 'TMT' | 'TND' | 'TOP' | 'TRY' | 'TTD' | 'TWD' | 'TZS' | 'UAH' | 'UGX' | 'USD' | 'UYI' | 'UYU' | 'UYW' | 'UZS' | 'VED' | 'VEF' | 'VES' | 'VND' | 'VUV' | 'WST' | 'XAF' | 'XCD' | 'XCG' | 'XOF' | 'XPF' | 'YER' | 'ZAR' | 'ZMK' | 'ZMW' | 'ZWD' | 'ZWG' | 'ZWL' | 'ZWN' | 'ZWR';export type ExchangeStatus = 'requested' | 'approved' | 'received' | 'fulfilled' | 'canceled' | (string & {});export type FulfillmentStatus = 'unfulfilled' | 'fulfilled' | 'delivered' | 'canceled' | (string & {});export type ImportRowStatus = 'pending' | 'processing' | 'completed' | 'failed' | (string & {});diff --git a/packages/seller-sdk/src/types/generated/Import.ts b/packages/seller-sdk/src/types/generated/Import.tsindex 23cb8d106b..e63e44609a 100644--- a/packages/seller-sdk/src/types/generated/Import.ts+++ b/packages/seller-sdk/src/types/generated/Import.ts@@ -1,4 +1,4 @@-// Typelizer digest 8a08207848e7d6dedbcd0a6f0b6cb8d1+// Typelizer digest 0aedc5df79e66c6727f2048143abb3bd//// DO NOT MODIFY: This file was automatically generated by Typelizer.import type {ImportMapping, ImportStatus} from '@/types'@@ -14,10 +14,6 @@ type Import = {status: ImportStatus;store_id: string | null;seller_id: string | null;- /** @deprecated Read `store_id` / `seller_id`. Removed in 6.1. */- owner_type: string | null;- /** @deprecated Read `store_id` / `seller_id`. Removed in 6.1. */- owner_id: string | null;user_id: string | null;processing_errors: string | null;delimiter: string;diff --git a/packages/seller-sdk/src/types/generated/Order.ts b/packages/seller-sdk/src/types/generated/Order.tsindex 3903ad7b1b..547261ead6 100644--- a/packages/seller-sdk/src/types/generated/Order.ts+++ b/packages/seller-sdk/src/types/generated/Order.ts@@ -1,13 +1,13 @@-// Typelizer digest d6f233a2a9b55c03e33683ac28423c97+// Typelizer digest 82bd63b6bfab8779cba8c6eccf49cc31//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {OrderLineItem, PaymentSplit, Fulfillment, Address} from '@/types'+import type {OrderLineItem, PaymentSplit, Fulfillment, Address, CurrencyCode} from '@/types'type Order = {id: string;number: string;customer_note: string | null;- currency: string;+ currency: CurrencyCode;total_quantity: number;status: 'draft' | 'placed' | 'canceled';fulfillment_status: 'backorder' | 'canceled' | 'partial' | 'unfulfilled' | 'fulfilled' | 'delivered' | 'pending' | 'ready' | 'shipped' | null;diff --git a/packages/seller-sdk/src/types/generated/OrderLineItem.ts b/packages/seller-sdk/src/types/generated/OrderLineItem.tsindex 249188eea7..e5896203be 100644--- a/packages/seller-sdk/src/types/generated/OrderLineItem.ts+++ b/packages/seller-sdk/src/types/generated/OrderLineItem.ts@@ -1,13 +1,14 @@-// Typelizer digest aac33360a4fd65174577fe9551004a87+// Typelizer digest 24c00ab748f25e0a2506dc5f7f94f15e//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'type OrderLineItem = {id: string;name: string;options_text: string | null;quantity: number;- currency: string;+ currency: CurrencyCode;price: string | null;discounted_amount: string | null;additional_tax_total: string | null;diff --git a/packages/seller-sdk/src/types/generated/PaymentSplit.ts b/packages/seller-sdk/src/types/generated/PaymentSplit.tsindex 04cd2c9110..2488ab5747 100644--- a/packages/seller-sdk/src/types/generated/PaymentSplit.ts+++ b/packages/seller-sdk/src/types/generated/PaymentSplit.ts@@ -1,10 +1,11 @@-// Typelizer digest 7f7d7eb8dba2b13a3a67e61d7da18b70+// Typelizer digest 249d234eea1aa8893ae65ee87c1efd14//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'type PaymentSplit = {id: string;- currency: string;+ currency: CurrencyCode;created_at: string;authorized_amount: string;captured_amount: string;diff --git a/packages/seller-sdk/src/types/generated/Payout.ts b/packages/seller-sdk/src/types/generated/Payout.tsindex 7fa67e7d10..6476b6cc2e 100644--- a/packages/seller-sdk/src/types/generated/Payout.ts+++ b/packages/seller-sdk/src/types/generated/Payout.ts@@ -1,11 +1,12 @@-// Typelizer digest feb207405c2195e4f2cf29b89d9cf847+// Typelizer digest a636fecdb51183c9c9b27ce0bb3e766d//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'type Payout = {id: string;status: string;- currency: string;+ currency: CurrencyCode;reference: string | null;period_start: string | null;period_end: string | null;diff --git a/packages/seller-sdk/src/types/generated/Price.ts b/packages/seller-sdk/src/types/generated/Price.tsindex d8fcdd0e1f..879b49df8f 100644--- a/packages/seller-sdk/src/types/generated/Price.ts+++ b/packages/seller-sdk/src/types/generated/Price.ts@@ -1,10 +1,11 @@-// Typelizer digest b0b489e09a1508742d1471149b8708d5+// Typelizer digest c771f0567e5f073a725cbb4db101fd47//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'type Price = {id: string;- currency: string | null;+ currency: CurrencyCode | null;amount: string | null;compare_at_amount: string | null;price_list_id: string | null;diff --git a/packages/seller-sdk/src/types/generated/PriceHistory.ts b/packages/seller-sdk/src/types/generated/PriceHistory.tsindex 022d35b37d..f6c0088525 100644--- a/packages/seller-sdk/src/types/generated/PriceHistory.ts+++ b/packages/seller-sdk/src/types/generated/PriceHistory.ts@@ -1,10 +1,11 @@-// Typelizer digest 39e498f29bc0668a0ed217cdf01a6751+// Typelizer digest db767e527b3ba6a694cc67b2aa550768//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'type PriceHistory = {id: string;- currency: string;+ currency: CurrencyCode;amount: string | null;recorded_at: string;}diff --git a/packages/seller-sdk/src/types/generated/Profile.ts b/packages/seller-sdk/src/types/generated/Profile.tsindex 9a08fd3de8..69deb453a9 100644--- a/packages/seller-sdk/src/types/generated/Profile.ts+++ b/packages/seller-sdk/src/types/generated/Profile.ts@@ -1,7 +1,7 @@-// Typelizer digest 937723e4c17fd5b9e0df90582405860c+// Typelizer digest 4ada38a7dc51130638061cdb39282643//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Policy, Address, SellerStatus} from '@/types'+import type {Policy, Address, SellerStatus, CurrencyCode} from '@/types'type Profile = {id: string;@@ -27,8 +27,8 @@ type Profile = {policies?: Array<Policy>;on_holiday: boolean;sellable: boolean;- default_currency: string;- supported_currencies: Array<string>;+ default_currency: CurrencyCode;+ supported_currencies: Array<CurrencyCode>;products_count: number;billing_address?: Address;returns_address?: Address;diff --git a/packages/seller-sdk/src/types/generated/ShippingLabel.ts b/packages/seller-sdk/src/types/generated/ShippingLabel.tsindex aee4b4b119..8ca455c1e6 100644--- a/packages/seller-sdk/src/types/generated/ShippingLabel.ts+++ b/packages/seller-sdk/src/types/generated/ShippingLabel.ts@@ -1,7 +1,7 @@-// Typelizer digest 175ac842e43ce206f43f335317cc65e4+// Typelizer digest 0629575beb871e90e563e8e58d80d34a//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {ShippingLabelStatus} from '@/types'+import type {ShippingLabelStatus, CurrencyCode} from '@/types'type ShippingLabel = {id: string;@@ -11,7 +11,7 @@ type ShippingLabel = {carrier_name: string | null;service: string | null;tracking_number: string | null;- currency: string | null;+ currency: CurrencyCode | null;format: string | null;external_id: string | null;metadata: Record<string, unknown>;diff --git a/packages/seller-sdk/src/types/generated/StockLocation.ts b/packages/seller-sdk/src/types/generated/StockLocation.tsindex ea89fef655..78251184a6 100644--- a/packages/seller-sdk/src/types/generated/StockLocation.ts+++ b/packages/seller-sdk/src/types/generated/StockLocation.ts@@ -1,7 +1,7 @@-// Typelizer digest b1c46352637aa7f28be290f3feb28f7d+// Typelizer digest 21dfc45eec4f49de258df762bffbe0a1//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {StockLocationKind} from '@/types'+import type {CountryCode, StockLocationKind} from '@/types'type StockLocation = {id: string;@@ -9,7 +9,7 @@ type StockLocation = {address1: string | null;city: string | null;zipcode: string | null;- country_code: string | null;+ country_code: CountryCode | null;country_name: string | null;state_code: string | null;state_text: string | null;diff --git a/packages/seller-sdk/src/types/generated/Transfer.ts b/packages/seller-sdk/src/types/generated/Transfer.tsindex e757d78fca..ece5658f02 100644--- a/packages/seller-sdk/src/types/generated/Transfer.ts+++ b/packages/seller-sdk/src/types/generated/Transfer.ts@@ -1,18 +1,19 @@-// Typelizer digest 818213e522fa078a0b683f728b123228+// Typelizer digest 84fe5d0b238d30294b3cbbee8614a666//// DO NOT MODIFY: This file was automatically generated by Typelizer.+import type {CurrencyCode} from '@/types'type Transfer = {id: string;kind: string;status: string;- currency: string;+ currency: CurrencyCode;reference: string | null;created_at: string;updated_at: string;amount: string;settled_amount: string | null;- settled_currency: string | null;+ settled_currency: CurrencyCode | null;converted: boolean;order_id: string | null;payout_id: string | null;diff --git a/packages/seller-sdk/src/types/generated/Variant.ts b/packages/seller-sdk/src/types/generated/Variant.tsindex 25344af14f..228b077c32 100644--- a/packages/seller-sdk/src/types/generated/Variant.ts+++ b/packages/seller-sdk/src/types/generated/Variant.ts@@ -1,7 +1,7 @@-// Typelizer digest 35bcd9f5f5fe62db10662174ca954800+// Typelizer digest 7ab42da9313b31668eca3d5cccb7dd96//// DO NOT MODIFY: This file was automatically generated by Typelizer.-import type {Price, PriceHistory, Seller, Media, OptionValue, CustomField, StockLevel} from '@/types'+import type {Price, PriceHistory, Seller, Media, OptionValue, CustomField, StockLevel, CurrencyCode, CountryCode} from '@/types'type Variant = {id: string;@@ -37,11 +37,11 @@ type Variant = {prior_price?: PriceHistory | null;metadata: Record<string, unknown>;position: number;- cost_currency: string | null;+ cost_currency: CurrencyCode | null;barcode: string | null;backorder_limit: number | null;hs_code: string | null;- country_of_origin: string | null;+ country_of_origin: CountryCode | null;customs_description: string | null;created_at: string;updated_at: string;diff --git a/packages/seller-sdk/src/types/generated/index.ts b/packages/seller-sdk/src/types/generated/index.tsindex 9dce3550c7..1c1a4e833e 100644--- a/packages/seller-sdk/src/types/generated/index.ts+++ b/packages/seller-sdk/src/types/generated/index.ts@@ -1,13 +1,13 @@-// Typelizer digest 8e3f7f5fe36c8db2ba7aeb82704bdb86+// Typelizer digest be63ed125d4e0152b15f85b1f6fd4bc0//// DO NOT MODIFY: This file was automatically generated by Typelizer.-export type { ClaimStatus, ExchangeStatus, FulfillmentStatus, ImportRowStatus, ImportStatus, InvitationStatus, ProductStatus, ProductSubmissionStatus, ReturnStatus, SellerRequirementSubmissionStatus, SellerStatus, ShippingLabelStatus, StockLocationKind } from './Enums'-export type { default as Address } from './Address'+export type { ClaimStatus, CountryCode, CurrencyCode, ExchangeStatus, FulfillmentStatus, ImportRowStatus, ImportStatus, InvitationStatus, ProductStatus, ProductSubmissionStatus, ReturnStatus, SellerRequirementSubmissionStatus, SellerStatus, ShippingLabelStatus, StockLocationKind } from './Enums'export type { default as Category } from './Category'export type { default as CustomField } from './CustomField'export type { default as OptionType } from './OptionType'export type { default as OptionValue } from './OptionValue'export type { default as Account } from './Account'+export type { default as Address } from './Address'export type { default as Balance } from './Balance'export type { default as ClaimLineItem } from './ClaimLineItem'export type { default as Claim } from './Claim'diff --git a/packages/seller-sdk/src/types/params/OrderAddressParams.ts b/packages/seller-sdk/src/types/params/OrderAddressParams.tsindex 6fd79d7016..e8809d2358 100644--- a/packages/seller-sdk/src/types/params/OrderAddressParams.ts+++ b/packages/seller-sdk/src/types/params/OrderAddressParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type OrderAddressParams = {first_name?: stringlast_name?: string@@ -14,5 +16,5 @@ export type OrderAddressParams = {state_code?: string | nullstate_name?: string | nulllabel?: string | null- country_code?: string+ country_code?: CountryCode}diff --git a/packages/seller-sdk/src/types/params/ProductParams.ts b/packages/seller-sdk/src/types/params/ProductParams.tsindex 0653de123a..8581073a98 100644--- a/packages/seller-sdk/src/types/params/ProductParams.ts+++ b/packages/seller-sdk/src/types/params/ProductParams.ts@@ -1,5 +1,6 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'import type { SellerProductMediaParams } from './SellerProductMediaParams'import type { SellerProductVariantParams } from './SellerProductVariantParams'@@ -27,7 +28,7 @@ export type ProductParams = {*/prices?: {/** Omit to price in the store's currency. A seller has no currency of their own. */- currency?: string+ currency?: CurrencyCode/*** A canonical decimal string (`"1234.56"`: period decimal, no grouping). The API does not parse* localized input.diff --git a/packages/seller-sdk/src/types/params/SellerAddressParams.ts b/packages/seller-sdk/src/types/params/SellerAddressParams.tsindex b532b5e081..3f65add5aa 100644--- a/packages/seller-sdk/src/types/params/SellerAddressParams.ts+++ b/packages/seller-sdk/src/types/params/SellerAddressParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type SellerAddressParams = {first_name?: stringlast_name?: string@@ -13,7 +15,7 @@ export type SellerAddressParams = {/** Legacy spelling of `postal_code`; send only one of the two. */zipcode?: string/** ISO 3166-1 alpha-2 code, such as `US`. */- country_code?: string+ country_code?: CountryCode/** The state or province abbreviation, such as `NY`. */state_code?: string/** For countries without states in the database. */diff --git a/packages/seller-sdk/src/types/params/SellerProductVariantParams.ts b/packages/seller-sdk/src/types/params/SellerProductVariantParams.tsindex 7334ef2db0..3d1e7a498f 100644--- a/packages/seller-sdk/src/types/params/SellerProductVariantParams.ts+++ b/packages/seller-sdk/src/types/params/SellerProductVariantParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+import type { CurrencyCode } from '../generated'import type { StockLevelParams } from './StockLevelParams'import type { VariantOptionParams } from './VariantOptionParams'@@ -8,7 +10,7 @@ export type SellerProductVariantParams = {sku?: stringbarcode?: stringcost_price?: string | null- cost_currency?: string+ cost_currency?: CurrencyCodeweight?: number | nullheight?: number | nullwidth?: number | null@@ -16,8 +18,8 @@ export type SellerProductVariantParams = {weight_unit?: 'g' | 'kg' | 'lb' | 'oz'dimensions_unit?: 'mm' | 'cm' | 'in' | 'ft'hs_code?: string- country_of_origin?: stringcustoms_description?: string+ country_of_origin?: CountryCodeminimum_order_quantity?: number | nullorder_multiple?: number | nullpurchase_unit?: string@@ -44,7 +46,7 @@ export type SellerProductVariantParams = {/** Per-currency prices. Upserted by currency. */prices?: {/** Omit to price in the store's currency. A seller has no currency of their own. */- currency?: string+ currency?: CurrencyCode/*** A canonical decimal string (`"1234.56"`: period decimal, no grouping). The API does not parse* localized input.diff --git a/packages/seller-sdk/src/types/params/ShippingLabelCreateParams.ts b/packages/seller-sdk/src/types/params/ShippingLabelCreateParams.tsindex fe4202f915..b0635d886e 100644--- a/packages/seller-sdk/src/types/params/ShippingLabelCreateParams.ts+++ b/packages/seller-sdk/src/types/params/ShippingLabelCreateParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CurrencyCode } from '../generated'+export type ShippingLabelCreateParams = {/** A `signed_id` from `files.upload()`. */file_signed_id: string@@ -18,7 +20,7 @@ export type ShippingLabelCreateParams = {*/cost?: string/** Currency of the cost. */- currency?: string+ currency?: CurrencyCode/** Taken from the file when omitted. */file_format?: 'pdf' | 'png' | 'zpl'/** Tracking page for the consignment the label mints. */diff --git a/packages/seller-sdk/src/types/params/StockLocationParams.ts b/packages/seller-sdk/src/types/params/StockLocationParams.tsindex 7d8c5a8ff9..7498516e78 100644--- a/packages/seller-sdk/src/types/params/StockLocationParams.ts+++ b/packages/seller-sdk/src/types/params/StockLocationParams.ts@@ -1,5 +1,7 @@// This file is auto-generated from the request schemas in docs/api-reference by `pnpm generate:params`. Do not edit directly.+import type { CountryCode } from '../generated'+export type StockLocationParams = {name?: stringadmin_name?: string | null@@ -17,7 +19,7 @@ export type StockLocationParams = {phone?: string | nullcompany?: string | null/** ISO-3166 alpha-2 country code. */- country_code?: string | null+ country_code?: CountryCode | null/** State or province abbreviation, resolved against the selected country's states. */state_code?: string | null/** Free-text state for countries that don't have a states list. */diff --git a/packages/seller-sdk/src/zod/generated/Address.ts b/packages/seller-sdk/src/zod/generated/Address.tsindex ee0f2d0143..7f47805f72 100644--- a/packages/seller-sdk/src/zod/generated/Address.ts+++ b/packages/seller-sdk/src/zod/generated/Address.ts@@ -20,8 +20,6 @@ export const AddressSchema = z.object({quick_checkout: z.boolean(),is_default_billing: z.boolean(),is_default_shipping: z.boolean(),- state_abbr: z.string().nullable(),- country_iso: z.string(),state_name: z.string().nullable(),});diff --git a/packages/seller-sdk/src/zod/generated/Import.ts b/packages/seller-sdk/src/zod/generated/Import.tsindex 041f563ad1..4cd357acd4 100644--- a/packages/seller-sdk/src/zod/generated/Import.ts+++ b/packages/seller-sdk/src/zod/generated/Import.ts@@ -12,8 +12,6 @@ export const ImportSchema = z.object({status: z.string(),store_id: z.string().nullable(),seller_id: z.string().nullable(),- owner_type: z.string().nullable(),- owner_id: z.string().nullable(),user_id: z.string().nullable(),processing_errors: z.string().nullable(),delimiter: z.string(),diff --git a/spree/api/app/controllers/concerns/spree/api/v3/legacy_preference_params.rb b/spree/api/app/controllers/concerns/spree/api/v3/legacy_preference_params.rbdeleted file mode 100644index fc81339751..0000000000--- a/spree/api/app/controllers/concerns/spree/api/v3/legacy_preference_params.rb+++ /dev/null@@ -1,48 +0,0 @@-module Spree- module Api- module V3- # Accepts the pre-6.0 shapes of a write for one release, with a- # deprecation warning, so a client written for 5.x keeps saving instead- # of having its change silently dropped: a setting under its- # `preferred_<name>` key, and a calculator as `calculator_type` plus- # `calculator_preferences`. Responses use only the new shapes. Removed- # in Spree 6.1.- module LegacyPreferenceParams- extend ActiveSupport::Concern-- class_methods do- # @param model [Class] the model whose exposed preferences the controller writes- def accepts_legacy_preference_params(model)- before_action(if: -> { request.post? || request.patch? || request.put? }) { translate_legacy_preference_params(model) }- end-- def accepts_legacy_calculator_params- before_action(if: -> { request.post? || request.patch? || request.put? }) { translate_legacy_calculator_params }- end- end-- private-- def translate_legacy_preference_params(model)- params.keys.each do |key|- name = model.exposed_preference_name(key)&.to_s- next if name.nil? || params.key?(name)-- Spree::Deprecation.warn("The `#{key}` parameter is deprecated and will be removed in Spree 6.1. Send `#{name}` instead.")- params[name] = params.delete(key)- end- end-- def translate_legacy_calculator_params- return if params.key?(:calculator) || !(params.key?(:calculator_type) || params.key?(:calculator_preferences))-- Spree::Deprecation.warn(- 'The `calculator_type` and `calculator_preferences` parameters are deprecated and will be removed in Spree 6.1. ' \- 'Send `calculator: { type, preferences }` instead.'- )- params[:calculator] = { type: params.delete(:calculator_type), preferences: params.delete(:calculator_preferences) }.compact- end- end- end- end-enddiff --git a/spree/api/app/controllers/spree/api/v3/admin/channels_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/channels_controller.rbindex 6c745a5c73..990a768cfb 100644--- a/spree/api/app/controllers/spree/api/v3/admin/channels_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/channels_controller.rb@@ -3,10 +3,6 @@ module Spreemodule V3module Adminclass ChannelsController < ResourceController- include Spree::Api::V3::LegacyPreferenceParams-- accepts_legacy_preference_params Spree::Channel-scoped_resource :settingsrequest_params :channel dodiff --git a/spree/api/app/controllers/spree/api/v3/admin/companies/tax_exemption_certificates_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/companies/tax_exemption_certificates_controller.rbindex ae531974e3..19ebd8ff31 100644--- a/spree/api/app/controllers/spree/api/v3/admin/companies/tax_exemption_certificates_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/companies/tax_exemption_certificates_controller.rb@@ -15,8 +15,8 @@ module Spreedescription: "Becomes the tax provider's entity use code. Required when creating."string :issuing_authority, nullable: true, example: 'Finanzamt Berlin'datetime :issued_at, :expires_at, nullable: true- string :country_code, :state_code, nullable: true,- description: 'Where the certificate holds. Omit both for one valid everywhere.'+ country :country_code, nullable: true, description: 'Where the certificate holds. Omit it and `state_code` for one valid everywhere.'+ string :state_code, nullable: truestring :document_signed_id,description: "A `signed_id` from `files.upload()` with `visibility: 'private'`."object :metadatadiff --git a/spree/api/app/controllers/spree/api/v3/admin/customers/store_credits_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/customers/store_credits_controller.rbindex 3b80a131eb..1b63221c7b 100644--- a/spree/api/app/controllers/spree/api/v3/admin/customers/store_credits_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/customers/store_credits_controller.rb@@ -11,7 +11,7 @@ module Spreerequest_params :customer_store_credit dodecimal :amount, required: :create, example: '50.00'- string :currency, required: :create, only: :create, example: 'USD'+ currency :currency, required: :create, only: :create, example: 'USD'string :memoenddiff --git a/spree/api/app/controllers/spree/api/v3/admin/delivery_methods_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/delivery_methods_controller.rbindex e18d4996c8..543a62af7f 100644--- a/spree/api/app/controllers/spree/api/v3/admin/delivery_methods_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/delivery_methods_controller.rb@@ -3,10 +3,6 @@ module Spreemodule V3module Adminclass DeliveryMethodsController < ResourceController- include Spree::Api::V3::LegacyPreferenceParams-- accepts_legacy_calculator_params-scoped_resource :delivery_methods# A single POST/PATCH can ship eligibility rules and carrier servicediff --git a/spree/api/app/controllers/spree/api/v3/admin/delivery_zones_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/delivery_zones_controller.rbindex 537026a1bf..ca8843f8b2 100644--- a/spree/api/app/controllers/spree/api/v3/admin/delivery_zones_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/delivery_zones_controller.rb@@ -17,7 +17,7 @@ module Spreeobject :members, array: true, as: 'DeliveryZoneMemberParams',description: "Replaces the zone's full member set atomically." dostring :member_type, required: true, enum: Spree::DeliveryZoneMember::MEMBER_TYPES- string :country_code, example: 'US'+ country :country_code, example: 'US'string :state_code, description: 'A subdivision code or name. Without `country_code` the country is inferred when only one country matches.'string :postal_code_prefix, :postal_code_from, :postal_code_toenddiff --git a/spree/api/app/controllers/spree/api/v3/admin/gift_card_batches_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/gift_card_batches_controller.rbindex bcbcfc4041..78b387e151 100644--- a/spree/api/app/controllers/spree/api/v3/admin/gift_card_batches_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/gift_card_batches_controller.rb@@ -18,7 +18,7 @@ module Spreedescription: 'The amount of each card, greater than zero.'integer :codes_count, required: :create, example: 100,description: 'How many cards to generate. Capped at `gift_card_batch_limit`; batches over `gift_card_batch_web_limit` generate in the background.'- string :currency, example: 'USD', description: 'ISO 4217 currency code. Defaults to the store currency.'+ currency :currency, example: 'USD', description: 'ISO 4217 currency code. Defaults to the store currency.'date :expires_at, nullable: true, example: '2030-12-31'enddiff --git a/spree/api/app/controllers/spree/api/v3/admin/gift_cards_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/gift_cards_controller.rbindex 6d290848f9..e2aa589f61 100644--- a/spree/api/app/controllers/spree/api/v3/admin/gift_cards_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/gift_cards_controller.rb@@ -15,7 +15,7 @@ module Spreerequest_params :gift_card dodecimal :amount, required: :create, example: '25.00', description: 'Greater than zero.'- string :currency, example: 'USD', description: 'ISO 4217 currency code. Defaults to the store currency.'+ currency :currency, example: 'USD', description: 'ISO 4217 currency code. Defaults to the store currency.'string :code, example: 'WELCOME50', description: 'Generated when omitted.'date :expires_at, nullable: true, example: '2030-12-31'# Resolved through the caller's ability by `resolve_customer`.diff --git a/spree/api/app/controllers/spree/api/v3/admin/imports_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/imports_controller.rbindex 38a87acf7a..720cceefc0 100644--- a/spree/api/app/controllers/spree/api/v3/admin/imports_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/imports_controller.rb@@ -11,10 +11,6 @@ module Spree# Spree::Import.required_scope). The index is filtered to the types# the key can write.class ImportsController < ResourceController- include Spree::Api::V3::LegacyPreferenceParams-- accepts_legacy_preference_params Spree::Import-include ActiveStorage::SetCurrent# The index spans many import types — `scope` filters it to thediff --git a/spree/api/app/controllers/spree/api/v3/admin/markets_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/markets_controller.rbindex 31b343bc1f..393aff0c3f 100644--- a/spree/api/app/controllers/spree/api/v3/admin/markets_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/markets_controller.rb@@ -15,7 +15,7 @@ module Spreerequest_params :market dostring :name, required: :create, example: 'Europe', description: 'Display name, unique within the store.'- string :currency, required: :create, example: 'EUR', description: 'ISO 4217 currency code.'+ currency :currency, required: :create, example: 'EUR', description: 'ISO 4217 currency code.'string :default_locale, required: :create, example: 'de',description: 'Locale used as the market default. Always part of `supported_locales`.'boolean :tax_inclusive, description: 'Display prices with tax included.'@@ -25,7 +25,7 @@ module Spreeinteger :position, description: 'Sort order within the store; lower comes first.'string :supported_locales, array: true, example: %w[de en],description: 'Locales available in this market. The default locale is always included.'- string :country_codes, array: true, required: :create, example: %w[DE FR],+ country :country_codes, array: true, required: :create, example: %w[DE FR],description: 'ISO 3166-1 alpha-2 codes of the countries in this market. At least one is required.'enddiff --git a/spree/api/app/controllers/spree/api/v3/admin/orders/labels_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/orders/labels_controller.rbindex b7fb049e03..985085fc87 100644--- a/spree/api/app/controllers/spree/api/v3/admin/orders/labels_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/orders/labels_controller.rb@@ -20,7 +20,7 @@ module Spreestring :carrier, description: "Free text; a forwarder's name is as valid as a carrier slug. Detected from the number when omitted."string :service, description: 'Carrier service the label was bought at.'decimal :cost, description: "What the merchant paid the carrier. Accounting data only; it never touches the order's shipping charge."- string :currency, description: 'Currency of the cost.'+ currency :currency, description: 'Currency of the cost.'string :file_format, enum: %w[pdf png zpl], description: 'Taken from the file when omitted.'string :tracking_url, description: 'Tracking page for the consignment the label mints.'enddiff --git a/spree/api/app/controllers/spree/api/v3/admin/orders_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/orders_controller.rbindex 74b106bc2d..4acdf2a235 100644--- a/spree/api/app/controllers/spree/api/v3/admin/orders_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/orders_controller.rb@@ -20,7 +20,7 @@ module Spreeid :customer_idboolean :use_customer_default_address, only: :create,description: "With `customer_id`, copies the customer's saved billing and shipping addresses onto the order."- string :currency, example: 'USD'+ currency :currency, example: 'USD'id :market_idid :channel_id, description: 'Defaults to the store primary channel when omitted.'string :locale, example: 'en-US'diff --git a/spree/api/app/controllers/spree/api/v3/admin/payment_methods_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/payment_methods_controller.rbindex 337475a42d..be619fd00e 100644--- a/spree/api/app/controllers/spree/api/v3/admin/payment_methods_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/payment_methods_controller.rb@@ -17,7 +17,6 @@ module Spreestring :description, nullable: trueboolean :activeboolean :storefront_visible, description: 'False keeps the method to the dashboard; true also offers it on the storefront.'- boolean :auto_capture, nullable: true, deprecated: 'Use `capture_method`. Removed in 6.1.'string :capture_method, nullable: true, enum: Spree::CaptureMethod::CAPTURE_METHODS,description: 'When customers are charged for this method. Null inherits the store setting.'integer :positiondiff --git a/spree/api/app/controllers/spree/api/v3/admin/prices_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/prices_controller.rbindex ac7819a74c..b38d46792f 100644--- a/spree/api/app/controllers/spree/api/v3/admin/prices_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/prices_controller.rb@@ -17,7 +17,7 @@ module Spree# scopes (+permitted_params+), so a foreign or unknown id 404s.request_params :price doid :variant_id, required: :create, example: 'variant_xY9'- string :currency, required: :create, example: 'USD'+ currency :currency, required: :create, example: 'USD'integer :min_quantity,description: 'The quantity a line must reach for this price to apply. Omit for the bottom rung of the ladder. Anything above 1 requires a `price_list_id`.'decimal :amount, :compare_at_amount, nullable: true, example: '19.99'@@ -31,7 +31,7 @@ module Spreeid :id, nullable: true, example: 'price_aBc123',description: 'Present: updates that row. Absent: upserts on `(variant_id, currency, price_list_id, min_quantity)`.'id :variant_id, required: true, example: 'variant_xY9'- string :currency, required: true, example: 'USD'+ currency :currency, required: true, example: 'USD'id :price_list_id, nullable: true, example: 'pl_aBc123', description: 'Omit or null for a base price.'integer :min_quantity,description: "The rung of the variant's ladder. Omit for the bottom rung; anything above 1 requires a `price_list_id`. A variant carries at most ten rungs on one list per currency."diff --git a/spree/api/app/controllers/spree/api/v3/admin/purchase_orders_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/purchase_orders_controller.rbindex cd52a3b2dd..64d5d8a11a 100644--- a/spree/api/app/controllers/spree/api/v3/admin/purchase_orders_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/purchase_orders_controller.rb@@ -22,7 +22,7 @@ module Spreerequest_params :purchase_order doid :supplier_id, required: :create, permit: false, example: 'sup_1234567890'id :destination_location_id, required: :create, permit: false, example: 'sloc_1234567890'- string :currency, nullable: true, example: 'USD',+ currency :currency, nullable: true, example: 'USD',description: "Defaults to the store's currency; set it for a foreign-currency order."date :expected_at, nullable: true, example: '2026-10-01', description: 'The day the supplier promised. `null` clears it.'date :cancel_by, nullable: true, description: 'The day after which the goods are no longer wanted. `null` clears it.'diff --git a/spree/api/app/controllers/spree/api/v3/admin/reporting_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/reporting_controller.rbindex e910b5e3cb..432d65d9bc 100644--- a/spree/api/app/controllers/spree/api/v3/admin/reporting_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/reporting_controller.rb@@ -40,7 +40,7 @@ module Spreestring :compare, enum: Spree::Reporting::Query::COMPARE_MODESstring :sort, description: 'A metric name; prefix it with `-` to sort descending.'integer :limit, description: "At most #{Spree::Reporting::Query::MAX_LIMIT}."- string :currency+ currency :currencyend# POST /api/v3/admin/reporting/querydiff --git a/spree/api/app/controllers/spree/api/v3/admin/setup_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/setup_controller.rbindex ef53039839..ab87c72e61 100644--- a/spree/api/app/controllers/spree/api/v3/admin/setup_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/setup_controller.rb@@ -22,10 +22,10 @@ module Spreestring :first_name, example: 'Olivia'string :last_name, example: 'Owner'string :store_name, permit: false, example: 'My Store'- string :country_code, required: true, permit: false, example: 'US',+ country :country_code, required: true, permit: false, example: 'US',description: 'ISO 3166-1 alpha-2 country the store sells from. It determines the default market, the warehouse, the delivery zones and the currency.'string :locale, permit: false, example: 'en', description: "Storefront locale. Defaults to the country's own language."- string :currency, permit: false, example: 'USD',+ currency :currency, permit: false, example: 'USD',description: "ISO 4217 currency. Defaults to the country's own currency: pass one only when the store prices in something else."boolean :sample_data, permit: false,description: 'Load the demo catalog, customers and orders in the background once the admin account exists. The load takes minutes, so the response does not wait for it.'diff --git a/spree/api/app/controllers/spree/api/v3/admin/stock_locations_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/stock_locations_controller.rbindex 892c7e2d8f..a73622ea9d 100644--- a/spree/api/app/controllers/spree/api/v3/admin/stock_locations_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/stock_locations_controller.rb@@ -15,7 +15,7 @@ module Spreedescription: 'Categorizes the location.'boolean :propagate_all_variants, :backorderable_defaultstring :address1, :address2, :city, :zipcode, :phone, :company, nullable: true- string :country_code, nullable: true, example: 'US', description: 'ISO-3166 alpha-2 country code.'+ country :country_code, nullable: true, example: 'US', description: 'ISO-3166 alpha-2 country code.'string :state_code, nullable: true, example: 'NY',description: "State or province abbreviation, resolved against the selected country's states."string :state_name, nullable: true, description: "Free-text state for countries that don't have a states list."diff --git a/spree/api/app/controllers/spree/api/v3/admin/store_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/store_controller.rbindex 49445e58b6..fbef47294c 100644--- a/spree/api/app/controllers/spree/api/v3/admin/store_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/store_controller.rb@@ -3,10 +3,7 @@ module Spreemodule V3module Adminclass StoreController < Admin::BaseController- include Spree::Api::V3::LegacyPreferenceParams-scoped_resource :settings- accepts_legacy_preference_params Spree::Storerequest_params :store dostring :name, example: 'My Store'@@ -26,8 +23,6 @@ module Spreeboolean :address_requires_phone, description: 'Makes a phone number mandatory on customer addresses.'string :capture_method, enum: Spree::CaptureMethod::CAPTURE_METHODS,description: "The store-wide default for when a customer is charged rather than only authorized. A payment method's own setting wins when set."- boolean :preferred_auto_capture, :preferred_auto_capture_on_dispatch,- deprecated: 'Use `capture_method`. Removed in 6.1.'boolean :track_inventory_levels,description: 'Counts on-hand quantities. Off means everything is treated as always available.'boolean :stock_reservations_enabled,diff --git a/spree/api/app/controllers/spree/api/v3/admin/suppliers_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/suppliers_controller.rbindex 61cc7c0606..f5cbed2795 100644--- a/spree/api/app/controllers/spree/api/v3/admin/suppliers_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/suppliers_controller.rb@@ -19,7 +19,7 @@ module Spreestring :city, nullable: true, example: 'Brooklyn'string :state_name, nullable: truestring :state_code, nullable: true, example: 'NY'- string :country_code, nullable: true, example: 'US'+ country :country_code, nullable: true, example: 'US'string :postal_code, nullable: true, example: '11201'object :metadata, nullable: trueenddiff --git a/spree/api/app/controllers/spree/api/v3/admin/tax_rates_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/tax_rates_controller.rbindex ee69ead133..816dc1dfe0 100644--- a/spree/api/app/controllers/spree/api/v3/admin/tax_rates_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/tax_rates_controller.rb@@ -13,7 +13,7 @@ module Spreedecimal :rate_percent, example: '19', description: 'The rate as a percentage.'boolean :included_in_price, :show_rate_in_labelid :tax_category_id- string :country_code, nullable: true, example: 'DE',+ country :country_code, nullable: true, example: 'DE',description: 'ISO country code. A rate naming no country taxes everywhere.'string :state_code, nullable: true, example: 'CA', description: 'State abbreviation within that country.'object :metadatadiff --git a/spree/api/app/controllers/spree/api/v3/seller/delivery_methods_controller.rb b/spree/api/app/controllers/spree/api/v3/seller/delivery_methods_controller.rbindex 801507cead..4526d20faa 100644--- a/spree/api/app/controllers/spree/api/v3/seller/delivery_methods_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/seller/delivery_methods_controller.rb@@ -17,10 +17,6 @@ module Spree# `Spree::DeliveryMethod` validates and why neither provider is# writable here.class DeliveryMethodsController < Seller::ResourceController- include Spree::Api::V3::LegacyPreferenceParams-- accepts_legacy_calculator_params-scoped_resource :delivery_methods# No provider fields: both are fixed for a seller's method, anddiff --git a/spree/api/app/controllers/spree/api/v3/seller/imports_controller.rb b/spree/api/app/controllers/spree/api/v3/seller/imports_controller.rbindex 49cae8a863..6759768748 100644--- a/spree/api/app/controllers/spree/api/v3/seller/imports_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/seller/imports_controller.rb@@ -22,10 +22,6 @@ module Spree# says; a seller reaches `active` only through review# (docs/plans/6.0-seller-product-submission.md).class ImportsController < Seller::ResourceController- include Spree::Api::V3::LegacyPreferenceParams-- accepts_legacy_preference_params Spree::Import-include ActiveStorage::SetCurrent# The import types a seller may run. An operator's `customers` ordiff --git a/spree/api/app/controllers/spree/api/v3/seller/orders/labels_controller.rb b/spree/api/app/controllers/spree/api/v3/seller/orders/labels_controller.rbindex 4a174297fc..be8d72abcc 100644--- a/spree/api/app/controllers/spree/api/v3/seller/orders/labels_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/seller/orders/labels_controller.rb@@ -23,7 +23,7 @@ module Spreestring :carrier, description: "Free text; a forwarder's name is as valid as a carrier slug. Detected from the number when omitted."string :service, description: 'Carrier service the label was bought at.'decimal :cost, description: "What the seller paid the carrier. Accounting data only; it never touches the order's shipping charge."- string :currency, description: 'Currency of the cost.'+ currency :currency, description: 'Currency of the cost.'string :file_format, enum: %w[pdf png zpl], description: 'Taken from the file when omitted.'string :tracking_url, description: 'Tracking page for the consignment the label mints.'enddiff --git a/spree/api/app/controllers/spree/api/v3/seller/orders_controller.rb b/spree/api/app/controllers/spree/api/v3/seller/orders_controller.rbindex 95634c018a..02f95f06c1 100644--- a/spree/api/app/controllers/spree/api/v3/seller/orders_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/seller/orders_controller.rb@@ -24,7 +24,7 @@ module SpreeADDRESS = Spree::Api::V3::RequestSchema.shape('OrderAddressParams') dostring :first_name, :last_name, :address1, :city, :postal_code, :zipcodestring :company, :address2, :phone, :alternative_phone, :state_code, :state_name, :label, nullable: true- string :country_code, example: 'US'+ country :country_code, example: 'US'endrequest_params 'OrderCancelParams', action: :cancel dodiff --git a/spree/api/app/controllers/spree/api/v3/seller/products_controller.rb b/spree/api/app/controllers/spree/api/v3/seller/products_controller.rbindex f6a6e6f124..59f1502f7f 100644--- a/spree/api/app/controllers/spree/api/v3/seller/products_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/seller/products_controller.rb@@ -44,7 +44,7 @@ module Spree# The operator's price shape, except `currency` may be left out: the# store's currency is assumed (see `default_price_currencies`).PRICE = Spree::Api::V3::RequestSchema.new do- string :currency, example: 'USD',+ currency :currency, example: 'USD',description: "Omit to price in the store's currency. A seller has no currency of their own."decimal :amount, required: true, example: '24.00',description: 'A canonical decimal string (`"1234.56"`: period decimal, no grouping). The API does not parse localized input.'@@ -84,11 +84,12 @@ module Spreeid :idstring :sku, :barcodedecimal :cost_price, nullable: true- string :cost_currency+ currency :cost_currencynumber :weight, :height, :width, :depth, nullable: truestring :weight_unit, enum: Spree::Variant::WEIGHT_UNITSstring :dimensions_unit, enum: Spree::Variant::DIMENSION_UNITS- string :hs_code, :country_of_origin, :customs_description+ string :hs_code, :customs_description+ country :country_of_origininteger :minimum_order_quantity, :order_multiple, nullable: truestring :purchase_unitinteger :units_per_carton, nullable: true, description: 'How many units fill one carton.'diff --git a/spree/api/app/controllers/spree/api/v3/seller/stock_locations_controller.rb b/spree/api/app/controllers/spree/api/v3/seller/stock_locations_controller.rbindex 4a970c2add..7c5189114c 100644--- a/spree/api/app/controllers/spree/api/v3/seller/stock_locations_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/seller/stock_locations_controller.rb@@ -37,7 +37,7 @@ module Spreedescription: 'Categorizes the location.'boolean :propagate_all_variants, :backorderable_defaultstring :address1, :address2, :city, :zipcode, :phone, :company, nullable: true- string :country_code, nullable: true, example: 'US', description: 'ISO-3166 alpha-2 country code.'+ country :country_code, nullable: true, example: 'US', description: 'ISO-3166 alpha-2 country code.'string :state_code, nullable: true, example: 'OR',description: "State or province abbreviation, resolved against the selected country's states."string :state_name, nullable: true, description: "Free-text state for countries that don't have a states list."diff --git a/spree/api/app/controllers/spree/api/v3/store/carts_controller.rb b/spree/api/app/controllers/spree/api/v3/store/carts_controller.rbindex 9196ab616d..a03ff14888 100644--- a/spree/api/app/controllers/spree/api/v3/store/carts_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/store/carts_controller.rb@@ -22,7 +22,8 @@ module Spreestring :email, format: :email, example: '[email protected]'string :customer_note, example: 'Leave at door'id :market_id- string :currency, :locale+ currency :currency+ string :localeid :shipping_address_id, description: 'An existing address to ship to.', example: 'addr_abc123'id :billing_address_id, description: 'An existing address to bill.', example: 'addr_def456'id :preferred_stock_location_iddiff --git a/spree/api/app/request_schemas/spree/api/v3/address_request_schema.rb b/spree/api/app/request_schemas/spree/api/v3/address_request_schema.rbindex cc6f5e7590..4c6abb19bd 100644--- a/spree/api/app/request_schemas/spree/api/v3/address_request_schema.rb+++ b/spree/api/app/request_schemas/spree/api/v3/address_request_schema.rb@@ -7,7 +7,7 @@ module Spreeclass AddressRequestSchema < Spree::Api::V3::RequestSchemastring(*(AddressParams::ADDRESS_KEYS - %i[country_code state_code state_name zipcode]))string :zipcode, description: 'Legacy spelling of `postal_code`; send only one of the two.'- string :country_code, example: 'US', description: 'ISO 3166-1 alpha-2 code, such as `US`.'+ country :country_code, example: 'US', description: 'ISO 3166-1 alpha-2 code, such as `US`.'string :state_code, example: 'NY', description: 'The state or province abbreviation, such as `NY`.'string :state_name, description: 'For countries without states in the database.'enddiff --git a/spree/api/app/request_schemas/spree/api/v3/admin/catalog_order_minimum_request_schema.rb b/spree/api/app/request_schemas/spree/api/v3/admin/catalog_order_minimum_request_schema.rbindex 92ceb0db8f..b7ac4e338c 100644--- a/spree/api/app/request_schemas/spree/api/v3/admin/catalog_order_minimum_request_schema.rb+++ b/spree/api/app/request_schemas/spree/api/v3/admin/catalog_order_minimum_request_schema.rb@@ -6,7 +6,7 @@ module Spreeclass CatalogOrderMinimumRequestSchema < Spree::Api::V3::RequestSchemapublishes 'CatalogOrderMinimumParams'- string :currency, example: 'USD', description: 'ISO 4217 code. Required on create; one minimum per currency.'+ currency :currency, example: 'USD', description: 'ISO 4217 code. Required on create; one minimum per currency.'decimal :amount, example: '500.00'endenddiff --git a/spree/api/app/request_schemas/spree/api/v3/admin/price_list_price_request_schema.rb b/spree/api/app/request_schemas/spree/api/v3/admin/price_list_price_request_schema.rbindex 20da20484e..42baefd316 100644--- a/spree/api/app/request_schemas/spree/api/v3/admin/price_list_price_request_schema.rb+++ b/spree/api/app/request_schemas/spree/api/v3/admin/price_list_price_request_schema.rb@@ -8,7 +8,7 @@ module Spreeid :id, description: 'Updates this price row. Without it, the row upserts on `(variant_id, currency, min_quantity)`.'id :variant_id, example: 'variant_xY9'- string :currency, example: 'USD'+ currency :currency, example: 'USD'integer :min_quantity, description: "The rung of the variant's ladder. Omit for the bottom rung."decimal :amount, :compare_at_amount, nullable: true, example: '19.99'enddiff --git a/spree/api/app/request_schemas/spree/api/v3/price_request_schema.rb b/spree/api/app/request_schemas/spree/api/v3/price_request_schema.rbindex 55f6d5a453..45eddc9fd2 100644--- a/spree/api/app/request_schemas/spree/api/v3/price_request_schema.rb+++ b/spree/api/app/request_schemas/spree/api/v3/price_request_schema.rb@@ -5,7 +5,7 @@ module Spreeclass PriceRequestSchema < Spree::Api::V3::RequestSchemapublishes 'PriceParams'- string :currency, required: true, example: 'USD'+ currency :currency, required: true, example: 'USD'decimal :amount, required: true, example: '29.99',description: 'A canonical decimal string (`"1234.56"`: period decimal, no grouping). The API does not parse localized input.'decimal :compare_at_amount, nullable: true, example: '39.99'diff --git a/spree/api/app/request_schemas/spree/api/v3/store/address_request_schema.rb b/spree/api/app/request_schemas/spree/api/v3/store/address_request_schema.rbindex cdf774e8e4..80293f6973 100644--- a/spree/api/app/request_schemas/spree/api/v3/store/address_request_schema.rb+++ b/spree/api/app/request_schemas/spree/api/v3/store/address_request_schema.rb@@ -6,7 +6,7 @@ module Spree# their own address book. Not published on its own.class AddressRequestSchema < Spree::Api::V3::RequestSchemastring :first_name, :last_name, :company, :address1, :address2, :city, :postal_code, :phone- string :country_code, example: 'US', description: 'ISO 3166-1 alpha-2 country code, such as `US` or `DE`.'+ country :country_code, example: 'US', description: 'ISO 3166-1 alpha-2 country code, such as `US` or `DE`.'string :state_code, example: 'NY', description: 'ISO 3166-2 subdivision code without the country prefix, such as `CA` or `NY`.'string :state_name, description: 'The state name, for countries without predefined states.'string :country_iso, deprecated: 'Use `country_code`. Removed in 6.1.'diff --git a/spree/api/app/request_schemas/spree/api/v3/variant_request_schema.rb b/spree/api/app/request_schemas/spree/api/v3/variant_request_schema.rbindex 2ed4ba1306..38a725258f 100644--- a/spree/api/app/request_schemas/spree/api/v3/variant_request_schema.rb+++ b/spree/api/app/request_schemas/spree/api/v3/variant_request_schema.rb@@ -7,11 +7,12 @@ module Spreeclass VariantRequestSchema < Spree::Api::V3::RequestSchemastring :sku, :barcodedecimal :cost_price, nullable: true- string :cost_currency+ currency :cost_currencynumber :weight, :height, :width, :depth, nullable: truestring :weight_unit, enum: Spree::Variant::WEIGHT_UNITSstring :dimensions_unit, enum: Spree::Variant::DIMENSION_UNITS- string :hs_code, :country_of_origin, :customs_description+ string :hs_code, :customs_description+ country :country_of_origininteger :minimum_order_quantity, :order_multiple, nullable: truestring :purchase_unitinteger :units_per_carton, nullable: true, description: 'How many units fill one carton.'diff --git a/spree/api/app/serializers/spree/api/v3/address_serializer.rb b/spree/api/app/serializers/spree/api/v3/address_serializer.rbindex 809d4e50fc..9aa2ca51e4 100644--- a/spree/api/app/serializers/spree/api/v3/address_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/address_serializer.rb@@ -8,7 +8,7 @@ module Spreecompany: [:string, nullable: true], state_code: [:string, nullable: true],state_abbr: [:string, nullable: true, deprecated: 'Use `state_code`. Removed in 6.1.'],state_name: [:string, nullable: true],- state_text: [:string, nullable: true], country_code: :string,+ state_text: [:string, nullable: true], country_code: [:string, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],country_iso: [:string, deprecated: 'Use `country_code`. Removed in 6.1.'],country_name: :string,quick_checkout: :boolean, is_default_billing: :boolean, is_default_shipping: :boolean,diff --git a/spree/api/app/serializers/spree/api/v3/admin/address_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/address_serializer.rbindex e2be644b88..c5d9871994 100644--- a/spree/api/app/serializers/spree/api/v3/admin/address_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/address_serializer.rb@@ -3,6 +3,9 @@ module Spreemodule V3module Adminclass AddressSerializer < V3::AddressSerializer+ # The Store API keeps these deprecated names until 6.1.+ %i[state_abbr country_iso].each { |key| _attributes.delete(key) }+typelize customer_id: [:string, nullable: true],owner_id: [:string, nullable: true],owner_type: [:string, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/admin/cart_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/cart_serializer.rbindex e98ef6f0a3..002d574ff6 100644--- a/spree/api/app/serializers/spree/api/v3/admin/cart_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/cart_serializer.rb@@ -14,7 +14,7 @@ module Spreeclass CartSerializer < V3::CartSerializerwithout_formatted_money- %i[fulfillments payments payment_methods gift_card discounts fees].each { |key| _attributes.delete(key) }+ %i[fulfillments payments payment_methods gift_card discounts fees number].each { |key| _attributes.delete(key) }typelize completed_at: [:string, nullable: true]diff --git a/spree/api/app/serializers/spree/api/v3/admin/catalog_order_minimum_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/catalog_order_minimum_serializer.rbindex 29dfc57902..ba78f27552 100644--- a/spree/api/app/serializers/spree/api/v3/admin/catalog_order_minimum_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/catalog_order_minimum_serializer.rb@@ -5,7 +5,7 @@ module Spree# The least a whole order must come to under a catalog's agreement,# in one currency.class CatalogOrderMinimumSerializer < V3::BaseSerializer- typelize currency: :string+ typelize currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode']attributes :currency, created_at: :iso8601, updated_at: :iso8601diff --git a/spree/api/app/serializers/spree/api/v3/admin/catalog_price_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/catalog_price_serializer.rbindex 40f5bdc281..aa5953605b 100644--- a/spree/api/app/serializers/spree/api/v3/admin/catalog_price_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/catalog_price_serializer.rb@@ -17,7 +17,7 @@ module Spree_attributes.delete(:id)typelize id: 'string | null', label: 'string | null', sku: 'string | null',- currency: :string, source: [:string, enum: Spree::CatalogPrice::SOURCES], break_count: :number+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'], source: [:string, enum: Spree::CatalogPrice::SOURCES], break_count: :number# The variant this prices, so a row can name what it is showing —# a product's variants can be priced differently, and one figurediff --git a/spree/api/app/serializers/spree/api/v3/admin/commission_line_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/commission_line_serializer.rbindex cd1831d433..1384191a13 100644--- a/spree/api/app/serializers/spree/api/v3/admin/commission_line_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/commission_line_serializer.rb@@ -21,9 +21,9 @@ module Spreecommission_rate_id: 'string | null',kind: [:string, enum: Spree::CommissionRate::KINDS],taxability_reason: 'string | null',- country_code: 'string | null',+ country_code: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],state_code: 'string | null',- currency: :string+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode']# The treatment, in Spree::TaxLine's vocabulary — a seller's invoice# has to explain why its fee was taxed the way it was, and thediff --git a/spree/api/app/serializers/spree/api/v3/admin/market_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/market_serializer.rbindex 639a0fbff2..8310bda094 100644--- a/spree/api/app/serializers/spree/api/v3/admin/market_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/market_serializer.rb@@ -3,6 +3,9 @@ module Spreemodule V3module Adminclass MarketSerializer < V3::MarketSerializer+ # The Store API keeps this deprecated name until 6.1.+ _attributes.delete(:country_isos)+typelize tax_provider: [:string, nullable: true, comment: 'Tax provider; null uses the store default. Built-in: internal. Provider gems register more.']attributes created_at: :iso8601, updated_at: :iso8601diff --git a/spree/api/app/serializers/spree/api/v3/admin/payment_method_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/payment_method_serializer.rbindex 262df961b7..482399ecca 100644--- a/spree/api/app/serializers/spree/api/v3/admin/payment_method_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/payment_method_serializer.rb@@ -4,7 +4,6 @@ module Spreemodule Adminclass PaymentMethodSerializer < V3::PaymentMethodSerializertypelize active: :boolean,- auto_capture: [:boolean, nullable: true],capture_method: "'checkout' | 'on_dispatch' | 'manual' | null",resolved_capture_method: "'checkout' | 'on_dispatch' | 'manual'",storefront_visible: :boolean,@@ -18,7 +17,7 @@ module Spree# Null capture_method means the method inherits from its store;# resolved_capture_method is what actually applies, so the dashboard# can show the inherited value.- attributes :metadata, :active, :auto_capture, :capture_method, :resolved_capture_method,+ attributes :metadata, :active, :capture_method, :resolved_capture_method,:storefront_visible, :position,created_at: :iso8601, updated_at: :iso8601diff --git a/spree/api/app/serializers/spree/api/v3/admin/payment_split_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/payment_split_serializer.rbindex 3e081c9ec8..fe5636356c 100644--- a/spree/api/app/serializers/spree/api/v3/admin/payment_split_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/payment_split_serializer.rb@@ -11,7 +11,7 @@ module SpreeAMOUNTS = %i[authorized_amount captured_amount refunded_amount claimed_amountnet_captured_amount refundable_amount].freeze- typelize currency: :string,+ typelize currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],payment_id: :string,payment_number: 'string | null',order_id: :string,diff --git a/spree/api/app/serializers/spree/api/v3/admin/purchase_order_item_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/purchase_order_item_serializer.rbindex 0ac41ebc69..a6366700db 100644--- a/spree/api/app/serializers/spree/api/v3/admin/purchase_order_item_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/purchase_order_item_serializer.rb@@ -9,7 +9,7 @@ module Spreequantity_rejected: :number,quantity_over: :number,outstanding: :number,- currency: 'string | null',+ currency: [:string, nullable: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],purchase_order_id: 'string | null',thumbnail_url: 'string | null',product_id: 'string | null',diff --git a/spree/api/app/serializers/spree/api/v3/admin/purchase_order_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/purchase_order_serializer.rbindex 76bc308635..e5e2698c88 100644--- a/spree/api/app/serializers/spree/api/v3/admin/purchase_order_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/purchase_order_serializer.rb@@ -7,7 +7,7 @@ module Spreeclass PurchaseOrderSerializer < V3::BaseSerializertypelize number: :string,status: :string,- currency: :string,+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],reference: 'string | null',notes: 'string | null',supplier_id: 'string | null',diff --git a/spree/api/app/serializers/spree/api/v3/admin/seller_balance_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/seller_balance_serializer.rbindex 4369a4d2fe..c813b00410 100644--- a/spree/api/app/serializers/spree/api/v3/admin/seller_balance_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/seller_balance_serializer.rb@@ -6,8 +6,8 @@ module Spree# operator. A computed value rather than a record, so it carries no id.class SellerBalanceSerializer < V3::BaseSerializertypelize seller_id: :string,- currency: :string,- settlement_currency: :string,+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],+ settlement_currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],converted: :boolean,earned: :string,payable: :string,diff --git a/spree/api/app/serializers/spree/api/v3/admin/seller_payout_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/seller_payout_serializer.rbindex 05df02fa6c..3c26066c5c 100644--- a/spree/api/app/serializers/spree/api/v3/admin/seller_payout_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/seller_payout_serializer.rb@@ -13,7 +13,7 @@ module Spreestatus: [:string, enum: Spree::SellerPayout.statuses, enum_type_name: 'SellerPayoutStatus'],provider: [:string, comment: 'Payout provider. Built-in: system. Provider gems register more (e.g. stripe).'],amount: :string,- currency: :string,+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],reference: 'string | null',period_start: 'string | null',period_end: 'string | null',diff --git a/spree/api/app/serializers/spree/api/v3/admin/seller_transfer_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/seller_transfer_serializer.rbindex 5704ed5689..92170c61f6 100644--- a/spree/api/app/serializers/spree/api/v3/admin/seller_transfer_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/seller_transfer_serializer.rb@@ -18,9 +18,9 @@ module Spreestatus: [:string, enum: Spree::SellerTransfer.statuses, enum_type_name: 'SellerTransferStatus'],provider: [:string, comment: 'Payout provider. Built-in: system. Provider gems register more (e.g. stripe).'],amount: :string,- currency: :string,+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],settled_amount: 'string | null',- settled_currency: 'string | null',+ settled_currency: [:string, nullable: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],converted: :boolean,reference: 'string | null'diff --git a/spree/api/app/serializers/spree/api/v3/admin/shipping_label_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/shipping_label_serializer.rbindex 6d4578d3f4..ef730a2b3e 100644--- a/spree/api/app/serializers/spree/api/v3/admin/shipping_label_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/shipping_label_serializer.rb@@ -14,7 +14,7 @@ module Spreecarrier_name: [:string, nullable: true],service: [:string, nullable: true],tracking_number: [:string, nullable: true],- currency: [:string, nullable: true],+ currency: [:string, nullable: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],format: [:string, nullable: true],external_id: [:string, nullable: true],integration_id: [:string, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/admin/store_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/store_serializer.rbindex a88945c941..5912eca23d 100644--- a/spree/api/app/serializers/spree/api/v3/admin/store_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/store_serializer.rb@@ -4,9 +4,9 @@ module Spreemodule Adminclass StoreSerializer < V3::BaseSerializertypelize name: :string, url: :string, code: :string, api_url: :string,- default_currency: :string, default_locale: :string,+ default_currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'], default_locale: :string,default_country_code: [:string, nullable: true],- supported_currencies: [:string, multi: true],+ supported_currencies: [:string, multi: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],supported_locales: [:string, multi: true],available_locales: [:string, multi: true],logo_url: [:string, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/admin/supplier_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/supplier_serializer.rbindex 94b718407c..891a410cdb 100644--- a/spree/api/app/serializers/spree/api/v3/admin/supplier_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/supplier_serializer.rb@@ -15,7 +15,7 @@ module Spreecity: 'string | null',state_name: 'string | null',state_code: 'string | null',- country_code: 'string | null',+ country_code: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],postal_code: 'string | null',purchase_orders_count: :number,can_be_deleted: :boolean,diff --git a/spree/api/app/serializers/spree/api/v3/admin/tax_exemption_certificate_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/tax_exemption_certificate_serializer.rbindex 1cc48e7b87..3ef06059c5 100644--- a/spree/api/app/serializers/spree/api/v3/admin/tax_exemption_certificate_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/tax_exemption_certificate_serializer.rb@@ -8,7 +8,7 @@ module Spreetypelize certificate_number: :string, reason_code: :string, status: [:string, enum: Spree::TaxExemptionCertificate.statuses, enum_type_name: 'TaxExemptionCertificateStatus'],issuing_authority: [:string, nullable: true],company_id: :string,- country_code: [:string, nullable: true], state_code: [:string, nullable: true],+ country_code: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'], state_code: [:string, nullable: true],active: :boolean, lapsed: :boolean, can_be_deleted: :boolean,document_filename: [:string, nullable: true],document_byte_size: ['number | null'],diff --git a/spree/api/app/serializers/spree/api/v3/admin/tax_line_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/tax_line_serializer.rbindex 3ed0d8113b..b61d2f5e7d 100644--- a/spree/api/app/serializers/spree/api/v3/admin/tax_line_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/tax_line_serializer.rb@@ -7,7 +7,7 @@ module Spreetypelize amount: [:string, nullable: false],provider_id: [:string, nullable: true], metadata: ['Record<string, unknown>', nullable: true],- taxability_reason: [:string, nullable: true], country_code: [:string, nullable: true],+ taxability_reason: [:string, nullable: true], country_code: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],state_code: [:string, nullable: true], data: ['Record<string, unknown>', nullable: true],original_tax_line_id: [:string, nullable: true]diff --git a/spree/api/app/serializers/spree/api/v3/admin/tax_rate_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/tax_rate_serializer.rbindex 37ebc4bb7e..aa03100882 100644--- a/spree/api/app/serializers/spree/api/v3/admin/tax_rate_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/tax_rate_serializer.rb@@ -10,7 +10,7 @@ module Spreeshow_rate_in_label: :boolean,tax_category_id: [:string, nullable: true],store_id: [:string, nullable: true],- country_code: [:string, nullable: true],+ country_code: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],state_code: [:string, nullable: true],metadata: ['Record<string, unknown>', nullable: true],deleted_at: [:string, nullable: true]diff --git a/spree/api/app/serializers/spree/api/v3/admin/variant_serializer.rb b/spree/api/app/serializers/spree/api/v3/admin/variant_serializer.rbindex af721f376c..de0bd419bb 100644--- a/spree/api/app/serializers/spree/api/v3/admin/variant_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/admin/variant_serializer.rb@@ -12,14 +12,14 @@ module Spreetypelize product_name: :string,position: :number, tax_category_id: [:string, nullable: true],- cost_price: [:string, nullable: true], cost_currency: [:string, nullable: true],+ cost_price: [:string, nullable: true], cost_currency: [:string, nullable: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],barcode: [:string, nullable: true],available_stock: [:number, nullable: true],reserved_quantity: :number, total_on_hand: [:number, nullable: true],preorderable: :boolean, preorder_ships_at: [:string, nullable: true],backorder_limit: [:number, nullable: true],hs_code: [:string, nullable: true],- country_of_origin: [:string, nullable: true],+ country_of_origin: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],customs_description: [:string, nullable: true],deleted_at: [:string, nullable: true],delivery_profile_id: [:string, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/cart_serializer.rb b/spree/api/app/serializers/spree/api/v3/cart_serializer.rbindex 724e0f4bfc..ae2231a36b 100644--- a/spree/api/app/serializers/spree/api/v3/cart_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/cart_serializer.rb@@ -6,7 +6,7 @@ module Spreeclass CartSerializer < BaseSerializertypelize number: [:string, deprecated: 'Use `id`; a cart has no order number. Removed in 6.1.'], current_step: :string, completed_steps: 'string[]', token: :string,email: [:string, nullable: true], customer_note: [:string, nullable: true],- market_id: [:string, nullable: true], channel_id: [:string, nullable: true], currency: :string,+ market_id: [:string, nullable: true], channel_id: [:string, nullable: true], currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],locale: [:string, nullable: true], total_quantity: :number, coupon_code: [:string, nullable: true],preferred_stock_location_id: [:string, nullable: true], company_id: [:string, nullable: true],company_name: [:string, nullable: true], po_number: [:string, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/country_serializer.rb b/spree/api/app/serializers/spree/api/v3/country_serializer.rbindex 44d97f8720..49b35e53ed 100644--- a/spree/api/app/serializers/spree/api/v3/country_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/country_serializer.rb@@ -5,7 +5,7 @@ module Spreeinclude Alba::Resourceinclude Typelizer::DSL- typelize iso: :string, iso3: :string, name: :string,+ typelize iso: [:string, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'], iso3: :string, name: :string,states_required: :boolean, zipcode_required: :boolean,market: [:Market, nullable: true]diff --git a/spree/api/app/serializers/spree/api/v3/currency_serializer.rb b/spree/api/app/serializers/spree/api/v3/currency_serializer.rbindex 6324ff34ae..474d6ed257 100644--- a/spree/api/app/serializers/spree/api/v3/currency_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/currency_serializer.rb@@ -5,7 +5,8 @@ module Spreeinclude Alba::Resourceinclude Typelizer::DSL- typelize iso_code: :string, name: :string, symbol: :string, decimal_places: :number+ typelize iso_code: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'], name: :string, symbol: :string,+ decimal_places: :numberattributes :iso_code, :name, :symboldiff --git a/spree/api/app/serializers/spree/api/v3/delivery_zone_member_serializer.rb b/spree/api/app/serializers/spree/api/v3/delivery_zone_member_serializer.rbindex 5aae34d489..305ae1c645 100644--- a/spree/api/app/serializers/spree/api/v3/delivery_zone_member_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/delivery_zone_member_serializer.rb@@ -2,7 +2,7 @@ module Spreemodule Apimodule V3class DeliveryZoneMemberSerializer < BaseSerializer- typelize member_type: [:string, enum: Spree::DeliveryZoneMember::MEMBER_TYPES], country_code: [:string, nullable: true],+ typelize member_type: [:string, enum: Spree::DeliveryZoneMember::MEMBER_TYPES], country_code: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],country_name: [:string, nullable: true],state_code: [:string, nullable: true], state_name: [:string, nullable: true],postal_code_prefix: [:string, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/gift_card_batch_serializer.rb b/spree/api/app/serializers/spree/api/v3/gift_card_batch_serializer.rbindex 94cc7b7721..babff0042d 100644--- a/spree/api/app/serializers/spree/api/v3/gift_card_batch_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/gift_card_batch_serializer.rb@@ -4,7 +4,7 @@ module Spreemodule Apimodule V3class GiftCardBatchSerializer < BaseSerializer- typelize codes_count: :number, currency: [:string, nullable: true],+ typelize codes_count: :number, currency: [:string, nullable: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],prefix: [:string, nullable: true], expires_at: [:string, nullable: true],created_by_id: [:string, nullable: true]diff --git a/spree/api/app/serializers/spree/api/v3/gift_card_serializer.rb b/spree/api/app/serializers/spree/api/v3/gift_card_serializer.rbindex c3c543d3db..2c3fec16e5 100644--- a/spree/api/app/serializers/spree/api/v3/gift_card_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/gift_card_serializer.rb@@ -5,7 +5,7 @@ module Spreetypelize code: :string,status: [:string, enum: Spree::GiftCard::DISPLAY_STATUSES, enum_type_name: 'GiftCardStatus'],display_amount: [:string, nullable: true], display_amount_used: [:string, nullable: true],- display_amount_remaining: [:string, nullable: true], currency: :string,+ display_amount_remaining: [:string, nullable: true], currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],expires_at: [:string, nullable: true], redeemed_at: [:string, nullable: true], expired: :boolean,active: :booleandiff --git a/spree/api/app/serializers/spree/api/v3/import_serializer.rb b/spree/api/app/serializers/spree/api/v3/import_serializer.rbindex 5053a721f9..015772baac 100644--- a/spree/api/app/serializers/spree/api/v3/import_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/import_serializer.rb@@ -6,8 +6,6 @@ module Spreeclass ImportSerializer < BaseSerializertypelize number: :string,type: [:string, nullable: true, comment: 'Import type. Built-in: products, product_translations, customers, price_list_prices. Extensions may register more.'], status: [:string, enum: Spree::Import.statuses, enum_type_name: 'ImportStatus'],- owner_type: [:string, nullable: true, deprecated: 'Read `store_id` / `seller_id`. Removed in 6.1.'],- owner_id: [:string, nullable: true, deprecated: 'Read `store_id` / `seller_id`. Removed in 6.1.'],store_id: [:string, nullable: true], seller_id: [:string, nullable: true],user_id: [:string, nullable: true], rows_count: :number@@ -27,17 +25,6 @@ module Spree# whose it is. A null `seller_id` means the operator's own.prefixed_id_attributes :store, :seller- # @deprecated Read `store_id` / `seller_id` — removed in 6.1. Emitted- # from the pair above rather than the dropped columns, so a client- # still reading them sees the same answer.- attribute :owner_type do |import|- Spree::Base.polymorphic_api_type(import.seller_id.present? ? 'Spree::Seller' : 'Spree::Store')- end-- attribute :owner_id do |import|- (import.seller || import.store)&.prefixed_id- end-prefixed_id_attributes :userendenddiff --git a/spree/api/app/serializers/spree/api/v3/line_item_serializer.rb b/spree/api/app/serializers/spree/api/v3/line_item_serializer.rbindex d966ac4ca8..e12de914a8 100644--- a/spree/api/app/serializers/spree/api/v3/line_item_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/line_item_serializer.rb@@ -2,7 +2,7 @@ module Spreemodule Apimodule V3class LineItemSerializer < BaseSerializer- typelize variant_id: :string, quantity: :number, currency: :string, name: :string, slug: :string,+ typelize variant_id: :string, quantity: :number, currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'], name: :string, slug: :string,options_text: :string, compare_at_amount: [:string, nullable: true],thumbnail_url: [:string, nullable: true], preorder: :boolean,preorder_ships_at: [:string, nullable: true], seller_id: [:string, nullable: true]diff --git a/spree/api/app/serializers/spree/api/v3/market_serializer.rb b/spree/api/app/serializers/spree/api/v3/market_serializer.rbindex e1c9589fee..ed7f432063 100644--- a/spree/api/app/serializers/spree/api/v3/market_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/market_serializer.rb@@ -2,10 +2,10 @@ module Spreemodule Apimodule V3class MarketSerializer < BaseSerializer- typelize name: :string, currency: :string,+ typelize name: :string, currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],default_locale: :string,supported_locales: [:string, multi: true],- country_codes: [:string, multi: true],+ country_codes: [:string, multi: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],country_isos: [:string, multi: true, deprecated: 'Use `country_codes`. Removed in 6.1.'],tax_inclusive: :boolean,default: :booleandiff --git a/spree/api/app/serializers/spree/api/v3/order_group_serializer.rb b/spree/api/app/serializers/spree/api/v3/order_group_serializer.rbindex d923470b51..88f42e2463 100644--- a/spree/api/app/serializers/spree/api/v3/order_group_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/order_group_serializer.rb@@ -8,7 +8,7 @@ module Spree# their order history shows them — with the per-seller orders nested# inside it, each carrying its own items, delivery and tracking.class OrderGroupSerializer < BaseSerializer- typelize number: :string, email: [:string, nullable: true], currency: :string,+ typelize number: :string, email: [:string, nullable: true], currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],fulfillment_status: [:string, nullable: true, enum: Spree::Order::FULFILLMENT_STATUSES],payment_status: [:string, nullable: true, enum: Spree::Order::PAYMENT_STATUSES],completed_at: [:string, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/order_serializer.rb b/spree/api/app/serializers/spree/api/v3/order_serializer.rbindex db79b7e385..e749bb550f 100644--- a/spree/api/app/serializers/spree/api/v3/order_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/order_serializer.rb@@ -9,7 +9,7 @@ module Spreechannel_id: [:string, nullable: true], company_id: [:string, nullable: true],company_name: [:string, nullable: true], po_number: [:string, nullable: true],po_document_filename: [:string, nullable: true], po_document_byte_size: ['number | null'],- currency: :string, locale: [:string, nullable: true], total_quantity: :number,+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'], locale: [:string, nullable: true], total_quantity: :number,coupon_code: [:string, nullable: true],fulfillment_status: [:string, nullable: true, enum: Spree::Order::FULFILLMENT_STATUSES],payment_status: [:string, nullable: true, enum: Spree::Order::PAYMENT_STATUSES],diff --git a/spree/api/app/serializers/spree/api/v3/payment_session_serializer.rb b/spree/api/app/serializers/spree/api/v3/payment_session_serializer.rbindex 6846478dad..65db93d499 100644--- a/spree/api/app/serializers/spree/api/v3/payment_session_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/payment_session_serializer.rb@@ -2,7 +2,7 @@ module Spreemodule Apimodule V3class PaymentSessionSerializer < BaseSerializer- typelize status: [:string, enum: Spree::PaymentSession.statuses, enum_type_name: 'PaymentSessionStatus'], currency: :string,+ typelize status: [:string, enum: Spree::PaymentSession.statuses, enum_type_name: 'PaymentSessionStatus'], currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],external_id: :string, external_data: 'Record<string, unknown>',expires_at: [:string, nullable: true], customer_external_id: [:string, nullable: true],payment_method_id: :string, order_id: [:string, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/price_history_serializer.rb b/spree/api/app/serializers/spree/api/v3/price_history_serializer.rbindex d0cb2d5a9c..83922dd90e 100644--- a/spree/api/app/serializers/spree/api/v3/price_history_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/price_history_serializer.rb@@ -5,7 +5,7 @@ module Spreemodule V3class PriceHistorySerializer < BaseSerializertypelize display_amount: :string,- currency: :string,+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],recorded_at: :stringattributes :currencydiff --git a/spree/api/app/serializers/spree/api/v3/price_serializer.rb b/spree/api/app/serializers/spree/api/v3/price_serializer.rbindex 89f73b000e..b4da48b358 100644--- a/spree/api/app/serializers/spree/api/v3/price_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/price_serializer.rb@@ -7,7 +7,7 @@ module Spreeclass PriceSerializer < BaseSerializertypelize display_amount: [:string, nullable: true],display_compare_at_amount: [:string, nullable: true],- currency: [:string, nullable: true],+ currency: [:string, nullable: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],price_list_id: [:string, nullable: true]attributes :currencydiff --git a/spree/api/app/serializers/spree/api/v3/product_filter_price_range_serializer.rb b/spree/api/app/serializers/spree/api/v3/product_filter_price_range_serializer.rbindex 5e18f0a6bc..d6aea58223 100644--- a/spree/api/app/serializers/spree/api/v3/product_filter_price_range_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/product_filter_price_range_serializer.rb@@ -6,7 +6,7 @@ module Spreetype: "'price_range'",min: :string,max: :string,- currency: :string+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode']attributes :id, :typediff --git a/spree/api/app/serializers/spree/api/v3/seller/address_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/address_serializer.rbnew file mode 100644index 0000000000..19af3a5d96--- /dev/null+++ b/spree/api/app/serializers/spree/api/v3/seller/address_serializer.rb@@ -0,0 +1,12 @@+module Spree+ module Api+ module V3+ module Seller+ class AddressSerializer < V3::AddressSerializer+ # The Store API keeps these deprecated names until 6.1.+ %i[state_abbr country_iso].each { |key| _attributes.delete(key) }+ end+ end+ end+ end+enddiff --git a/spree/api/app/serializers/spree/api/v3/seller/balance_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/balance_serializer.rbindex 7a6ad441bc..828d5f1ff3 100644--- a/spree/api/app/serializers/spree/api/v3/seller/balance_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/seller/balance_serializer.rb@@ -6,8 +6,8 @@ module Spree## A computed value rather than a record, so it carries no id.class BalanceSerializer < V3::BaseSerializer- typelize currency: :string,- settlement_currency: :string,+ typelize currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],+ settlement_currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],converted: :boolean,earned: :string,payable: :string,diff --git a/spree/api/app/serializers/spree/api/v3/seller/order_line_item_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/order_line_item_serializer.rbindex 7533cf031f..f51f0e7144 100644--- a/spree/api/app/serializers/spree/api/v3/seller/order_line_item_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/seller/order_line_item_serializer.rb@@ -12,7 +12,7 @@ module Spree# this branch's generated types.class OrderLineItemSerializer < V3::BaseSerializertypelize name: :string, sku: [:string, nullable: true], options_text: [:string, nullable: true],- quantity: :number, currency: :string, variant_id: [:string, nullable: true],+ quantity: :number, currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'], variant_id: [:string, nullable: true],thumbnail_url: [:string, nullable: true]attributes :name, :options_text, :quantity, :currencydiff --git a/spree/api/app/serializers/spree/api/v3/seller/order_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/order_serializer.rbindex 3fe4c2ee6a..79e5895998 100644--- a/spree/api/app/serializers/spree/api/v3/seller/order_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/seller/order_serializer.rb@@ -21,7 +21,7 @@ module Spree# the one contact detail that lets a marketplace's customer be taken# off it, and it is not needed to pack, post or invoice.class OrderSerializer < V3::BaseSerializer- typelize number: :string, customer_note: [:string, nullable: true], currency: :string,+ typelize number: :string, customer_note: [:string, nullable: true], currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],total_quantity: :number,fulfillment_status: [:string, nullable: true, enum: Spree::Order::FULFILLMENT_STATUSES],payment_status: [:string, nullable: true, enum: Spree::Order::PAYMENT_STATUSES],@@ -89,8 +89,8 @@ module Spreemany :payment_splits, resource: proc { Spree.api.seller_payment_split_serializer },if: proc { expand?('payment_splits') }many :fulfillments, resource: proc { Spree.api.seller_fulfillment_serializer }- one :shipping_address, resource: proc { Spree.api.address_serializer }- one :billing_address, resource: proc { Spree.api.address_serializer }+ one :shipping_address, resource: proc { Spree.api.seller_address_serializer }+ one :billing_address, resource: proc { Spree.api.seller_address_serializer }endendenddiff --git a/spree/api/app/serializers/spree/api/v3/seller/payment_split_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/payment_split_serializer.rbindex e729f87b9b..83752b387e 100644--- a/spree/api/app/serializers/spree/api/v3/seller/payment_split_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/seller/payment_split_serializer.rb@@ -13,7 +13,7 @@ module SpreeAMOUNTS = %i[authorized_amount captured_amount refunded_amount claimed_amountnet_captured_amount refundable_amount].freeze- typelize currency: :string,+ typelize currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],authorized_amount: :string,captured_amount: :string,refunded_amount: :string,diff --git a/spree/api/app/serializers/spree/api/v3/seller/payout_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/payout_serializer.rbindex 4a202fc54c..7ac000b9ad 100644--- a/spree/api/app/serializers/spree/api/v3/seller/payout_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/seller/payout_serializer.rb@@ -5,7 +5,7 @@ module Spree# One settlement to this seller, as the seller reads it.class PayoutSerializer < V3::BaseSerializertypelize status: :string,- currency: :string,+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],provider: [:string, comment: 'Payout provider. Built-in: system. Provider gems register more (e.g. stripe).'],amount: :string,reference: 'string | null',diff --git a/spree/api/app/serializers/spree/api/v3/seller/profile_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/profile_serializer.rbindex 51f039413d..4fdd12052e 100644--- a/spree/api/app/serializers/spree/api/v3/seller/profile_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/seller/profile_serializer.rb@@ -15,8 +15,8 @@ module Spreeterms_accepted_at: [:string, nullable: true],on_holiday: :boolean, sellable: :boolean,products_count: :number,- default_currency: :string,- supported_currencies: [:string, multi: true],+ default_currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],+ supported_currencies: [:string, multi: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],timezone: [:string, nullable: true]attributes :timezone,@@ -60,11 +60,11 @@ module Spreeendone :billing_address,- resource: proc { Spree.api.address_serializer },+ resource: proc { Spree.api.seller_address_serializer },if: proc { |seller| seller.billing_address.present? }one :returns_address,- resource: proc { Spree.api.address_serializer },+ resource: proc { Spree.api.seller_address_serializer },if: proc { |seller| seller.returns_address.present? }endenddiff --git a/spree/api/app/serializers/spree/api/v3/seller/transfer_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/transfer_serializer.rbindex 18072a521c..104391fd5b 100644--- a/spree/api/app/serializers/spree/api/v3/seller/transfer_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/seller/transfer_serializer.rb@@ -11,11 +11,11 @@ module Spreeclass TransferSerializer < V3::BaseSerializertypelize kind: :string,status: :string,- currency: :string,+ currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],provider: [:string, comment: 'Payout provider. Built-in: system. Provider gems register more (e.g. stripe).'],amount: :string,settled_amount: 'string | null',- settled_currency: 'string | null',+ settled_currency: [:string, nullable: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],converted: :boolean,reference: 'string | null',order_id: 'string | null',diff --git a/spree/api/app/serializers/spree/api/v3/seller/variant_serializer.rb b/spree/api/app/serializers/spree/api/v3/seller/variant_serializer.rbindex 309c30415e..3071e074fe 100644--- a/spree/api/app/serializers/spree/api/v3/seller/variant_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/seller/variant_serializer.rb@@ -14,7 +14,7 @@ module Spreetypelize position: :number,cost_price: [:string, nullable: true],- cost_currency: [:string, nullable: true],+ cost_currency: [:string, nullable: true, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode'],barcode: [:string, nullable: true],available_stock: [:number, nullable: true],total_on_hand: [:number, nullable: true],@@ -22,7 +22,7 @@ module Spreepreorder_ships_at: [:string, nullable: true],backorder_limit: [:number, nullable: true],hs_code: [:string, nullable: true],- country_of_origin: [:string, nullable: true],+ country_of_origin: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],customs_description: [:string, nullable: true],minimum_order_quantity: ['number | null'], order_multiple: ['number | null'],purchase_unit: [:string, nullable: true, enum: Spree::Variant::PURCHASE_UNITS],diff --git a/spree/api/app/serializers/spree/api/v3/stock_location_serializer.rb b/spree/api/app/serializers/spree/api/v3/stock_location_serializer.rbindex 743599160d..c48f6d762f 100644--- a/spree/api/app/serializers/spree/api/v3/stock_location_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/stock_location_serializer.rb@@ -3,7 +3,7 @@ module Spreemodule V3class StockLocationSerializer < BaseSerializertypelize name: :string, address1: [:string, nullable: true], city: [:string, nullable: true],- zipcode: [:string, nullable: true], country_code: [:string, nullable: true],+ zipcode: [:string, nullable: true], country_code: [:string, nullable: true, enum: Spree::IsoData.country_codes, enum_type_name: 'CountryCode'],country_name: [:string, nullable: true], state_code: [:string, nullable: true],state_text: [:string, nullable: true],pickup_ready_in_minutes: [:number, nullable: true],diff --git a/spree/api/app/serializers/spree/api/v3/store_credit_serializer.rb b/spree/api/app/serializers/spree/api/v3/store_credit_serializer.rbindex d1212efe17..44ebe60cca 100644--- a/spree/api/app/serializers/spree/api/v3/store_credit_serializer.rb+++ b/spree/api/app/serializers/spree/api/v3/store_credit_serializer.rb@@ -2,7 +2,7 @@ module Spreemodule Apimodule V3class StoreCreditSerializer < BaseSerializer- typelize currency: :string+ typelize currency: [:string, enum: Spree::Money::Rounding::CURRENCY_CODES, enum_type_name: 'CurrencyCode']money_attributes :amount, :amount_used, :amount_remaining, :display_amount,:display_amount_used, :display_amount_remainingdiff --git a/spree/api/app/services/spree/api/v3/request_schema.rb b/spree/api/app/services/spree/api/v3/request_schema.rbindex f789937e4d..371dd3ea2b 100644--- a/spree/api/app/services/spree/api/v3/request_schema.rb+++ b/spree/api/app/services/spree/api/v3/request_schema.rb@@ -40,7 +40,19 @@ module Spreedate: { type: :string, format: :date },datetime: { type: :string, format: :'date-time' },id: { type: :string },- any: {}+ any: {},+ # ISO codes, from the closed lists below.+ country: { type: :string },+ currency: { type: :string }+ }.freeze++ # The ISO lists a `country` or `currency` field takes, published once+ # per API as a named component — the same `CountryCode` and+ # `CurrencyCode` types the serializers declare, so a value read from+ # a response is the type a request takes.+ CODE_LISTS = {+ country: ['CountryCode', -> { Spree::IsoData.country_codes }],+ currency: ['CurrencyCode', -> { Spree::Money::Rounding::CURRENCY_CODES }]}.freezeACTIONS = %i[create update].freeze@@ -242,6 +254,20 @@ module Spreeend.uniqend+ # The ISO code lists this schema's fields reach, nested ones included,+ # as the components they publish.+ #+ # @return [Hash{String => Hash}]+ def code_lists+ fields.each_value.each_with_object({}) do |field, lists|+ lists.merge!(field.schema.code_lists) if field.schema+ next unless CODE_LISTS.key?(field.kind)++ name, values = CODE_LISTS[field.kind]+ lists[name] = { type: :string, enum: values.call }+ end+ end+def shape?(schema)schema.name.present?end@@ -313,6 +339,8 @@ module Spreeenddef item_schema(field)+ return { '$ref': "#/components/schemas/#{CODE_LISTS[field.kind].first}" } if CODE_LISTS.key?(field.kind)+if field.schemareturn { '$ref': "#/components/schemas/#{field.schema.name}" } if shape?(field.schema)diff --git a/spree/api/config/initializers/typelizer.rb b/spree/api/config/initializers/typelizer.rbindex 6dcf9eafd7..09e1284962 100644--- a/spree/api/config/initializers/typelizer.rb+++ b/spree/api/config/initializers/typelizer.rb@@ -75,7 +75,7 @@ Rails.application.config.after_initialize do# serializer this branch inherits references them, so their types still# have to exist in the package.store_nested_for_seller = %w[- Address Category CustomField OptionType OptionValue Seller+ Category CustomField OptionType OptionValue Seller].to_setconfig.writer(:seller) do |c|diff --git a/spree/api/lib/spree/api/dependencies.rb b/spree/api/lib/spree/api/dependencies.rbindex d9a48384de..c2aad4b1fa 100644--- a/spree/api/lib/spree/api/dependencies.rb+++ b/spree/api/lib/spree/api/dependencies.rb@@ -45,7 +45,7 @@ module Spreeemail_template_sample_record file_upload file_upload_target].freezeSELLER_SERIALIZERS =- %i[profile policy team_member account invitation invitation_acceptance_link product product_type+ %i[address profile policy team_member account invitation invitation_acceptance_link product product_typedelivery_profile delivery_method delivery_method_rule delivery_zone variant media stock_level orderorder_line_item fulfillment fulfillment_item delivery delivery_rate shipping_label returnreturn_line_item exchange exchange_line_item claim claim_line_item reason package_type stock_locationdiff --git a/spree/api/lib/typelizer/open_enums.rb b/spree/api/lib/typelizer/open_enums.rbindex 0c02e9fe78..a58b6155c0 100644--- a/spree/api/lib/typelizer/open_enums.rb+++ b/spree/api/lib/typelizer/open_enums.rb@@ -7,10 +7,18 @@ module Typelizer# open, and the OpenAPI property becomes an open enum, so a client generated# from either still accepts an added value while every built-in value stays# documented and autocompletable.+ #+ # ISO lists are the exception: a named type several serializers and the+ # request types share, but closed, since nothing outside the standard can+ # add a country or a currency.module OpenEnums+ CLOSED_TYPE_NAMES = %w[CountryCode CurrencyCode].freeze+module Propertydef enum_definition(...)definition = super+ return definition if CLOSED_TYPE_NAMES.include?(enum_type_name)+definition && "#{definition} | (string & {})"endend@@ -20,6 +28,7 @@ module Typelizerdef inline_schema(definition, property, openapi_version:)return super unless property.enum_type_name && property.enum.is_a?(Array) && !property.multi+ return super if CLOSED_TYPE_NAMES.include?(property.enum_type_name)open = { anyOf: [{ type: :string, enum: property.enum.compact }, { type: :string }] }apply_nullable(open, property, openapi_version: openapi_version)diff --git a/spree/api/spec/controllers/spree/api/v3/admin/delivery_methods_controller_spec.rb b/spree/api/spec/controllers/spree/api/v3/admin/delivery_methods_controller_spec.rbindex 83de1bffd7..230320324e 100644--- a/spree/api/spec/controllers/spree/api/v3/admin/delivery_methods_controller_spec.rb+++ b/spree/api/spec/controllers/spree/api/v3/admin/delivery_methods_controller_spec.rb@@ -261,15 +261,6 @@ RSpec.describe Spree::Api::V3::Admin::DeliveryMethodsController, type: :controllexpect(delivery_method.reload.calculator).to eq(calculator)end- it 'still accepts the pre-6.0 calculator parameters for one release' do- expect(Spree::Deprecation).to receive(:warn).with(/`calculator_type` and `calculator_preferences` parameters are deprecated/)-- patch :update, params: { id: delivery_method.prefixed_id, calculator_preferences: { amount: '42' } }, as: :json-- expect(response).to have_http_status(:ok)- expect(delivery_method.reload.calculator.preferred_amount).to eq(42)- end-it 'stores per-currency amounts' dopatch :update, params: {id: delivery_method.prefixed_id,diff --git a/spree/api/spec/controllers/spree/api/v3/admin/store_controller_spec.rb b/spree/api/spec/controllers/spree/api/v3/admin/store_controller_spec.rbindex b2eba55533..50ebd0cbb6 100644--- a/spree/api/spec/controllers/spree/api/v3/admin/store_controller_spec.rb+++ b/spree/api/spec/controllers/spree/api/v3/admin/store_controller_spec.rb@@ -385,15 +385,9 @@ RSpec.describe Spree::Api::V3::Admin::StoreController, type: :controller docontext 'with a pre-6.0 preferred_ key' dolet(:params) { { preferred_guest_checkout: false } }- it 'still saves it for one release, with a deprecation warning' do- expect(Spree::Deprecation).to receive(:warn).with(/`preferred_guest_checkout` parameter is deprecated/)-- subject-+ it 'ignores it: the Admin API takes the setting under its own name' do+ expect { subject }.not_to(change { store.reload.preferred_guest_checkout })expect(response).to have_http_status(:ok)- expect(store.reload.preferred_guest_checkout).to eq(false)- expect(json_response).to include('guest_checkout' => false)- expect(json_response).not_to have_key('preferred_guest_checkout')endenddiff --git a/spree/api/spec/serializers/spree/api/v3/import_serializer_spec.rb b/spree/api/spec/serializers/spree/api/v3/import_serializer_spec.rbindex aab41f9d12..592c433287 100644--- a/spree/api/spec/serializers/spree/api/v3/import_serializer_spec.rb+++ b/spree/api/spec/serializers/spree/api/v3/import_serializer_spec.rb@@ -11,7 +11,7 @@ RSpec.describe Spree::Api::V3::ImportSerializer doit 'includes all expected attributes' doexpect(subject.keys).to match_array(%w[- id number type status store_id seller_id owner_type owner_id user_id rows_count+ id number type status store_id seller_id user_id rows_countcreated_at updated_at])end@@ -21,23 +21,12 @@ RSpec.describe Spree::Api::V3::ImportSerializer doexpect(subject['seller_id']).to be_nilend- # `owner` shipped in 5.6 and is emitted from the new pair until 6.1, so the- # two must agree.- context 'the deprecated owner pair' do- it 'names the store for an operator\'s import' do- expect(subject['owner_type']).to eq('store')- expect(subject['owner_id']).to eq(import.store.prefixed_id)- end-- context 'when a seller ran it' do- let(:seller) { create(:seller, store: store) }- let(:import) { create(:import, store: store, seller: seller) }+ context 'when a seller ran it' do+ let(:seller) { create(:seller, store: store) }+ let(:import) { create(:import, store: store, seller: seller) }- it 'names the seller' do- expect(subject['seller_id']).to eq(seller.prefixed_id)- expect(subject['owner_type']).to eq('seller')- expect(subject['owner_id']).to eq(seller.prefixed_id)- end+ it 'returns the seller' do+ expect(subject['seller_id']).to eq(seller.prefixed_id)endenddiff --git a/spree/api/spec/services/spree/api/v3/request_schema_spec.rb b/spree/api/spec/services/spree/api/v3/request_schema_spec.rbindex e2077be248..115605ef1a 100644--- a/spree/api/spec/services/spree/api/v3/request_schema_spec.rb+++ b/spree/api/spec/services/spree/api/v3/request_schema_spec.rb@@ -105,6 +105,22 @@ RSpec.describe Spree::Api::V3::RequestSchema doexpect(schema.permit_list).to eq([:country_iso])end+ it 'references the shared ISO code lists and publishes them' do+ schema = described_class.new do+ country :country_code+ currency :currencies, array: true+ end++ expect(schema.json_schema[:properties]).to eq(+ country_code: { '$ref': '#/components/schemas/CountryCode' },+ currencies: { type: :array, items: { '$ref': '#/components/schemas/CurrencyCode' } }+ )+ expect(schema.code_lists['CountryCode'][:enum]).to include('US', 'DE')+ expect(schema.code_lists['CountryCode'][:enum]).not_to include('AQ')+ expect(schema.code_lists['CurrencyCode'][:enum]).to include('USD', 'EUR')+ expect(schema.permit_list).to eq([:country_code, { currencies: [] }])+ end+it 'sends decimals as canonical strings' doexpect(price.json_schema[:properties][:amount]).to include(type: :string, format: :decimal)enddiff --git a/spree/api/spec/support/request_body_helper.rb b/spree/api/spec/support/request_body_helper.rbindex cf95c36405..37362d0b0f 100644--- a/spree/api/spec/support/request_body_helper.rb+++ b/spree/api/spec/support/request_body_helper.rb@@ -24,6 +24,7 @@ module RequestBodyHelpername = schema.component_name(action)register_request_schema(name, schema.json_schema(action.in?(%i[create update]) ? action : nil))schema.shapes.each { |shape| register_request_schema(shape.name, shape.json_schema) }+ schema.code_lists.each { |list_name, definition| register_request_schema(list_name, definition) }parameter name: :body, in: :body, required: required, schema: { '$ref': "#/components/schemas/#{name}" }enddiff --git a/spree/core/lib/spree/iso_data.rb b/spree/core/lib/spree/iso_data.rbindex e02c1760b7..fe413d10f0 100644--- a/spree/core/lib/spree/iso_data.rb+++ b/spree/core/lib/spree/iso_data.rb@@ -88,6 +88,13 @@ module Spreefreezeend+ # The alpha-2 code of every orderable country, the closed list the API+ # types publish as `CountryCode`.+ # @return [Array<String>]+ def country_codes+ @country_codes ||= countries.map(&:alpha2).sort.freeze+ end+# @param code [String] alpha-2 or alpha-3 code, any case# @return [ISO3166::Country, nil]def country(code)diff --git a/spree/core/lib/spree/money.rb b/spree/core/lib/spree/money.rbindex ca9a066a8e..ddeeaaadeb 100644--- a/spree/core/lib/spree/money.rb+++ b/spree/core/lib/spree/money.rb@@ -32,6 +32,10 @@ module Spree# without decimals), so Spree reads its own copy.EXPONENTS = JSON.parse(File.read(File.expand_path('../../config/currency_exponents.json', __dir__))).freeze+ # Every currency Spree knows, the closed list the API types publish as+ # `CurrencyCode`.+ CURRENCY_CODES = EXPONENTS.keys.sort.freeze+# Unit prices may be quoted below the minor unit ("0.0125" USD); amounts# that change hands never are.UNIT_PRICE_DECIMALS = 4