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
Simplify the integrations and EasyPost surfaces after review
Damian Legawiece24aabe7ee07
diff --git a/docs/api-reference/store.yaml b/docs/api-reference/store.yamlindex 9b78435d20..0b3fc96f6e 100644--- a/docs/api-reference/store.yaml+++ b/docs/api-reference/store.yaml@@ -87,16 +87,16 @@ paths:content:application/json:example:- token: eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoxLCJ1c2VyX3R5cGUiOiJjdXN0b21lciIsImp0aSI6IjBkZTg2OGNmLWNlMDEtNDcwOC1hNDQ3LTljY2NmN2Y2YWQ0ZiIsImlzcyI6InNwcmVlIiwiYXVkIjoic3RvcmVfYXBpIiwiZXhwIjoxNzg2MDUwMDI4fQ.VSB4GdlZ4DdHpTv1BLClvkDVrERRK6Lrhnt_D9JlQpU- refresh_token: 6d3hptkexdAW6X5unJnXcmqq+ token: eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoxLCJ1c2VyX3R5cGUiOiJjdXN0b21lciIsImp0aSI6IjYzM2NhZjY2LTZiNTEtNDIyNC04ZmMzLThiYjkzNDMyZDc2NyIsImlzcyI6InNwcmVlIiwiYXVkIjoic3RvcmVfYXBpIiwiZXhwIjoxNzg2MDU0OTk2fQ.S3HJ83S7T5kbrWkfBC-C5rSgVfLDIcwLMh47WaXfevg+ refresh_token: Ty8ogGw7sNrepnCK4phQdyLHuser:id: cust_UkLWZg9DAJemail: [email protected]- first_name: Arnette- last_name: Kshlerin+ first_name: Katharyn+ last_name: Erdmanphone:accepts_email_marketing: false- full_name: Arnette Kshlerin+ full_name: Katharyn Erdmanavailable_store_credit_total: '0'display_available_store_credit_total: "$0.00"addresses: []@@ -194,16 +194,16 @@ paths:content:application/json:example:- token: eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoxLCJ1c2VyX3R5cGUiOiJjdXN0b21lciIsImp0aSI6IjFjNjRiMzEzLTlhMTktNGQ2NS05ZTkyLWMzYzY5MjAyNGZkNyIsImlzcyI6InNwcmVlIiwiYXVkIjoic3RvcmVfYXBpIiwiZXhwIjoxNzg2MDUwMDI4fQ.5D-Hww_cj0Cv7ZMh-ZORhZk-aSwbgrpwsJnpxDjHqVc- refresh_token: gQGXtEnLD7ouERpuwZFLJwms+ token: eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoxLCJ1c2VyX3R5cGUiOiJjdXN0b21lciIsImp0aSI6IjVmMTJjYzgzLTg4ZDgtNDUxYi1iZTBjLTQxZTQ1MzBjM2Y5ZiIsImlzcyI6InNwcmVlIiwiYXVkIjoic3RvcmVfYXBpIiwiZXhwIjoxNzg2MDU0OTk2fQ.Mt_Ylb3iYdyoYHXk-6_4pLVKWDWs9BqtcURsKUxDl38+ refresh_token: fdxpy9GLQunmaUyveBToGuAtuser:id: cust_UkLWZg9DAJemail: [email protected]- first_name: Risa- last_name: Kuhlman+ first_name: Paula+ last_name: Keelingphone:accepts_email_marketing: false- full_name: Risa Kuhlman+ full_name: Paula Keelingavailable_store_credit_total: '0'display_available_store_credit_total: "$0.00"addresses: []@@ -393,16 +393,16 @@ paths:content:application/json:example:- token: eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoxLCJ1c2VyX3R5cGUiOiJjdXN0b21lciIsImp0aSI6ImU5NzRkYjQ2LWMzMzYtNGFhMS1hNWViLTljYzAyMTY1ZjQ0OCIsImlzcyI6InNwcmVlIiwiYXVkIjoic3RvcmVfYXBpIiwiZXhwIjoxNzg2MDUwMDMxfQ.l4wNhDZUCgt3SKQqYrmqHuaqa-K45Ent3xlcEqqjWaM- refresh_token: MQ55xStoAAKK9BhLjzKLn8S3+ token: eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoxLCJ1c2VyX3R5cGUiOiJjdXN0b21lciIsImp0aSI6IjQwNDU1ZDliLWQ2ZjgtNGMzYS1hNDRhLTlhNGE0MDkxMDU0ZCIsImlzcyI6InNwcmVlIiwiYXVkIjoic3RvcmVfYXBpIiwiZXhwIjoxNzg2MDU0OTk5fQ.HSrfj0ouhhoYX7eedeI3ofv50q_eUX9g_CaTwevZgNI+ refresh_token: qcvD1mNsWY7K3mZM4khDkV2suser:id: cust_UkLWZg9DAJemail: [email protected]- first_name: Alejandra- last_name: Goodwin+ first_name: Debera+ last_name: Prosaccophone:accepts_email_marketing: false- full_name: Alejandra Goodwin+ full_name: Debera Prosaccoavailable_store_credit_total: '0'display_available_store_credit_total: "$0.00"addresses: []@@ -879,8 +879,8 @@ paths:example:data:- id: prod_UkLWZg9DAJ- name: Product 1293745- slug: product-1293745+ name: Product 1293884+ slug: product-1293884meta_title:meta_description:meta_keywords:@@ -892,27 +892,21 @@ paths:in_stock: falsebackorderable: trueavailable: true- description: Cupiditate autem eaque dolorum maxime. Id rerum minima- quas iste ullam voluptatem. Quas praesentium inventore sed non- tenetur eaque laboriosam quae. Nesciunt asperiores explicabo nobis- similique fugit aperiam consectetur omnis. Officiis inventore- cumque sed dolorum quaerat accusantium. Nulla ipsam cumque accusantium- libero ut error. Maiores laboriosam excepturi optio illo perspiciatis- placeat. Nulla maxime ipsa esse sunt assumenda necessitatibus.- Dolor quod aliquam reprehenderit consequuntur nemo doloremque- quae voluptatem. Quis exercitationem vero dolorem voluptatem.- Possimus vero quibusdam magnam nemo. Sapiente alias modi totam- reiciendis impedit tempora quae. Numquam quod explicabo qui id- commodi repellendus. Dolorum nulla earum quos esse aspernatur- quaerat exercitationem optio. Nulla provident illum illo debitis- in. Minima magni eum corporis tempora. Excepturi itaque nihil- doloremque facere. Odit praesentium nemo cumque magnam. Autem- quo vero saepe in animi sequi id voluptas.+ description: Consequatur ratione suscipit pariatur ad ea voluptas+ earum magni. Libero eligendi nobis ipsa provident. Molestiae voluptatibus+ est enim perferendis saepe. Alias similique ipsum debitis minima+ ullam. Dignissimos consequuntur quas omnis earum officiis facere+ voluptatem optio. Repudiandae dolor veritatis inventore iure consequuntur+ ab necessitatibus. Voluptatem asperiores odit facere cumque officia+ quis. Dolores amet magni illo saepe voluptate est. Quasi eum quisquam+ voluptatum illum nulla voluptate. Labore beatae assumenda reiciendis+ ratione provident architecto. Qui accusantium quaerat vel quia+ dolorum. Magnam unde illum laborum vitae est adipisci officiis.+ Voluptates velit quae facilis ad.description_html: |-- Cupiditate autem eaque dolorum maxime. Id rerum minima quas iste ullam voluptatem. Quas praesentium inventore sed non tenetur eaque laboriosam quae. Nesciunt asperiores explicabo nobis similique fugit aperiam consectetur omnis. Officiis inventore cumque sed dolorum quaerat accusantium.- Nulla ipsam cumque accusantium libero ut error. Maiores laboriosam excepturi optio illo perspiciatis placeat. Nulla maxime ipsa esse sunt assumenda necessitatibus. Dolor quod aliquam reprehenderit consequuntur nemo doloremque quae voluptatem. Quis exercitationem vero dolorem voluptatem.- Possimus vero quibusdam magnam nemo. Sapiente alias modi totam reiciendis impedit tempora quae. Numquam quod explicabo qui id commodi repellendus. Dolorum nulla earum quos esse aspernatur quaerat exercitationem optio.- Nulla provident illum illo debitis in. Minima magni eum corporis tempora. Excepturi itaque nihil doloremque facere. Odit praesentium nemo cumque magnam. Autem quo vero saepe in animi sequi id voluptas.+ Consequatur ratione suscipit pariatur ad ea voluptas earum magni. Libero eligendi nobis ipsa provident. Molestiae voluptatibus est enim perferendis saepe. Alias similique ipsum debitis minima ullam. Dignissimos consequuntur quas omnis earum officiis facere voluptatem optio.+ Repudiandae dolor veritatis inventore iure consequuntur ab necessitatibus. Voluptatem asperiores odit facere cumque officia quis. Dolores amet magni illo saepe voluptate est. Quasi eum quisquam voluptatum illum nulla voluptate.+ Labore beatae assumenda reiciendis ratione provident architecto. Qui accusantium quaerat vel quia dolorum. Magnam unde illum laborum vitae est adipisci officiis. Voluptates velit quae facilis ad.default_variant_id: variant_UkLWZg9DAJthumbnail_url:tags: []@@ -1067,8 +1061,8 @@ paths:example:data:- id: prod_UkLWZg9DAJ- name: Product 1717279- slug: product-1717279+ name: Product 1712060+ slug: product-1712060meta_title:meta_description:meta_keywords:@@ -1097,8 +1091,8 @@ paths:price_list_id:original_price:- id: prod_gbHJdmfrXB- name: Product 1721476- slug: product-1721476+ name: Product 1729277+ slug: product-1729277meta_title:meta_description:meta_keywords:@@ -1110,28 +1104,24 @@ paths:in_stock: falsebackorderable: trueavailable: true- description: Maiores expedita eaque omnis quibusdam totam saepe- velit. Sequi cum rem nesciunt maxime tenetur occaecati voluptatum.- Laborum maxime illum fugit mollitia voluptas hic. Dolorem occaecati- deleniti nostrum doloribus eius dolorum. Voluptate delectus ratione- sapiente ex porro qui amet. Praesentium placeat quibusdam aperiam- perferendis. Eaque nisi beatae dicta natus. Molestiae vel iusto- ducimus exercitationem fugiat reiciendis fugit laudantium. Unde- optio corrupti officia pariatur asperiores. Modi accusantium incidunt- natus repellendus. Neque quaerat animi sequi dolores. Nesciunt- sint delectus consequatur minima quia ipsum. Aspernatur voluptatum- expedita perferendis incidunt nisi aperiam enim culpa. Id amet- magni magnam nostrum culpa. Deleniti praesentium omnis perferendis- velit sapiente voluptates harum qui. Accusantium ducimus repellendus- quis voluptates. Molestiae similique laboriosam nostrum deleniti- quas. Doloribus saepe minus cumque repellendus quis nulla. Eveniet- vero debitis excepturi suscipit ex.+ description: Optio nam possimus illum dolorem. Explicabo reiciendis+ quibusdam cum impedit. Corrupti fugit necessitatibus sunt blanditiis+ aliquid. Facere illo enim doloribus consequatur fugit veritatis+ vitae. Soluta nulla odit fuga temporibus occaecati id excepturi+ exercitationem. Nostrum quas suscipit quos et. Unde optio reiciendis+ nisi molestiae corporis. Explicabo soluta rem quas aliquid suscipit+ officiis impedit. Nemo optio architecto unde aliquam. Pariatur+ quas voluptas explicabo ullam error blanditiis. Veniam temporibus+ tempore ratione culpa aliquam debitis. Facilis quasi itaque voluptate+ voluptatem et accusantium deserunt libero. Sapiente recusandae+ at ipsum rem aspernatur deleniti exercitationem. Aut excepturi+ natus asperiores consequuntur ipsa consequatur consectetur aliquid.+ Fugit enim magnam explicabo tenetur placeat sit quas.description_html: |-- Maiores expedita eaque omnis quibusdam totam saepe velit. Sequi cum rem nesciunt maxime tenetur occaecati voluptatum. Laborum maxime illum fugit mollitia voluptas hic.- Dolorem occaecati deleniti nostrum doloribus eius dolorum. Voluptate delectus ratione sapiente ex porro qui amet. Praesentium placeat quibusdam aperiam perferendis. Eaque nisi beatae dicta natus. Molestiae vel iusto ducimus exercitationem fugiat reiciendis fugit laudantium.- Unde optio corrupti officia pariatur asperiores. Modi accusantium incidunt natus repellendus. Neque quaerat animi sequi dolores. Nesciunt sint delectus consequatur minima quia ipsum.- Aspernatur voluptatum expedita perferendis incidunt nisi aperiam enim culpa. Id amet magni magnam nostrum culpa. Deleniti praesentium omnis perferendis velit sapiente voluptates harum qui.- Accusantium ducimus repellendus quis voluptates. Molestiae similique laboriosam nostrum deleniti quas. Doloribus saepe minus cumque repellendus quis nulla. Eveniet vero debitis excepturi suscipit ex.+ Optio nam possimus illum dolorem. Explicabo reiciendis quibusdam cum impedit. Corrupti fugit necessitatibus sunt blanditiis aliquid. Facere illo enim doloribus consequatur fugit veritatis vitae. Soluta nulla odit fuga temporibus occaecati id excepturi exercitationem.+ Nostrum quas suscipit quos et. Unde optio reiciendis nisi molestiae corporis. Explicabo soluta rem quas aliquid suscipit officiis impedit.+ Nemo optio architecto unde aliquam. Pariatur quas voluptas explicabo ullam error blanditiis. Veniam temporibus tempore ratione culpa aliquam debitis. Facilis quasi itaque voluptate voluptatem et accusantium deserunt libero.+ Sapiente recusandae at ipsum rem aspernatur deleniti exercitationem. Aut excepturi natus asperiores consequuntur ipsa consequatur consectetur aliquid. Fugit enim magnam explicabo tenetur placeat sit quas.default_variant_id: variant_EfhxLZ9ck8thumbnail_url:tags: []@@ -1233,8 +1223,8 @@ paths:application/json:example:id: prod_UkLWZg9DAJ- name: Product 1992650- slug: product-1992650+ name: Product 1991632+ slug: product-1991632meta_title:meta_description:meta_keywords:@@ -1268,7 +1258,7 @@ paths:amount_in_cents: 999currency: USDdisplay_amount: "$9.99"- recorded_at: '2026-07-22T20:00:38Z'+ recorded_at: '2026-07-22T21:23:25Z'schema:"$ref": "#/components/schemas/Product"'404':@@ -1518,7 +1508,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_gbHJdmfrXB- token: 6GA9htpQSwBLyRQqQtFiHwqu+ token: iCHQQ5KfWpotpHBPfT824iewemail:customer_note:currency: USD@@ -1577,8 +1567,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1044222- slug: product-1044222+ name: Product 1046744+ slug: product-1046744options_text: ''price: '10.0'display_price: "$10.00"@@ -1623,7 +1613,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: pfApFbFnA4kmgpW1N7FvKvya+ token: CgBJcEqeVXCjEWWDm5fgLDueemail:customer_note:currency: USD@@ -1682,8 +1672,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1032723- slug: product-1032723+ name: Product 1034344+ slug: product-1034344options_text: ''price: '10.0'display_price: "$10.00"@@ -1801,7 +1791,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: PCzs3UFMyGPxfwdMvWAJfJn5+ token: Zn5iDgkaTdbxAJih5Y7rC8Zbemail:customer_note:currency: USD@@ -1966,7 +1956,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: DQKqbtCs4PhL3PreGoyvhdHh+ token: RFu3uFWQZq99faER1GsdR178email:customer_note:currency: USD@@ -1974,7 +1964,7 @@ paths:total_quantity: 0warnings:- code: line_item_removed- message: Product 1086243 was removed because it was sold out+ message: Product 1084226 was removed because it was sold outline_item_id: li_UkLWZg9DAJvariant_id: variant_UkLWZg9DAJcoupon_code:@@ -2116,7 +2106,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: 7p9c963q5GNJ13LuXkmfWu4j+ token: ZwfB3BVxgst3rLXgMVgePsPhemail:customer_note: Leave at doorcurrency: USD@@ -2171,8 +2161,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1093949- slug: product-1093949+ name: Product 1091309+ slug: product-1091309options_text: ''price: '10.0'display_price: "$10.00"@@ -2391,8 +2381,8 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: 2gD1iT5aqvfD2BPke1CDz1w7- email: [email protected]+ token: bs8WZCnWGAuqVhqsY3M4XWkG+ email: [email protected]customer_note:currency: USDlocale: en@@ -2443,8 +2433,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1114288- slug: product-1114288+ name: Product 1115936+ slug: product-1115936options_text: ''price: '10.0'display_price: "$10.00"@@ -2598,8 +2588,8 @@ paths:market_id: mkt_UkLWZg9DAJcart_id: cart_UkLWZg9DAJchannel_id: ch_UkLWZg9DAJ- number: R191958576- email: [email protected]+ number: R867845175+ email: [email protected]customer_note:currency: USDlocale: en@@ -2607,7 +2597,7 @@ paths:coupon_code:fulfillment_status: backorderpayment_status: paid- completed_at: '2026-08-06T20:00:29.491Z'+ completed_at: '2026-08-06T21:23:17.119Z'item_total: '10.0'display_item_total: "$10.00"adjustment_total: '0.0'@@ -2639,8 +2629,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1141222- slug: product-1141222+ name: Product 1145148+ slug: product-1145148options_text: ''price: '10.0'display_price: "$10.00"@@ -2665,7 +2655,7 @@ paths:digital_links: []fulfillments:- id: ful_gbHJdmfrXB- number: F38651412087+ number: F70644662656tracking:tracking_url:pickup_point_data:@@ -2699,7 +2689,7 @@ paths:stock_location:id: sloc_UkLWZg9DAJstate_abbr: NY- name: Breann Adams+ name: Ivory Herzogaddress1: 1600 Pennsylvania Ave NWcity: Washingtonzipcode: '20500'@@ -2734,8 +2724,8 @@ paths:payments:- id: py_UkLWZg9DAJpayment_method_id: pm_UkLWZg9DAJ- response_code: BGS-7d2a61b1b4ea- number: PE1VU5GQ+ response_code: BGS-93e5f4ef1a8c+ number: PU5ZLT9Wamount: '20.0'display_amount: "$20.00"status: completed@@ -2891,7 +2881,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: Spfca52dVJxNC81KgRt98L8B+ token: uS94XqX81yFrEEKn6JQJCvxEemail:customer_note:currency: USD@@ -2949,8 +2939,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1407127- slug: product-1407127+ name: Product 1406303+ slug: product-1406303options_text: ''price: '10.0'display_price: "$10.00"@@ -3079,7 +3069,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: HeJSt7e8jy1aS5TSAxvi8NW1+ token: hv9DXhBA6MVUvNZ2kz1kArdtemail:customer_note:currency: USD@@ -3134,8 +3124,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1429879- slug: product-1429879+ name: Product 1424175+ slug: product-1424175options_text: ''price: '10.0'display_price: "$10.00"@@ -3253,8 +3243,8 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: kPHkdphQo6EVkdFhGfvLwDri- email: [email protected]+ token: fZWhU21oexA2Vnorct81gz2m+ email: [email protected]customer_note:currency: USDlocale: en@@ -3302,8 +3292,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1448093- slug: product-1448093+ name: Product 1444840+ slug: product-1444840options_text: ''price: '10.0'display_price: "$10.00"@@ -3328,7 +3318,7 @@ paths:digital_links: []fulfillments:- id: ful_UkLWZg9DAJ- number: F66418645657+ number: F45266719132tracking:tracking_url:pickup_point_data:@@ -3362,7 +3352,7 @@ paths:stock_location:id: sloc_UkLWZg9DAJstate_abbr: NY- name: Aleisha Lueilwitz+ name: Tammie Maggioaddress1: 1600 Pennsylvania Ave NWcity: Washingtonzipcode: '20500'@@ -3520,7 +3510,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: bubZvz5855SDyA8pq7GYnhBP+ token: ZK3Ymznq9wQnQ9hixSajWgmZemail:customer_note:currency: USD@@ -3571,8 +3561,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1467016- slug: product-1467016+ name: Product 146347+ slug: product-146347options_text: ''price: '10.0'display_price: "$10.00"@@ -3599,8 +3589,8 @@ paths:payments:- id: py_UkLWZg9DAJpayment_method_id: pm_UkLWZg9DAJ- response_code: 1-SC-20260806200033816233- number: PVDN5XQU+ response_code: 1-SC-20260806212321038075+ number: P7KZMW32amount: '10.0'display_amount: "$10.00"status: checkout@@ -3756,7 +3746,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: tMi9SYDpd8kr4cC8wKNbJahB+ token: Pof8uEpDCwgaZqs535fqgE52email:customer_note:currency: USD@@ -3811,8 +3801,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1503448- slug: product-1503448+ name: Product 1507026+ slug: product-1507026options_text: ''price: '10.0'display_price: "$10.00"@@ -3839,8 +3829,8 @@ paths:payments:- id: py_UkLWZg9DAJpayment_method_id: pm_UkLWZg9DAJ- response_code: 1-SC-20260806200034112725- number: PX4N6TC6+ response_code: 1-SC-20260806212321312544+ number: PUGSJPVIamount: '10.0'display_amount: "$10.00"status: invalid@@ -3947,7 +3937,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: 5bbcSKGPt33LMt6F4CYFFd8x+ token: SLp424chgmp6byRhyQPMnGTwemail:customer_note:currency: USD@@ -3955,10 +3945,10 @@ paths:total_quantity: 2warnings:- code: delivery_unavailable- message: Product 1535677 cannot be delivered to the selected address+ message: Product 1535952 cannot be delivered to the selected addressline_item_id: li_UkLWZg9DAJ- code: delivery_unavailable- message: Product 1543365 cannot be delivered to the selected address+ message: Product 1547922 cannot be delivered to the selected addressline_item_id: li_gbHJdmfrXBcoupon_code:item_total: '29.99'@@ -4008,8 +3998,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1535677- slug: product-1535677+ name: Product 1535952+ slug: product-1535952options_text: ''price: '10.0'display_price: "$10.00"@@ -4038,8 +4028,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1543365- slug: product-1543365+ name: Product 1547922+ slug: product-1547922options_text: ''price: '19.99'display_price: "$19.99"@@ -4177,7 +4167,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: Ni8unDeRnMKZ5eUJUyMogLcg+ token: Mr8MToaLaNNQX5wXkeN2VATDemail:customer_note:currency: USD@@ -4228,8 +4218,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1572993- slug: product-1572993+ name: Product 1576784+ slug: product-1576784options_text: ''price: '10.0'display_price: "$10.00"@@ -4347,7 +4337,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: iC4uNgdEnbzKByoziaenx8KN+ token: qKS1SKdPrScyjYziNFxPQ5Pyemail:customer_note:currency: USD@@ -4487,9 +4477,9 @@ paths:id: ps_gbHJdmfrXBstatus: pendingcurrency: USD- external_id: bogus_d3dfdfcfab797783cbecda80+ external_id: bogus_393605e30d52883b694469c6external_data:- client_secret: bogus_secret_82e1e635f4bfe00d+ client_secret: bogus_secret_210f8cd4897822c8customer_external_id:expires_at:amount: '10.0'@@ -4588,7 +4578,7 @@ paths:id: ps_UkLWZg9DAJstatus: pendingcurrency: USD- external_id: bogus_7ad6829a2d8226ba4df091a5+ external_id: bogus_b170b787fbab467d1ee1cb89external_data:client_secret: secret_123customer_external_id:@@ -4651,7 +4641,7 @@ paths:id: ps_UkLWZg9DAJstatus: pendingcurrency: USD- external_id: bogus_e8c3573e9cb8269caf5319f8+ external_id: bogus_d058a54788dafad23a52b2d9external_data:client_secret: secret_123customer_external_id:@@ -4754,7 +4744,7 @@ paths:id: ps_UkLWZg9DAJstatus: completedcurrency: USD- external_id: bogus_cd1d22009b4961215403e778+ external_id: bogus_33259edd732bf6e7cfba178eexternal_data:client_secret: secret_123customer_external_id:@@ -4853,7 +4843,7 @@ paths:id: py_UkLWZg9DAJpayment_method_id: pm_UkLWZg9DAJresponse_code:- number: P7XCQ5CM+ number: PC9EFNG1amount: '10.0'display_amount: "$10.00"status: checkout@@ -4962,7 +4952,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: PjdYqMVFwXpq9TJTd5wVHQp9+ token: 1fDMKxrFq6rHjPuQHtM4e3X7email:customer_note:currency: USD@@ -5013,8 +5003,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 2197781- slug: product-2197781+ name: Product 2191111+ slug: product-2191111options_text: ''price: '10.0'display_price: "$10.00"@@ -5041,8 +5031,8 @@ paths:payments:- id: py_UkLWZg9DAJpayment_method_id: pm_UkLWZg9DAJ- response_code: 1-SC-20260806200040057449- number: P30ZVFZS+ response_code: 1-SC-20260806212326945319+ number: PLKYN7E8amount: '10.0'display_amount: "$10.00"status: checkout@@ -5162,7 +5152,7 @@ paths:channel_id: ch_UkLWZg9DAJpreferred_stock_location_id:number: cart_UkLWZg9DAJ- token: FGnDGsn5tNrKKrEwbWGGmNu3+ token: NoTcrZG9kDLunGec1qgS8k3iemail:customer_note:currency: USD@@ -5217,8 +5207,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 221807- slug: product-221807+ name: Product 221170+ slug: product-221170options_text: ''price: '10.0'display_price: "$10.00"@@ -5333,7 +5323,7 @@ paths:market_id: mkt_UkLWZg9DAJcart_id:channel_id: ch_UkLWZg9DAJ- number: R950634159+ number: R801732429email: [email protected]customer_note:currency: USD@@ -5342,7 +5332,7 @@ paths:coupon_code:fulfillment_status:payment_status:- completed_at: '2026-08-06T20:00:36.065Z'+ completed_at: '2026-08-06T21:23:23.190Z'item_total: '10.0'display_item_total: "$10.00"adjustment_total: '0.0'@@ -5374,8 +5364,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1615450- slug: product-1615450+ name: Product 1616143+ slug: product-1616143options_text: ''price: '10.0'display_price: "$10.00"@@ -5400,7 +5390,7 @@ paths:digital_links: []fulfillments:- id: ful_UkLWZg9DAJ- number: F43767956970+ number: F58163171859tracking: U10000tracking_url:pickup_point_data:@@ -5434,7 +5424,7 @@ paths:stock_location:id: sloc_UkLWZg9DAJstate_abbr: NY- name: Rebeca Barton+ name: Trista Weissnataddress1: 1600 Pennsylvania Ave NWcity: Washingtonzipcode: '20500'@@ -6389,8 +6379,8 @@ paths:market_id: mkt_UkLWZg9DAJcart_id:channel_id: ch_UkLWZg9DAJ- number: R847194696- email: [email protected]+ number: R406879504+ email: [email protected]customer_note:currency: USDlocale: en@@ -6398,7 +6388,7 @@ paths:coupon_code:fulfillment_status:payment_status:- completed_at: '2026-08-06T20:00:32.052Z'+ completed_at: '2026-08-06T21:23:19.547Z'item_total: '10.0'display_item_total: "$10.00"adjustment_total: '0.0'@@ -6430,8 +6420,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1307456- slug: product-1307456+ name: Product 1308859+ slug: product-1308859options_text: ''price: '10.0'display_price: "$10.00"@@ -6456,7 +6446,7 @@ paths:digital_links: []fulfillments:- id: ful_UkLWZg9DAJ- number: F70412700069+ number: F35386386056tracking: U10000tracking_url:pickup_point_data:@@ -6490,7 +6480,7 @@ paths:stock_location:id: sloc_UkLWZg9DAJstate_abbr: NY- name: Debbie Bahringer+ name: Elouise Huelsaddress1: 1600 Pennsylvania Ave NWcity: Washingtonzipcode: '20500'@@ -6670,8 +6660,8 @@ paths:market_id: mkt_UkLWZg9DAJcart_id:channel_id: ch_UkLWZg9DAJ- number: R398149125- email: [email protected]+ number: R494435688+ email: [email protected]customer_note:currency: USDlocale: en@@ -6679,7 +6669,7 @@ paths:coupon_code:fulfillment_status:payment_status:- completed_at: '2026-08-06T20:00:32.258Z'+ completed_at: '2026-08-06T21:23:19.767Z'item_total: '10.0'display_item_total: "$10.00"adjustment_total: '0.0'@@ -6711,8 +6701,8 @@ paths:preorder_ships_at:quantity: 1currency: USD- name: Product 1328611- slug: product-1328611+ name: Product 132642+ slug: product-132642options_text: ''price: '10.0'display_price: "$10.00"@@ -6737,7 +6727,7 @@ paths:digital_links: []fulfillments:- id: ful_UkLWZg9DAJ- number: F53926315863+ number: F69710174315tracking: U10000tracking_url:pickup_point_data:@@ -6771,7 +6761,7 @@ paths:stock_location:id: sloc_UkLWZg9DAJstate_abbr: NY- name: Julee Rippin+ name: Boris Rohanaddress1: 1600 Pennsylvania Ave NWcity: Washingtonzipcode: '20500'@@ -6907,8 +6897,8 @@ paths:content:application/json:example:- token: eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoxLCJ1c2VyX3R5cGUiOiJjdXN0b21lciIsImp0aSI6IjBmNWI3ZjAzLTdiZGEtNGFjYS1hMmIyLTE5MWJkYTZkMDAwZiIsImlzcyI6InNwcmVlIiwiYXVkIjoic3RvcmVfYXBpIiwiZXhwIjoxNzg2MDUwMDMyfQ.qxCJCnfMIEdCj2BxjkPlkwpiGo7AQvARrKZPEJTALiw- refresh_token: LPw6unEZGdjbWqiJgMztV8ei+ token: eyJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoxLCJ1c2VyX3R5cGUiOiJjdXN0b21lciIsImp0aSI6IjEyNjcwMmM5LTI0ZWItNDhiYS04MzBlLTNiNWFjODZlMDc3MyIsImlzcyI6InNwcmVlIiwiYXVkIjoic3RvcmVfYXBpIiwiZXhwIjoxNzg2MDU0OTk5fQ.QVnKZhQtdsiznZDFKAHYzf5L4iiIP_vq87EkMyB7gzw+ refresh_token: 8ew1DA5P3bhcZ8DXCp2gr98ouser:id: cust_UkLWZg9DAJemail: [email protected]@@ -6925,10 +6915,10 @@ paths:newsletter_subscriber:id: sub_UkLWZg9DAJemail: [email protected]- created_at: '2026-08-06T20:00:32.421Z'- updated_at: '2026-08-06T20:00:32.423Z'+ created_at: '2026-08-06T21:23:19.903Z'+ updated_at: '2026-08-06T21:23:19.905Z'verified: true- verified_at: '2026-08-06T20:00:32Z'+ verified_at: '2026-08-06T21:23:19Z'customer_id: cust_UkLWZg9DAJcustomer_groups: []schema:@@ -7031,12 +7021,12 @@ paths:application/json:example:id: cust_UkLWZg9DAJ- email: [email protected]- first_name: Lovie- last_name: Lynch+ email: [email protected]+ first_name: Krystina+ last_name: Konopelskiphone: 555-555-0199accepts_email_marketing: false- full_name: Lovie Lynch+ full_name: Krystina Konopelskiavailable_store_credit_total: '0'display_available_store_credit_total: "$0.00"addresses:@@ -7172,7 +7162,7 @@ paths:application/json:example:id: cust_UkLWZg9DAJ- email: [email protected]+ email: [email protected]first_name: Updatedlast_name: Namephone: 555-555-0199@@ -7363,7 +7353,7 @@ paths:example:data:- id: gc_UkLWZg9DAJ- code: BE19973852173D8D+ code: 7B6E241F02F890D9status: activecurrency: USDamount: '10.0'@@ -7459,7 +7449,7 @@ paths:application/json:example:id: gc_UkLWZg9DAJ- code: 134DAB09459EE746+ code: 3D8DA3F6CE130AAEstatus: activecurrency: USDamount: '10.0'@@ -7531,8 +7521,8 @@ paths:example:id: pss_gbHJdmfrXBstatus: pending- external_id: bogus_seti_de311527bbd0ed89a4a88eba- external_client_secret: bogus_seti_secret_e78a0af5cf82efbf+ external_id: bogus_seti_a35b7d68247801fc27ea5e2f+ external_client_secret: bogus_seti_secret_fbbf1ebd37df7f37external_data: {}payment_method_id: pm_UkLWZg9DAJpayment_source_id:@@ -7631,8 +7621,8 @@ paths:example:id: pss_UkLWZg9DAJstatus: pending- external_id: seti_test_bac1a9ec609eef34ebfc3a58- external_client_secret: seti_secret_19e3b04c197d70196cc5c459+ external_id: seti_test_ea6783c24438cc8a326747d2+ external_client_secret: seti_secret_5adb6ac7e94e7e6550c10804external_data:client_secret: secret_123payment_method_id: pm_UkLWZg9DAJ@@ -7708,8 +7698,8 @@ paths:example:id: pss_UkLWZg9DAJstatus: completed- external_id: seti_test_10cc6a1375277d7bc7d9bc6b- external_client_secret: seti_secret_747ea4a0b355507f59c85fa1+ external_id: seti_test_e131f5e75c265dd5d8621501+ external_client_secret: seti_secret_5c1337754565617504d128b7external_data:client_secret: secret_123payment_method_id: pm_UkLWZg9DAJ@@ -8653,7 +8643,7 @@ paths:data:- id: wl_UkLWZg9DAJname: My Wishlist- token: JAhvQvbWCCUj6Yon3ctm5dBy+ token: UYLjvZChpe8KjExHG6t485SYis_default: falseis_private: truemeta:@@ -8729,7 +8719,7 @@ paths:example:id: wl_gbHJdmfrXBname: Birthday Ideas- token: vqH5fZ5kVkFAHSseEFRynfrx+ token: Cs8cvKc2rDcKUQ5BLVZZ59vHis_default: falseis_private: trueschema:@@ -8830,7 +8820,7 @@ paths:example:id: wl_UkLWZg9DAJname: My Wishlist- token: 5z4BPg3GB1MjSoCXrL1fa5DP+ token: MJsTPhFZCsJSrGcRRncgBcFTis_default: falseis_private: trueschema:@@ -8892,7 +8882,7 @@ paths:example:id: wl_UkLWZg9DAJname: Updated Name- token: ynZjcf2hrkntSomZq7pwrjvk+ token: PCFLEyh7jbcmB3AYoSeFdZeRis_default: falseis_private: trueschema:@@ -9174,11 +9164,11 @@ paths:application/json:example:id: sub_UkLWZg9DAJ- email: [email protected]- created_at: '2026-08-06T20:00:35.440Z'- updated_at: '2026-08-06T20:00:35.441Z'+ email: [email protected]+ created_at: '2026-08-06T21:23:22.485Z'+ updated_at: '2026-08-06T21:23:22.485Z'verified: true- verified_at: '2026-08-06T20:00:35Z'+ verified_at: '2026-08-06T21:23:22Z'customer_id: cust_UkLWZg9DAJschema:"$ref": "#/components/schemas/NewsletterSubscriber"@@ -9257,10 +9247,10 @@ paths:example:id: sub_UkLWZg9DAJemail: [email protected]- created_at: '2026-08-06T20:00:35.461Z'- updated_at: '2026-08-06T20:00:35.467Z'+ created_at: '2026-08-06T21:23:22.504Z'+ updated_at: '2026-08-06T21:23:22.509Z'verified: true- verified_at: '2026-08-06T20:00:35Z'+ verified_at: '2026-08-06T21:23:22Z'customer_id:schema:"$ref": "#/components/schemas/NewsletterSubscriber"@@ -9430,7 +9420,7 @@ paths:body_html: ''- id: pol_OIJLhNcSbfname: Privacy Policy- slug: privacy-policy-3d42b2b0-4cb8-4cd2-8d7b-6959016621c8+ slug: privacy-policy-6fadb80b-2705-4849-9cae-2578ebfc7db5body: We respect your privacy.body_html: |<div class="trix-content">diff --git a/packages/admin-sdk/src/params.ts b/packages/admin-sdk/src/params.tsindex 109134d370..9ea06c1d02 100644--- a/packages/admin-sdk/src/params.ts+++ b/packages/admin-sdk/src/params.ts@@ -1399,9 +1399,8 @@ export type PaymentMethodType = ResourceTypeDefinition/*** One entry returned by `GET /integrations/types` — every registered- * integration with its configuration schema and whether the current store- * has it connected. This is the gallery source for the integrations- * settings page.+ * integration with its gallery metadata and configuration schema. Pure+ * registry discovery: read live connection state from `integrations.list()`.*/export interface IntegrationTypeDefinition {/** Wire shorthand (`Spree::Integration.api_type`), not the Ruby class name. */@@ -1414,8 +1413,6 @@ export interface IntegrationTypeDefinition {/** Gallery logo: an absolute URL to hosted brand assets, or a `data:` URI for self-contained gems. Render with a fallback — hosted logos are a courtesy, not a guarantee. */logo_url: string | nullpreference_schema: { key: string; type: string; default: unknown }[]- /** Whether the current store already holds credentials for this type. */- connected: boolean}export interface IntegrationCreateParams {diff --git a/packages/dashboard/src/routes/_authenticated/$storeId/settings/integrations.tsx b/packages/dashboard/src/routes/_authenticated/$storeId/settings/integrations.tsxindex f45c76a09a..be6b0f8dfc 100644--- a/packages/dashboard/src/routes/_authenticated/$storeId/settings/integrations.tsx+++ b/packages/dashboard/src/routes/_authenticated/$storeId/settings/integrations.tsx@@ -8,6 +8,9 @@ import {usePermissions,} from '@spree/dashboard-core'import {+ Avatar,+ AvatarFallback,+ AvatarImage,Badge,Button,Card,@@ -28,7 +31,7 @@ import {} from '@spree/dashboard-ui'import { createFileRoute, useNavigate } from '@tanstack/react-router'import { PlugIcon } from 'lucide-react'-import { useEffect, useMemo, useRef, useState } from 'react'+import { useMemo, useState } from 'react'import { useTranslation } from 'react-i18next'import { z } from 'zod/v4'import {@@ -128,6 +131,7 @@ function IntegrationsPage() {{configuringType && (<ConfigureIntegrationSheet+ key={`${configuringType.type}:${integrationsByType.get(configuringType.type)?.id ?? 'new'}`}type={configuringType}integration={integrationsByType.get(configuringType.type)}open@@ -186,27 +190,15 @@ function IntegrationCard({)}-// Gem-declared logo (hosted URL or data URI), falling back to an-// initial-letter avatar when none is declared — or when the URL fails to-// load (offline, vendor moved the file) — so cards never show a broken image.+// Gem-declared logo (hosted URL or data URI); the Avatar compound shows the+// initial-letter fallback until the image loads, covering unset and+// unreachable URLs alike — same pattern as the store switcher.function IntegrationLogo({ name, logoUrl }: { name: string; logoUrl: string | null }) {- const [failed, setFailed] = useState(false)-- if (logoUrl && !failed) {- return (- <img- src={logoUrl}- alt=""- onError={() => setFailed(true)}- className="size-9 shrink-0 rounded-md object-contain"- />- )- }-return (- <div className="flex size-9 shrink-0 items-center justify-center rounded-md bg-muted font-medium text-muted-foreground text-sm">- {name.charAt(0).toUpperCase()}- </div>+ <Avatar className="size-9 shrink-0 rounded-md">+ {logoUrl && <AvatarImage src={logoUrl} className="object-contain" />}+ <AvatarFallback className="rounded-md">{name.charAt(0).toUpperCase()}</AvatarFallback>+ </Avatar>)}@@ -228,23 +220,15 @@ function ConfigureIntegrationSheet({const deleteMutation = useDeleteIntegration()const testMutation = useTestIntegration()- const [preferences, setPreferences] = useState<Record<string, unknown>>({})- const [active, setActive] = useState(false)+ // Seeded once per mount — the parent keys this sheet by type + record, so+ // switching integrations remounts with fresh state.+ const [preferences, setPreferences] = useState<Record<string, unknown>>(() =>+ integration+ ? ((integration.preferences as Record<string, unknown>) ?? {})+ : defaultPreferences(type.preference_schema),+ )+ const [active, setActive] = useState(integration?.active ?? false)const [submitError, setSubmitError] = useState<string | null>(null)- const loadedIdRef = useRef<string | undefined>(undefined)-- useEffect(() => {- if (integration) {- if (integration.id === loadedIdRef.current) return- setPreferences((integration.preferences as Record<string, unknown>) ?? {})- setActive(integration.active)- loadedIdRef.current = integration.id- } else {- setPreferences(defaultPreferences(type.preference_schema))- setActive(false)- loadedIdRef.current = undefined- }- }, [integration, type])const saving = createMutation.isPending || updateMutation.isPendingdiff --git a/spree/api/app/controllers/spree/api/v3/admin/integrations_controller.rb b/spree/api/app/controllers/spree/api/v3/admin/integrations_controller.rbindex d9e714ce9f..6f2bc5bcdf 100644--- a/spree/api/app/controllers/spree/api/v3/admin/integrations_controller.rb+++ b/spree/api/app/controllers/spree/api/v3/admin/integrations_controller.rb@@ -16,25 +16,14 @@ module Spreeunknown_type_error: 'unknown_integration_type'# GET /api/v3/admin/integrations/types- # Every registered integration type with its configuration schema- # and whether the current store has it connected.+ # Pure registry discovery — which integrations are installed and how+ # they're configured. Deliberately carries no per-store connected+ # state: clients cache this long-lived and read live connection+ # state from the integrations list instead.def typesauthorize! :create, model_class- connected_types = current_store.integrations.pluck(:type)- data = Spree::Integration.registered_classes.map do |klass|- {- type: klass.api_type,- name: klass.integration_name,- group: klass.integration_group,- description: klass.localized_description,- logo_url: klass.logo_url,- preference_schema: klass.serialized_preference_schema,- connected: connected_types.include?(klass.to_s)- }- end-- render json: { data: data }+ render json: { data: Spree::Integration.discovery_entries }end# POST /api/v3/admin/integrations/:id/testdiff --git a/spree/api/spec/controllers/spree/api/v3/admin/integrations_controller_spec.rb b/spree/api/spec/controllers/spree/api/v3/admin/integrations_controller_spec.rbindex 1820b651c1..f05d2afc75 100644--- a/spree/api/spec/controllers/spree/api/v3/admin/integrations_controller_spec.rb+++ b/spree/api/spec/controllers/spree/api/v3/admin/integrations_controller_spec.rb@@ -34,26 +34,16 @@ RSpec.describe Spree::Api::V3::Admin::IntegrationsController, type: :controllerafter { Spree.integrations.delete('TestIntegrations::Carrier') }describe 'GET #types' do- it 'lists registered types with schema and connected state' do+ it 'lists registered types with their configuration schema' doget :types, as: :jsonexpect(response).to have_http_status(:ok)entry = json_response['data'].find { |row| row['type'] == 'carrier' }expect(entry['name']).to eq('Carrier')expect(entry['group']).to eq('shipping')- expect(entry['connected']).to be falseexpect(entry['preference_schema'].map { |f| f['key'] }).to match_array(%w[api_key account_number])end- it 'marks connected types for the current store' do- TestIntegrations::Carrier.create!(store: store, active: false)-- get :types, as: :json-- entry = json_response['data'].find { |row| row['type'] == 'carrier' }- expect(entry['connected']).to be true- end-describe 'gallery metadata' doit 'serves the class description and no logo by default' doallow(TestIntegrations::Carrier).to receive(:description).and_return('Ships things')diff --git a/spree/api/spec/integration/spree/api/v3/admin/integrations_spec.rb b/spree/api/spec/integration/spree/api/v3/admin/integrations_spec.rbindex 377a13a7b3..7f1e19cad9 100644--- a/spree/api/spec/integration/spree/api/v3/admin/integrations_spec.rb+++ b/spree/api/spec/integration/spree/api/v3/admin/integrations_spec.rb@@ -92,7 +92,7 @@ RSpec.describe 'Admin Integrations API', type: :request, swagger_doc: 'api-refertags 'Integrations'produces 'application/json'security [api_key: [], bearer_auth: []]- description 'Every registered integration type with its configuration schema and whether the current store has it connected. Registered types ship with provider gems.'+ description 'Every registered integration type with its gallery metadata and configuration schema. Pure registry discovery — read live connection state from GET /integrations.'admin_scope :read, :integrationsadmin_sdk_example 'integrations/types'@@ -104,7 +104,6 @@ RSpec.describe 'Admin Integrations API', type: :request, swagger_doc: 'api-referrun_test! do |response|data = JSON.parse(response.body)entry = data['data'].find { |row| row['type'] == 'carrier' }- expect(entry['connected']).to be falseexpect(entry['preference_schema']).to be_an(Array)endenddiff --git a/spree/core/app/models/spree/fulfillment_provider/base.rb b/spree/core/app/models/spree/fulfillment_provider/base.rbindex 8dd7b59984..b629bbac8e 100644--- a/spree/core/app/models/spree/fulfillment_provider/base.rb+++ b/spree/core/app/models/spree/fulfillment_provider/base.rb@@ -19,6 +19,16 @@ module Spreedef provider_namename.demodulize.titleizeend++ # The Spree::Integration subclass holding this provider's credentials,+ # as a class name string — same contract as+ # {Spree::DeliveryRateProvider::Base.integration_class}. Providers+ # without external credentials leave it nil.+ #+ # @return [String, nil]+ def integration_class+ nil+ endend# @return [Boolean] whether the fulfillment may transition to fulfilled@@ -68,6 +78,20 @@ module Spreedef documents(_fulfillment)[]end++ private++ # The connected, active integration carrying this provider's+ # credentials, resolved from the fulfillment's store.+ #+ # @param fulfillment [Spree::Fulfillment]+ # @return [Spree::Integration, nil]+ def integration_for(fulfillment)+ return if self.class.integration_class.blank?++ store = fulfillment.order&.store || fulfillment.cart&.store+ store&.integrations&.active&.find_by(type: self.class.integration_class)+ endendendenddiff --git a/spree/core/app/models/spree/integration.rb b/spree/core/app/models/spree/integration.rbindex 7d4dc3765e..324a6beb91 100644--- a/spree/core/app/models/spree/integration.rb+++ b/spree/core/app/models/spree/integration.rb@@ -53,10 +53,6 @@ module Spreenilend- def self.icon_path- nil- end-# Logo shown on the gallery card: an absolute URL to publicly hosted# brand assets, or a `data:` URI for gems that want to be self-contained# (works air-gapped, no CSP domain to allowlist). Anything an `<img src>`@@ -80,19 +76,34 @@ module Spreeend# Description for the current locale: the gem's Rails translation when- # present, otherwise the {.description} fallback.+ # present, otherwise the {.description} fallback. Named per the+ # human_name/human_description convention of the rule families.## @return [String, nil]- def self.localized_description+ def self.human_descriptionSpree.t("integrations.#{api_type}.description", default: description)end- def self.integration_name- name.demodulize.titleize.strip+ # Wire entries for the admin types-discovery endpoint — every registered+ # integration with its gallery metadata and configuration schema, stably+ # ordered by name.+ #+ # @return [Array<Hash>]+ def self.discovery_entries+ registered_classes.map do |klass|+ {+ type: klass.api_type,+ name: klass.integration_name,+ group: klass.integration_group,+ description: klass.human_description,+ logo_url: klass.logo_url,+ preference_schema: klass.serialized_preference_schema+ }+ end.sort_by { |entry| entry[:name] }end- def self.integration_key- name.demodulize.underscore+ def self.integration_name+ name.demodulize.titleize.stripend# Wire shorthand for the admin API. Provider gems follow the@@ -113,10 +124,6 @@ module Spreeself.class.integration_nameend- def key- self.class.integration_key- end-# Checks if the integration can establish a connection.# This is a base implementation that always returns true.# Subclasses should override this method to implement their own connection validation logic.diff --git a/spree/core/spec/models/spree/integration_spec.rb b/spree/core/spec/models/spree/integration_spec.rbindex bbf353da48..525a8cfb77 100644--- a/spree/core/spec/models/spree/integration_spec.rb+++ b/spree/core/spec/models/spree/integration_spec.rb@@ -54,14 +54,14 @@ RSpec.describe Spree::Integration, type: :model doendit 'falls back to the class description without a translation' do- expect(SpreeCarrier::Integration.localized_description).to eq('Fallback description')+ expect(SpreeCarrier::Integration.human_description).to eq('Fallback description')endit 'prefers the Rails translation for the current locale' dotranslations = { spree: { integrations: { carrier: { description: 'Translated' } } } }I18n.backend.store_translations(:en, translations)- expect(SpreeCarrier::Integration.localized_description).to eq('Translated')+ expect(SpreeCarrier::Integration.human_description).to eq('Translated')ensureI18n.backend.reload!enddiff --git a/spree/easypost/app/models/spree_easypost/delivery_rate_provider.rb b/spree/easypost/app/models/spree_easypost/delivery_rate_provider.rbindex 51fc960195..1ee610ef2f 100644--- a/spree/easypost/app/models/spree_easypost/delivery_rate_provider.rb+++ b/spree/easypost/app/models/spree_easypost/delivery_rate_provider.rb@@ -59,15 +59,7 @@ module SpreeEasyPostenddef address_params(source)- {- street1: source.address1,- street2: source.address2,- city: source.city,- state: source.respond_to?(:state_abbr) ? source.state_abbr : source.state&.abbr,- zip: source.zipcode,- country: source.country&.iso,- phone: source.phone- }.compact_blank+ SpreeEasyPost.address_params(source)enddef parcel_params(package)diff --git a/spree/easypost/app/models/spree_easypost/fulfillment_provider.rb b/spree/easypost/app/models/spree_easypost/fulfillment_provider.rbindex 6ea169762c..b6bba0ff5a 100644--- a/spree/easypost/app/models/spree_easypost/fulfillment_provider.rb+++ b/spree/easypost/app/models/spree_easypost/fulfillment_provider.rb@@ -13,6 +13,10 @@ module SpreeEasyPost'EasyPost'end+ def self.integration_class+ 'SpreeEasyPost::Integration'+ end+# Buys the rate quoted at checkout when it is still valid; EasyPost# quotes expire, so a stale or missing quote is re-quoted from the# actual fulfillment and bought only when a rate for the method's exact@@ -100,21 +104,8 @@ module SpreeEasyPost)end- def integration_for(fulfillment)- store = fulfillment.order&.store || fulfillment.cart&.store- store&.integrations&.active&.find_by(type: 'SpreeEasyPost::Integration')- end-def address_params(source)- {- street1: source.address1,- street2: source.address2,- city: source.city,- state: source.respond_to?(:state_abbr) ? source.state_abbr : source.state&.abbr,- zip: source.zipcode,- country: source.country&.iso,- phone: source.phone- }.compact_blank+ SpreeEasyPost.address_params(source)enddef report(error, fulfillment)diff --git a/spree/easypost/lib/spree_easypost.rb b/spree/easypost/lib/spree_easypost.rbindex 58d0719a56..326f584d23 100644--- a/spree/easypost/lib/spree_easypost.rb+++ b/spree/easypost/lib/spree_easypost.rb@@ -18,4 +18,20 @@ module SpreeEasyPostunit_system = store&.preferred_unit_system.presence || 'imperial'(weight.to_f * OUNCES_PER_UNIT.fetch(unit_system.to_s, 16.0)).round(2)end++ # EasyPost address payload from a Spree address or stock location.+ #+ # @param source [Spree::Address, Spree::StockLocation]+ # @return [Hash]+ def self.address_params(source)+ {+ street1: source.address1,+ street2: source.address2,+ city: source.city,+ state: source.respond_to?(:state_abbr) ? source.state_abbr : source.state&.abbr,+ zip: source.zipcode,+ country: source.country&.iso,+ phone: source.phone+ }.compact_blank+ endenddiff --git a/spree/easypost/spec/models/spree_easypost/integration_spec.rb b/spree/easypost/spec/models/spree_easypost/integration_spec.rbindex c24b64f4f6..36fa2effa2 100644--- a/spree/easypost/spec/models/spree_easypost/integration_spec.rb+++ b/spree/easypost/spec/models/spree_easypost/integration_spec.rb@@ -16,7 +16,7 @@ RSpec.describe SpreeEasyPost::Integration doit 'declares gallery metadata' doexpect(described_class.logo_url).to start_with('https://')# The gem's locale file wins over the class fallback.- expect(described_class.localized_description).to include('negotiated carrier contracts')+ expect(described_class.human_description).to include('negotiated carrier contracts')endit 'masks the api key as a password preference' dodiff --git a/spree/easypost/spec/spec_helper.rb b/spree/easypost/spec/spec_helper.rbindex 97f9203544..54cc39c638 100644--- a/spree/easypost/spec/spec_helper.rb+++ b/spree/easypost/spec/spec_helper.rb@@ -1,3 +1,19 @@+if ENV['COVERAGE']+ require 'simplecov'+ require 'simplecov-cobertura'+ SimpleCov.root(ENV.fetch('GITHUB_WORKSPACE', File.expand_path('../../..', __dir__)))+ SimpleCov.formatter = SimpleCov::Formatter::CoberturaFormatter+ SimpleCov.start 'rails' do+ add_group 'Models', 'app/models'+ add_filter '/bin/'+ add_filter '/spec/'++ suffix = [ENV.fetch('CI_SHARD', '1'), ENV['TEST_ENV_NUMBER']].compact.reject(&:empty?).join('_')+ coverage_dir "#{ENV['COVERAGE_DIR']}/easypost_#{suffix}" if ENV['COVERAGE_DIR']+ command_name "easypost_shard_#{suffix}"+ end+end+ENV['RAILS_ENV'] ||= 'test'begin