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
SD-1491 Add Store Credits endpoints to Platform API (#11473)
Aleksandar Petrushevfc8d6084e097
diff --git a/api/app/controllers/spree/api/v2/platform/store_credits_controller.rb b/api/app/controllers/spree/api/v2/platform/store_credits_controller.rbnew file mode 100644index 0000000000..15905cae18--- /dev/null+++ b/api/app/controllers/spree/api/v2/platform/store_credits_controller.rb@@ -0,0 +1,19 @@+module Spree+ module Api+ module V2+ module Platform+ class StoreCreditsController < ResourceController+ private++ def model_class+ Spree::StoreCredit+ end++ def scope_includes+ [:user, :created_by, :category, :credit_type]+ end+ end+ end+ end+ end+enddiff --git a/api/config/routes.rb b/api/config/routes.rbindex 30917bad67..7329094be9 100644--- a/api/config/routes.rb+++ b/api/config/routes.rb@@ -246,6 +246,9 @@ Spree::Core::Engine.add_routes do# endend+ # Store Credit API+ resources :store_credits+# Geo APIresources :zonesresources :countries, only: [:index, :show]diff --git a/api/docs/v2/platform/index.yaml b/api/docs/v2/platform/index.yamlindex ee15b42a17..79a908d3a2 100644--- a/api/docs/v2/platform/index.yaml+++ b/api/docs/v2/platform/index.yaml@@ -70,8 +70,8 @@ paths:state_name:alternative_phone: 555-555-0199company: Company- created_at: '2021-11-08T15:17:40.804Z'- updated_at: '2021-11-08T15:17:40.804Z'+ created_at: '2021-11-09T11:27:13.437Z'+ updated_at: '2021-11-09T11:27:13.437Z'deleted_at:label:public_metadata: {}@@ -100,8 +100,8 @@ paths:state_name:alternative_phone: 555-555-0199company: Company- created_at: '2021-11-08T15:17:40.813Z'- updated_at: '2021-11-08T15:17:40.813Z'+ created_at: '2021-11-09T11:27:13.443Z'+ updated_at: '2021-11-09T11:27:13.443Z'deleted_at:label:public_metadata: {}@@ -177,8 +177,8 @@ paths:state_name:alternative_phone: 555-555-0199company: Company- created_at: '2021-11-08T15:17:41.149Z'- updated_at: '2021-11-08T15:17:41.149Z'+ created_at: '2021-11-09T11:27:13.798Z'+ updated_at: '2021-11-09T11:27:13.798Z'deleted_at:label:public_metadata: {}@@ -274,8 +274,8 @@ paths:state_name:alternative_phone: 555-555-0199company: Company- created_at: '2021-11-08T15:17:41.229Z'- updated_at: '2021-11-08T15:17:41.229Z'+ created_at: '2021-11-09T11:27:13.878Z'+ updated_at: '2021-11-09T11:27:13.878Z'deleted_at:label:public_metadata: {}@@ -356,8 +356,8 @@ paths:state_name:alternative_phone: 555-555-0199company: Company- created_at: '2021-11-08T15:17:41.474Z'- updated_at: '2021-11-08T15:17:41.486Z'+ created_at: '2021-11-09T11:27:13.978Z'+ updated_at: '2021-11-09T11:27:13.994Z'deleted_at:label:public_metadata: {}@@ -503,8 +503,8 @@ paths:label: Shippingmandatory:eligible: true- created_at: '2021-11-08T15:17:41.831Z'- updated_at: '2021-11-08T15:17:41.831Z'+ created_at: '2021-11-09T11:27:14.324Z'+ updated_at: '2021-11-09T11:27:14.324Z'state: openincluded: falsedisplay_amount: "$100.00"@@ -530,8 +530,8 @@ paths:label: Shippingmandatory:eligible: true- created_at: '2021-11-08T15:17:41.864Z'- updated_at: '2021-11-08T15:17:41.864Z'+ created_at: '2021-11-09T11:27:14.351Z'+ updated_at: '2021-11-09T11:27:14.351Z'state: openincluded: falsedisplay_amount: "$100.00"@@ -604,8 +604,8 @@ paths:label: Shippingmandatory:eligible: true- created_at: '2021-11-08T15:17:42.266Z'- updated_at: '2021-11-08T15:17:42.266Z'+ created_at: '2021-11-09T11:27:14.740Z'+ updated_at: '2021-11-09T11:27:14.740Z'state: openincluded: falsedisplay_amount: "$100.00"@@ -687,8 +687,8 @@ paths:label: Shippingmandatory:eligible: true- created_at: '2021-11-08T15:17:42.454Z'- updated_at: '2021-11-08T15:17:42.462Z'+ created_at: '2021-11-09T11:27:14.955Z'+ updated_at: '2021-11-09T11:27:14.983Z'state: openincluded: falsedisplay_amount: "$1.00"@@ -766,8 +766,8 @@ paths:label: New labelmandatory:eligible: true- created_at: '2021-11-08T15:17:42.768Z'- updated_at: '2021-11-08T15:17:42.787Z'+ created_at: '2021-11-09T11:27:15.317Z'+ updated_at: '2021-11-09T11:27:15.335Z'state: openincluded: falsedisplay_amount: "$15.00"@@ -907,8 +907,8 @@ paths:type: classificationattributes:position: 1- created_at: '2021-11-08T15:17:43.617Z'- updated_at: '2021-11-08T15:17:43.617Z'+ created_at: '2021-11-09T11:27:16.235Z'+ updated_at: '2021-11-09T11:27:16.235Z'relationships:product:data:@@ -922,8 +922,8 @@ paths:type: classificationattributes:position: 1- created_at: '2021-11-08T15:17:43.733Z'- updated_at: '2021-11-08T15:17:43.733Z'+ created_at: '2021-11-09T11:27:16.339Z'+ updated_at: '2021-11-09T11:27:16.339Z'relationships:product:data:@@ -984,8 +984,8 @@ paths:type: classificationattributes:position: 1- created_at: '2021-11-08T15:17:44.448Z'- updated_at: '2021-11-08T15:17:44.448Z'+ created_at: '2021-11-09T11:27:17.064Z'+ updated_at: '2021-11-09T11:27:17.064Z'relationships:product:data:@@ -1052,8 +1052,8 @@ paths:type: classificationattributes:position: 1- created_at: '2021-11-08T15:17:44.716Z'- updated_at: '2021-11-08T15:17:44.716Z'+ created_at: '2021-11-09T11:27:17.303Z'+ updated_at: '2021-11-09T11:27:17.303Z'relationships:product:data:@@ -1119,8 +1119,8 @@ paths:type: classificationattributes:position: 1- created_at: '2021-11-08T15:17:45.234Z'- updated_at: '2021-11-08T15:17:45.234Z'+ created_at: '2021-11-09T11:27:17.788Z'+ updated_at: '2021-11-09T11:27:17.788Z'relationships:product:data:@@ -1242,8 +1242,8 @@ paths:type: classificationattributes:position: 2- created_at: '2021-11-08T15:17:46.500Z'- updated_at: '2021-11-08T15:17:46.528Z'+ created_at: '2021-11-09T11:27:18.969Z'+ updated_at: '2021-11-09T11:27:18.998Z'relationships:product:data:@@ -1348,34 +1348,35 @@ paths:- id: '1'type: cms_pageattributes:- title: Nemo cumque cum hic nulla modi beatae esse.+ title: Recusandae officia maiores suscipit quibusdam id.meta_title:content:meta_description:visible: true- slug: nemo-cumque-cum-hic-nulla-modi-beatae-esse+ slug: recusandae-officia-maiores-suscipit-quibusdam-idtype: Spree::Cms::Pages::StandardPagelocale: endeleted_at:- created_at: '2021-11-08T15:17:47.088Z'- updated_at: '2021-11-08T15:17:47.088Z'+ created_at: '2021-11-09T11:27:19.531Z'+ updated_at: '2021-11-09T11:27:19.531Z'relationships:cms_sections:data: []- id: '2'type: cms_pageattributes:- title: Inventore fugit totam voluptatem quo voluptatibus aspernatur.+ title: Velit voluptatum a provident iste temporibus ratione+ quia perspiciatis.meta_title:content:meta_description:visible: true- slug: inventore-fugit-totam-voluptatem-quo-voluptatibus-aspernatur+ slug: velit-voluptatum-a-provident-iste-temporibus-ratione-quia-perspiciatistype: Spree::Cms::Pages::StandardPagelocale: endeleted_at:- created_at: '2021-11-08T15:17:47.094Z'- updated_at: '2021-11-08T15:17:47.094Z'+ created_at: '2021-11-09T11:27:19.536Z'+ updated_at: '2021-11-09T11:27:19.536Z'relationships:cms_sections:data: []@@ -1429,18 +1430,17 @@ paths:id: '5'type: cms_pageattributes:- title: Eum id pariatur quia vero voluptatum facere dolorem- provident.+ title: Eius sunt tenetur eaque unde nemo occaecati quaerat.meta_title:content:meta_description:visible: true- slug: eum-id-pariatur-quia-vero-voluptatum-facere-dolorem-provident+ slug: eius-sunt-tenetur-eaque-unde-nemo-occaecati-quaerattype: Spree::Cms::Pages::StandardPagelocale: endeleted_at:- created_at: '2021-11-08T15:17:47.230Z'- updated_at: '2021-11-08T15:17:47.230Z'+ created_at: '2021-11-09T11:27:19.659Z'+ updated_at: '2021-11-09T11:27:19.659Z'relationships:cms_sections:data: []@@ -1506,18 +1506,18 @@ paths:id: '6'type: cms_pageattributes:- title: In harum consequatur distinctio occaecati sint dicta- cupiditate nesciunt.+ title: Fugiat molestiae aspernatur aliquid facere impedit+ odit commodi.meta_title:content:meta_description:visible: true- slug: in-harum-consequatur-distinctio-occaecati-sint-dicta-cupiditate-nesciunt+ slug: fugiat-molestiae-aspernatur-aliquid-facere-impedit-odit-commoditype: Spree::Cms::Pages::StandardPagelocale: endeleted_at:- created_at: '2021-11-08T15:17:47.301Z'- updated_at: '2021-11-08T15:17:47.301Z'+ created_at: '2021-11-09T11:27:19.727Z'+ updated_at: '2021-11-09T11:27:19.727Z'relationships:cms_sections:data: []@@ -1581,12 +1581,12 @@ paths:content:meta_description:visible: true- slug: exercitationem-rem-amet-animi-dolor-quos-temporibus-quaerat-minima+ slug: quo-aspernatur-occaecati-ex-debitis-numquam-veniam-rationetype: Spree::Cms::Pages::StandardPagelocale: endeleted_at:- created_at: '2021-11-08T15:17:47.428Z'- updated_at: '2021-11-08T15:17:47.443Z'+ created_at: '2021-11-09T11:27:19.834Z'+ updated_at: '2021-11-09T11:27:19.857Z'relationships:cms_sections:data: []@@ -1715,7 +1715,7 @@ paths:- id: '1'type: cms_sectionattributes:- name: Commodi illo minus natus nihil quaerat ad.+ name: Accusamus expedita vel aut asperiores fugit.content: {}settings:gutters: No Gutters@@ -1724,8 +1724,8 @@ paths:type: Spree::Cms::Sections::HeroImageposition: 1linked_resource_type: Spree::Taxon- created_at: '2021-11-08T15:17:47.755Z'- updated_at: '2021-11-08T15:17:47.755Z'+ created_at: '2021-11-09T11:27:20.135Z'+ updated_at: '2021-11-09T11:27:20.135Z'relationships:cms_page:data:@@ -1736,7 +1736,7 @@ paths:- id: '2'type: cms_sectionattributes:- name: Quaerat dolor placeat pariatur explicabo.+ name: Iure quidem reprehenderit minima quisquam fugiat.content:link_type_one: Spree::Taxonlink_type_two: Spree::Taxon@@ -1748,8 +1748,8 @@ paths:type: Spree::Cms::Sections::ImageGalleryposition: 2linked_resource_type:- created_at: '2021-11-08T15:17:47.760Z'- updated_at: '2021-11-08T15:17:47.760Z'+ created_at: '2021-11-09T11:27:20.139Z'+ updated_at: '2021-11-09T11:27:20.139Z'relationships:cms_page:data:@@ -1760,8 +1760,7 @@ paths:- id: '3'type: cms_sectionattributes:- name: Quas fugit accusamus fugiat asperiores molestiae illo- aut.+ name: Amet aperiam possimus harum aliquam sequi omnis.content: {}settings:gutters: No Gutters@@ -1770,8 +1769,8 @@ paths:type: Spree::Cms::Sections::FeaturedArticleposition: 3linked_resource_type: Spree::Taxon- created_at: '2021-11-08T15:17:47.772Z'- updated_at: '2021-11-08T15:17:47.772Z'+ created_at: '2021-11-09T11:27:20.154Z'+ updated_at: '2021-11-09T11:27:20.154Z'relationships:cms_page:data:@@ -1782,8 +1781,7 @@ paths:- id: '4'type: cms_sectionattributes:- name: Necessitatibus aperiam consequatur nihil nemo perspiciatis- fugiat officiis.+ name: Ratione molestiae sapiente non optio.content: {}settings:gutters: No Gutters@@ -1792,8 +1790,8 @@ paths:type: Spree::Cms::Sections::HeroImageposition: 4linked_resource_type: Spree::Product- created_at: '2021-11-08T15:17:47.793Z'- updated_at: '2021-11-08T15:17:47.793Z'+ created_at: '2021-11-09T11:27:20.166Z'+ updated_at: '2021-11-09T11:27:20.166Z'relationships:cms_page:data:@@ -1806,8 +1804,7 @@ paths:- id: '5'type: cms_sectionattributes:- name: Deserunt soluta amet itaque iure alias nam molestiae- provident.+ name: Minima quaerat nulla explicabo odio consequuntur tempora.content: {}settings:gutters: No Gutters@@ -1816,8 +1813,8 @@ paths:type: Spree::Cms::Sections::HeroImageposition: 5linked_resource_type: Spree::Product- created_at: '2021-11-08T15:17:47.805Z'- updated_at: '2021-11-08T15:17:47.805Z'+ created_at: '2021-11-09T11:27:20.178Z'+ updated_at: '2021-11-09T11:27:20.178Z'relationships:cms_page:data:@@ -1877,8 +1874,8 @@ paths:id: '13'type: cms_sectionattributes:- name: Cupiditate culpa asperiores quam quisquam molestiae- deserunt.+ name: Eos consequatur quia provident animi dolores asperiores+ eveniet.content: {}settings:gutters: No Gutters@@ -1887,8 +1884,8 @@ paths:type: Spree::Cms::Sections::HeroImageposition: 3linked_resource_type: Spree::Product- created_at: '2021-11-08T15:17:48.078Z'- updated_at: '2021-11-08T15:17:48.078Z'+ created_at: '2021-11-09T11:27:20.416Z'+ updated_at: '2021-11-09T11:27:20.416Z'relationships:cms_page:data:@@ -1963,7 +1960,7 @@ paths:id: '19'type: cms_sectionattributes:- name: Enim ipsa earum cum unde libero.+ name: Vitae optio voluptas tempora eveniet quidem minus.content: {}settings:gutters: No Gutters@@ -1972,8 +1969,8 @@ paths:type: Spree::Cms::Sections::HeroImageposition: 4linked_resource_type: Spree::Product- created_at: '2021-11-08T15:17:48.319Z'- updated_at: '2021-11-08T15:17:48.319Z'+ created_at: '2021-11-09T11:27:20.606Z'+ updated_at: '2021-11-09T11:27:20.606Z'relationships:cms_page:data:@@ -2047,8 +2044,8 @@ paths:type: Spree::Cms::Sections::HeroImageposition: 1linked_resource_type: Spree::Product- created_at: '2021-11-08T15:17:48.676Z'- updated_at: '2021-11-08T15:17:48.697Z'+ created_at: '2021-11-09T11:27:20.905Z'+ updated_at: '2021-11-09T11:27:20.921Z'relationships:cms_page:data:@@ -2168,9 +2165,9 @@ paths:name: United States of Americanumcode: 840states_required: true- updated_at: '2021-11-08T15:17:49.415Z'+ updated_at: '2021-11-09T11:27:21.545Z'zipcode_required: true- created_at: '2021-11-08T15:17:49.415Z'+ created_at: '2021-11-09T11:27:21.545Z'relationships:states:data: []@@ -2183,9 +2180,9 @@ paths:name: NAME_2numcode: 840states_required: false- updated_at: '2021-11-08T15:17:49.423Z'+ updated_at: '2021-11-09T11:27:21.553Z'zipcode_required: true- created_at: '2021-11-08T15:17:49.423Z'+ created_at: '2021-11-09T11:27:21.553Z'relationships:states:data: []@@ -2198,9 +2195,9 @@ paths:name: NAME_3numcode: 840states_required: false- updated_at: '2021-11-08T15:17:49.426Z'+ updated_at: '2021-11-09T11:27:21.556Z'zipcode_required: true- created_at: '2021-11-08T15:17:49.426Z'+ created_at: '2021-11-09T11:27:21.556Z'relationships:states:data: []@@ -2259,9 +2256,9 @@ paths:name: NAME_6numcode: 840states_required: false- updated_at: '2021-11-08T15:17:49.516Z'+ updated_at: '2021-11-09T11:27:21.642Z'zipcode_required: true- created_at: '2021-11-08T15:17:49.516Z'+ created_at: '2021-11-09T11:27:21.642Z'relationships:states:data: []@@ -2319,7 +2316,7 @@ paths:- id: '1'type: digital_linkattributes:- token: d9pqxPRg2spQXH5zJDJVsSXL+ token: 8zjcPXtzfvc4ViNjeXa2jjFkaccess_counter: 0relationships:digital:@@ -2333,7 +2330,7 @@ paths:- id: '2'type: digital_linkattributes:- token: emZLoGa6SNd8Z2wmH62P3mvi+ token: 1meiSdDM3YkWrgjGeseDzj4Vaccess_counter: 0relationships:digital:@@ -2387,7 +2384,7 @@ paths:id: '5'type: digital_linkattributes:- token: hBSMnSbqvkVZP14AfvPUydRR+ token: sg2GGb3yMWYrVJ4C1Vcdx3Q9access_counter: 0relationships:digital:@@ -2450,7 +2447,7 @@ paths:id: '6'type: digital_linkattributes:- token: Ppud9NNAKa9dqvxewNubwGNZ+ token: ZudXzDxVutNErAQ9X2Xg2Aokaccess_counter: 0relationships:digital:@@ -2509,7 +2506,7 @@ paths:id: '8'type: digital_linkattributes:- token: L79Y2AFK1w8oN1xPyXdhhpyx+ token: zwFyXZiqS5K5BiMUxFL2SWndaccess_counter: 0relationships:digital:@@ -2624,7 +2621,7 @@ paths:id: '13'type: digital_linkattributes:- token: et9Fn6FqkGyZztUyMkpRZdsc+ token: EvYHmkSBso7N6tcrfhVZPvcEaccess_counter: 0relationships:digital:@@ -3041,8 +3038,8 @@ paths:attributes:quantity: 1price: '10.0'- created_at: '2021-11-08T15:18:03.356Z'- updated_at: '2021-11-08T15:18:03.368Z'+ created_at: '2021-11-09T11:27:33.359Z'+ updated_at: '2021-11-09T11:27:33.370Z'currency: USDcost_price: '17.0'adjustment_total: '0.0'@@ -3090,8 +3087,8 @@ paths:attributes:quantity: 1price: '10.0'- created_at: '2021-11-08T15:18:03.416Z'- updated_at: '2021-11-08T15:18:03.425Z'+ created_at: '2021-11-09T11:27:33.415Z'+ updated_at: '2021-11-09T11:27:33.422Z'currency: USDcost_price: '17.0'adjustment_total: '0.0'@@ -3186,8 +3183,8 @@ paths:attributes:quantity: 1price: '10.0'- created_at: '2021-11-08T15:18:03.805Z'- updated_at: '2021-11-08T15:18:03.849Z'+ created_at: '2021-11-09T11:27:33.740Z'+ updated_at: '2021-11-09T11:27:33.787Z'currency: USDcost_price: '17.0'adjustment_total: '0.0'@@ -3291,8 +3288,8 @@ paths:attributes:quantity: 1price: '10.0'- created_at: '2021-11-08T15:18:04.080Z'- updated_at: '2021-11-08T15:18:04.092Z'+ created_at: '2021-11-09T11:27:34.002Z'+ updated_at: '2021-11-09T11:27:34.011Z'currency: USDcost_price: '17.0'adjustment_total: '0.0'@@ -3392,8 +3389,8 @@ paths:attributes:quantity: 4price: '10.0'- created_at: '2021-11-08T15:18:04.456Z'- updated_at: '2021-11-08T15:18:04.523Z'+ created_at: '2021-11-09T11:27:34.342Z'+ updated_at: '2021-11-09T11:27:34.396Z'currency: USDcost_price: '17.0'adjustment_total: '0.0'@@ -3445,10 +3442,10 @@ paths:examples:Example:value:- error: 'Quantity selected of "Product #130 - 8562" is not available.'+ error: 'Quantity selected of "Product #130 - 5339" is not available.'errors:quantity:- - 'selected of "Product #130 - 8562" is not available.'+ - 'selected of "Product #130 - 5339" is not available.'schema:"$ref": "#/components/schemas/validation_errors"'404':@@ -3568,8 +3565,8 @@ paths:lft: 2rgt: 3depth: 1- created_at: '2021-11-08T15:18:05.483Z'- updated_at: '2021-11-08T15:18:05.490Z'+ created_at: '2021-11-09T11:27:35.256Z'+ updated_at: '2021-11-09T11:27:35.263Z'link:is_container: falseis_root: false@@ -3605,8 +3602,8 @@ paths:lft: 4rgt: 5depth: 1- created_at: '2021-11-08T15:18:05.591Z'- updated_at: '2021-11-08T15:18:05.598Z'+ created_at: '2021-11-09T11:27:35.348Z'+ updated_at: '2021-11-09T11:27:35.354Z'link:is_container: falseis_root: false@@ -3642,8 +3639,8 @@ paths:lft: 6rgt: 7depth: 1- created_at: '2021-11-08T15:18:05.685Z'- updated_at: '2021-11-08T15:18:05.691Z'+ created_at: '2021-11-09T11:27:35.440Z'+ updated_at: '2021-11-09T11:27:35.446Z'link:is_container: falseis_root: false@@ -3679,8 +3676,8 @@ paths:lft: 8rgt: 9depth: 1- created_at: '2021-11-08T15:18:05.781Z'- updated_at: '2021-11-08T15:18:05.788Z'+ created_at: '2021-11-09T11:27:35.537Z'+ updated_at: '2021-11-09T11:27:35.544Z'link:is_container: falseis_root: false@@ -3716,8 +3713,8 @@ paths:lft: 10rgt: 11depth: 1- created_at: '2021-11-08T15:18:05.874Z'- updated_at: '2021-11-08T15:18:05.882Z'+ created_at: '2021-11-09T11:27:35.627Z'+ updated_at: '2021-11-09T11:27:35.633Z'link:is_container: falseis_root: false@@ -3753,8 +3750,8 @@ paths:lft: 12rgt: 13depth: 1- created_at: '2021-11-08T15:18:05.971Z'- updated_at: '2021-11-08T15:18:05.979Z'+ created_at: '2021-11-09T11:27:35.718Z'+ updated_at: '2021-11-09T11:27:35.724Z'link:is_container: falseis_root: false@@ -3790,8 +3787,8 @@ paths:lft: 14rgt: 15depth: 1- created_at: '2021-11-08T15:18:06.068Z'- updated_at: '2021-11-08T15:18:06.074Z'+ created_at: '2021-11-09T11:27:35.808Z'+ updated_at: '2021-11-09T11:27:35.814Z'link:is_container: falseis_root: false@@ -3817,7 +3814,7 @@ paths:- id: '1'type: menu_itemattributes:- name: Dolorem voluptatum eius rem aspernatur.+ name: Pariatur dolore molestiae animi iure impedit itaque.subtitle:destination:new_window: false@@ -3827,8 +3824,8 @@ paths:lft: 1rgt: 16depth: 0- created_at: '2021-11-08T15:18:05.395Z'- updated_at: '2021-11-08T15:18:06.090Z'+ created_at: '2021-11-09T11:27:35.169Z'+ updated_at: '2021-11-09T11:27:35.826Z'link:is_container: trueis_root: true@@ -3921,8 +3918,8 @@ paths:lft: 8rgt: 9depth: 1- created_at: '2021-11-08T15:18:07.219Z'- updated_at: '2021-11-08T15:18:07.226Z'+ created_at: '2021-11-09T11:27:36.927Z'+ updated_at: '2021-11-09T11:27:36.933Z'link:is_container: falseis_root: false@@ -4012,8 +4009,8 @@ paths:lft: 8rgt: 9depth: 1- created_at: '2021-11-08T15:18:07.983Z'- updated_at: '2021-11-08T15:18:07.990Z'+ created_at: '2021-11-09T11:27:37.641Z'+ updated_at: '2021-11-09T11:27:37.647Z'link:is_container: falseis_root: false@@ -4101,8 +4098,8 @@ paths:lft: 8rgt: 9depth: 1- created_at: '2021-11-08T15:18:09.260Z'- updated_at: '2021-11-08T15:18:09.297Z'+ created_at: '2021-11-09T11:27:38.810Z'+ updated_at: '2021-11-09T11:27:38.847Z'link:is_container: falseis_root: false@@ -4239,8 +4236,8 @@ paths:lft: 5rgt: 6depth: 2- created_at: '2021-11-08T15:18:12.199Z'- updated_at: '2021-11-08T15:18:12.240Z'+ created_at: '2021-11-09T11:27:41.566Z'+ updated_at: '2021-11-09T11:27:41.601Z'link:is_container: falseis_root: false@@ -4344,8 +4341,8 @@ paths:name: Main Menulocation: headerlocale: en- created_at: '2021-11-08T15:18:13.061Z'- updated_at: '2021-11-08T15:18:13.263Z'+ created_at: '2021-11-09T11:27:42.398Z'+ updated_at: '2021-11-09T11:27:42.587Z'relationships:menu_items:data:@@ -4361,8 +4358,8 @@ paths:name: Footer Menulocation: footerlocale: en- created_at: '2021-11-08T15:18:13.075Z'- updated_at: '2021-11-08T15:18:13.460Z'+ created_at: '2021-11-09T11:27:42.411Z'+ updated_at: '2021-11-09T11:27:42.768Z'relationships:menu_items:data:@@ -4425,8 +4422,8 @@ paths:name: Main Menulocation: headerlocale: en- created_at: '2021-11-08T15:18:14.007Z'- updated_at: '2021-11-08T15:18:14.016Z'+ created_at: '2021-11-09T11:27:43.285Z'+ updated_at: '2021-11-09T11:27:43.293Z'relationships:menu_items:data:@@ -4494,8 +4491,8 @@ paths:name: Main Menulocation: headerlocale: en- created_at: '2021-11-08T15:18:14.098Z'- updated_at: '2021-11-08T15:18:14.108Z'+ created_at: '2021-11-09T11:27:43.365Z'+ updated_at: '2021-11-09T11:27:43.373Z'relationships:menu_items:data:@@ -4559,8 +4556,8 @@ paths:name: Main Menulocation: headerlocale: en- created_at: '2021-11-08T15:18:14.237Z'- updated_at: '2021-11-08T15:18:14.250Z'+ created_at: '2021-11-09T11:27:43.487Z'+ updated_at: '2021-11-09T11:27:43.495Z'relationships:menu_items:data:@@ -4695,8 +4692,8 @@ paths:name: foo-size-68presentation: Sizeposition: 1- created_at: '2021-11-08T15:18:14.575Z'- updated_at: '2021-11-08T15:18:14.575Z'+ created_at: '2021-11-09T11:27:43.775Z'+ updated_at: '2021-11-09T11:27:43.775Z'filterable: truepublic_metadata: {}private_metadata: {}@@ -4709,8 +4706,8 @@ paths:name: foo-size-69presentation: Sizeposition: 2- created_at: '2021-11-08T15:18:14.577Z'- updated_at: '2021-11-08T15:18:14.577Z'+ created_at: '2021-11-09T11:27:43.777Z'+ updated_at: '2021-11-09T11:27:43.777Z'filterable: truepublic_metadata: {}private_metadata: {}@@ -4763,8 +4760,8 @@ paths:name: foo-size-72presentation: Sizeposition: 1- created_at: '2021-11-08T15:18:14.676Z'- updated_at: '2021-11-08T15:18:14.676Z'+ created_at: '2021-11-09T11:27:43.874Z'+ updated_at: '2021-11-09T11:27:43.874Z'filterable: truepublic_metadata: {}private_metadata: {}@@ -4823,8 +4820,8 @@ paths:name: foo-size-73presentation: Sizeposition: 1- created_at: '2021-11-08T15:18:14.744Z'- updated_at: '2021-11-08T15:18:14.744Z'+ created_at: '2021-11-09T11:27:43.938Z'+ updated_at: '2021-11-09T11:27:43.938Z'filterable: truepublic_metadata: {}private_metadata: {}@@ -4882,8 +4879,8 @@ paths:name: Size-Xpresentation: Sizeposition: 1- created_at: '2021-11-08T15:18:14.856Z'- updated_at: '2021-11-08T15:18:14.867Z'+ created_at: '2021-11-09T11:27:44.032Z'+ updated_at: '2021-11-09T11:27:44.043Z'filterable: truepublic_metadata: {}private_metadata: {}@@ -5021,8 +5018,8 @@ paths:position: 1name: Size-68presentation: S- created_at: '2021-11-08T15:18:15.105Z'- updated_at: '2021-11-08T15:18:15.105Z'+ created_at: '2021-11-09T11:27:44.263Z'+ updated_at: '2021-11-09T11:27:44.263Z'public_metadata: {}private_metadata: {}relationships:@@ -5036,8 +5033,8 @@ paths:position: 1name: Size-69presentation: S- created_at: '2021-11-08T15:18:15.113Z'- updated_at: '2021-11-08T15:18:15.113Z'+ created_at: '2021-11-09T11:27:44.270Z'+ updated_at: '2021-11-09T11:27:44.270Z'public_metadata: {}private_metadata: {}relationships:@@ -5098,8 +5095,8 @@ paths:position: 1name: Size-72presentation: S- created_at: '2021-11-08T15:18:15.217Z'- updated_at: '2021-11-08T15:18:15.217Z'+ created_at: '2021-11-09T11:27:44.367Z'+ updated_at: '2021-11-09T11:27:44.367Z'public_metadata: {}private_metadata: {}relationships:@@ -5164,8 +5161,8 @@ paths:position: 1name: Size-73presentation: S- created_at: '2021-11-08T15:18:15.297Z'- updated_at: '2021-11-08T15:18:15.297Z'+ created_at: '2021-11-09T11:27:44.438Z'+ updated_at: '2021-11-09T11:27:44.438Z'public_metadata: {}private_metadata: {}relationships:@@ -5231,8 +5228,8 @@ paths:position: 1name: Mpresentation: S- created_at: '2021-11-08T15:18:15.410Z'- updated_at: '2021-11-08T15:18:15.422Z'+ created_at: '2021-11-09T11:27:44.540Z'+ updated_at: '2021-11-09T11:27:44.553Z'public_metadata: {}private_metadata: {}relationships:@@ -5362,7 +5359,7 @@ paths:- id: '40'type: orderattributes:- number: R741041176+ number: R628635020item_total: '0.0'total: '0.0'state: cart@@ -5371,10 +5368,10 @@ paths:payment_total: '0.0'shipment_state:payment_state:- email: [email protected]+ email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:15.686Z'- updated_at: '2021-11-08T15:18:15.686Z'+ created_at: '2021-11-09T11:27:44.803Z'+ updated_at: '2021-11-09T11:27:44.803Z'currency: USDlast_ip_address:shipment_total: '0.0'@@ -5405,11 +5402,11 @@ paths:display_ship_total: "$0.00"display_shipment_total: "$0.00"display_total: "$0.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$0.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -5448,7 +5445,7 @@ paths:- id: '41'type: orderattributes:- number: R133945741+ number: R369818473item_total: '0.0'total: '0.0'state: cart@@ -5457,10 +5454,10 @@ paths:payment_total: '0.0'shipment_state:payment_state:- email: [email protected]+ email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:15.702Z'- updated_at: '2021-11-08T15:18:15.702Z'+ created_at: '2021-11-09T11:27:44.815Z'+ updated_at: '2021-11-09T11:27:44.815Z'currency: USDlast_ip_address:shipment_total: '0.0'@@ -5491,11 +5488,11 @@ paths:display_ship_total: "$0.00"display_shipment_total: "$0.00"display_total: "$0.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$0.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -5581,7 +5578,7 @@ paths:id: '44'type: orderattributes:- number: R142516546+ number: R888296862item_total: '0.0'total: '0.0'state: cart@@ -5592,8 +5589,8 @@ paths:payment_state:email:special_instructions:- created_at: '2021-11-08T15:18:16.131Z'- updated_at: '2021-11-08T15:18:16.154Z'+ created_at: '2021-11-09T11:27:45.197Z'+ updated_at: '2021-11-09T11:27:45.214Z'currency: USDlast_ip_address:shipment_total: '0.0'@@ -5624,11 +5621,11 @@ paths:display_ship_total: "$0.00"display_shipment_total: "$0.00"display_total: "$0.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$0.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -5709,7 +5706,7 @@ paths:id: '45'type: orderattributes:- number: R797008104+ number: R740967002item_total: '10.0'total: '110.0'state: delivery@@ -5718,10 +5715,10 @@ paths:payment_total: '0.0'shipment_state:payment_state:- email: [email protected]+ email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:16.226Z'- updated_at: '2021-11-08T15:18:16.411Z'+ created_at: '2021-11-09T11:27:45.273Z'+ updated_at: '2021-11-09T11:27:45.455Z'currency: USDlast_ip_address:shipment_total: '100.0'@@ -5752,11 +5749,11 @@ paths:display_ship_total: "$100.00"display_shipment_total: "$100.00"display_total: "$110.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$110.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -5853,7 +5850,7 @@ paths:id: '47'type: orderattributes:- number: R197706282+ number: R935822382item_total: '10.0'total: '110.0'state: delivery@@ -5864,8 +5861,8 @@ paths:payment_state:email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:16.733Z'- updated_at: '2021-11-08T15:18:16.886Z'+ created_at: '2021-11-09T11:27:45.718Z'+ updated_at: '2021-11-09T11:27:45.860Z'currency: USDlast_ip_address:shipment_total: '100.0'@@ -5896,11 +5893,11 @@ paths:display_ship_total: "$100.00"display_shipment_total: "$100.00"display_total: "$110.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$110.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -6053,7 +6050,7 @@ paths:id: '52'type: orderattributes:- number: R899326450+ number: R744586058item_total: '10.0'total: '110.0'state: payment@@ -6062,10 +6059,10 @@ paths:payment_total: '0.0'shipment_state:payment_state:- email: [email protected]+ email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:18.001Z'- updated_at: '2021-11-08T15:18:18.216Z'+ created_at: '2021-11-09T11:27:46.688Z'+ updated_at: '2021-11-09T11:27:46.875Z'currency: USDlast_ip_address:shipment_total: '100.0'@@ -6096,11 +6093,11 @@ paths:display_ship_total: "$100.00"display_shipment_total: "$100.00"display_total: "$110.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$110.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -6200,7 +6197,7 @@ paths:id: '54'type: orderattributes:- number: R936016062+ number: R837753886item_total: '10.0'total: '110.0'state: payment@@ -6209,10 +6206,10 @@ paths:payment_total: '0.0'shipment_state:payment_state:- email: [email protected]+ email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:18.547Z'- updated_at: '2021-11-08T15:18:18.772Z'+ created_at: '2021-11-09T11:27:47.144Z'+ updated_at: '2021-11-09T11:27:47.315Z'currency: USDlast_ip_address:shipment_total: '100.0'@@ -6243,11 +6240,11 @@ paths:display_ship_total: "$100.00"display_shipment_total: "$100.00"display_total: "$110.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$110.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -6347,19 +6344,19 @@ paths:id: '56'type: orderattributes:- number: R291271768+ number: R763839038item_total: '10.0'total: '110.0'state: completeadjustment_total: '0.0'- completed_at: '2021-11-08T15:18:19.362Z'+ completed_at: '2021-11-09T11:27:47.869Z'payment_total: '0.0'shipment_state: pendingpayment_state: balance_due- email: [email protected]+ email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:19.045Z'- updated_at: '2021-11-08T15:18:19.362Z'+ created_at: '2021-11-09T11:27:47.567Z'+ updated_at: '2021-11-09T11:27:47.869Z'currency: USDlast_ip_address:shipment_total: '100.0'@@ -6390,11 +6387,11 @@ paths:display_ship_total: "$100.00"display_shipment_total: "$100.00"display_total: "$110.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$110.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -6505,7 +6502,7 @@ paths:id: '59'type: orderattributes:- number: R647280035+ number: R943944715item_total: '0.0'total: '0.0'state: cart@@ -6514,10 +6511,10 @@ paths:payment_total: '0.0'shipment_state:payment_state:- email: [email protected]+ email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:19.865Z'- updated_at: '2021-11-08T15:18:20.019Z'+ created_at: '2021-11-09T11:27:48.479Z'+ updated_at: '2021-11-09T11:27:48.625Z'currency: USDlast_ip_address:shipment_total: '0.0'@@ -6548,11 +6545,11 @@ paths:display_ship_total: "$0.00"display_shipment_total: "$0.00"display_total: "$0.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$0.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -6647,7 +6644,7 @@ paths:id: '61'type: orderattributes:- number: R196770148+ number: R531982411item_total: '10.0'total: '110.0'state: delivery@@ -6656,10 +6653,10 @@ paths:payment_total: '0.0'shipment_state:payment_state:- email: [email protected]+ email: [email protected]special_instructions:- created_at: '2021-11-08T15:18:20.308Z'- updated_at: '2021-11-08T15:18:20.438Z'+ created_at: '2021-11-09T11:27:48.876Z'+ updated_at: '2021-11-09T11:27:48.997Z'currency: USDlast_ip_address:shipment_total: '100.0'@@ -6690,11 +6687,11 @@ paths:display_ship_total: "$100.00"display_shipment_total: "$100.00"display_total: "$110.00"- display_total_available_store_credit: "$0.00"- display_store_credit_remaining_after_capture: "$0.00"display_total_applicable_store_credit: "$0.00"display_total_applied_store_credit: "$0.00"display_order_total_after_store_credit: "$110.00"+ display_total_available_store_credit: "$0.00"+ display_store_credit_remaining_after_capture: "$0.00"relationships:user:data:@@ -6962,8 +6959,8 @@ paths:display_on: bothauto_capture:position: 1- created_at: '2021-11-08T15:18:22.890Z'- updated_at: '2021-11-08T15:18:22.890Z'+ created_at: '2021-11-09T11:27:51.177Z'+ updated_at: '2021-11-09T11:27:51.177Z'deleted_at:public_metadata: {}private_metadata: {}@@ -6983,8 +6980,8 @@ paths:display_on: bothauto_capture:position: 2- created_at: '2021-11-08T15:18:22.900Z'- updated_at: '2021-11-08T15:18:22.900Z'+ created_at: '2021-11-09T11:27:51.187Z'+ updated_at: '2021-11-09T11:27:51.187Z'deleted_at:public_metadata: {}private_metadata: {}@@ -7004,8 +7001,8 @@ paths:display_on: bothauto_capture:position: 3- created_at: '2021-11-08T15:18:22.907Z'- updated_at: '2021-11-08T15:18:22.907Z'+ created_at: '2021-11-09T11:27:51.193Z'+ updated_at: '2021-11-09T11:27:51.193Z'deleted_at:public_metadata: {}private_metadata: {}@@ -7025,8 +7022,8 @@ paths:display_on: bothauto_capture:position: 4- created_at: '2021-11-08T15:18:22.913Z'- updated_at: '2021-11-08T15:18:22.913Z'+ created_at: '2021-11-09T11:27:51.198Z'+ updated_at: '2021-11-09T11:27:51.198Z'deleted_at:public_metadata: {}private_metadata: {}@@ -7049,8 +7046,8 @@ paths:display_on: bothauto_capture:position: 5- created_at: '2021-11-08T15:18:22.920Z'- updated_at: '2021-11-08T15:18:22.920Z'+ created_at: '2021-11-09T11:27:51.204Z'+ updated_at: '2021-11-09T11:27:51.204Z'deleted_at:public_metadata: {}private_metadata: {}@@ -7120,8 +7117,8 @@ paths:display_on: bothauto_capture:position: 3- created_at: '2021-11-08T15:18:23.135Z'- updated_at: '2021-11-08T15:18:23.135Z'+ created_at: '2021-11-09T11:27:51.383Z'+ updated_at: '2021-11-09T11:27:51.383Z'deleted_at:public_metadata: {}private_metadata: {}@@ -7197,8 +7194,8 @@ paths:display_on: bothauto_capture:position: 4- created_at: '2021-11-08T15:18:23.276Z'- updated_at: '2021-11-08T15:18:23.276Z'+ created_at: '2021-11-09T11:27:51.510Z'+ updated_at: '2021-11-09T11:27:51.510Z'deleted_at:public_metadata: {}private_metadata: {}@@ -7273,8 +7270,8 @@ paths:display_on: bothauto_capture:position: 3- created_at: '2021-11-08T15:18:23.472Z'- updated_at: '2021-11-08T15:18:23.488Z'+ created_at: '2021-11-09T11:27:51.693Z'+ updated_at: '2021-11-09T11:27:51.707Z'deleted_at:public_metadata: {}private_metadata: {}@@ -7422,9 +7419,9 @@ paths:state: invalidresponse_code: '12345'avs_response:- created_at: '2021-11-08T15:18:23.977Z'- updated_at: '2021-11-08T15:18:24.007Z'- number: PS7WMFE0+ created_at: '2021-11-09T11:27:52.145Z'+ updated_at: '2021-11-09T11:27:52.171Z'+ number: PRZBNPR1cvv_response_code:cvv_response_message:public_metadata: {}@@ -7461,9 +7458,9 @@ paths:state: checkoutresponse_code: '12345'avs_response:- created_at: '2021-11-08T15:18:24.002Z'- updated_at: '2021-11-08T15:18:24.002Z'- number: PS2D9K0O+ created_at: '2021-11-09T11:27:52.166Z'+ updated_at: '2021-11-09T11:27:52.166Z'+ number: PEHEBTK3cvv_response_code:cvv_response_message:public_metadata: {}@@ -7551,9 +7548,9 @@ paths:state: checkoutresponse_code: '12345'avs_response:- created_at: '2021-11-08T15:18:24.268Z'- updated_at: '2021-11-08T15:18:24.268Z'- number: PW8TW80F+ created_at: '2021-11-09T11:27:52.400Z'+ updated_at: '2021-11-09T11:27:52.400Z'+ number: PPAX2BOIcvv_response_code:cvv_response_message:public_metadata: {}@@ -7691,8 +7688,8 @@ paths:type: promotion_categoryattributes:name: Promotion Category- created_at: '2021-11-08T15:18:24.645Z'- updated_at: '2021-11-08T15:18:24.645Z'+ created_at: '2021-11-09T11:27:52.742Z'+ updated_at: '2021-11-09T11:27:52.742Z'code: POP123relationships:promotions:@@ -7701,8 +7698,8 @@ paths:type: promotion_categoryattributes:name: Promotion Category- created_at: '2021-11-08T15:18:24.647Z'- updated_at: '2021-11-08T15:18:24.647Z'+ created_at: '2021-11-09T11:27:52.743Z'+ updated_at: '2021-11-09T11:27:52.743Z'code: POP123relationships:promotions:@@ -7758,8 +7755,8 @@ paths:type: promotion_categoryattributes:name: Promotion Category- created_at: '2021-11-08T15:18:24.734Z'- updated_at: '2021-11-08T15:18:24.734Z'+ created_at: '2021-11-09T11:27:52.829Z'+ updated_at: '2021-11-09T11:27:52.829Z'code: 2021-BFMrelationships:promotions:@@ -7819,8 +7816,8 @@ paths:type: promotion_categoryattributes:name: Promotion Category- created_at: '2021-11-08T15:18:24.806Z'- updated_at: '2021-11-08T15:18:24.806Z'+ created_at: '2021-11-09T11:27:52.895Z'+ updated_at: '2021-11-09T11:27:52.895Z'code: MJOrelationships:promotions:@@ -7881,8 +7878,8 @@ paths:type: promotion_categoryattributes:name: 2021 Promotions- created_at: '2021-11-08T15:18:24.919Z'- updated_at: '2021-11-08T15:18:24.928Z'+ created_at: '2021-11-09T11:27:52.992Z'+ updated_at: '2021-11-09T11:27:53.001Z'code: 2021-Promosrelationships:promotions:@@ -8003,14 +8000,14 @@ paths:type: roleattributes:name: 'Role #1'- created_at: '2021-11-08T15:18:25.297Z'- updated_at: '2021-11-08T15:18:25.297Z'+ created_at: '2021-11-09T11:27:53.207Z'+ updated_at: '2021-11-09T11:27:53.207Z'- id: '2'type: roleattributes:name: 'Role #2'- created_at: '2021-11-08T15:18:25.299Z'- updated_at: '2021-11-08T15:18:25.299Z'+ created_at: '2021-11-09T11:27:53.209Z'+ updated_at: '2021-11-09T11:27:53.209Z'meta:count: 2total_count: 2@@ -8055,8 +8052,8 @@ paths:type: roleattributes:name: 'Role #5'- created_at: '2021-11-08T15:18:25.397Z'- updated_at: '2021-11-08T15:18:25.397Z'+ created_at: '2021-11-09T11:27:53.296Z'+ updated_at: '2021-11-09T11:27:53.296Z'schema:"$ref": "#/components/schemas/resource"'422':@@ -8105,8 +8102,8 @@ paths:type: roleattributes:name: 'Role #6'- created_at: '2021-11-08T15:18:25.459Z'- updated_at: '2021-11-08T15:18:25.459Z'+ created_at: '2021-11-09T11:27:53.355Z'+ updated_at: '2021-11-09T11:27:53.355Z'schema:"$ref": "#/components/schemas/resource"'404':@@ -8156,8 +8153,8 @@ paths:type: roleattributes:name: administrator- created_at: '2021-11-08T15:18:25.555Z'- updated_at: '2021-11-08T15:18:25.564Z'+ created_at: '2021-11-09T11:27:53.455Z'+ updated_at: '2021-11-09T11:27:53.463Z'schema:"$ref": "#/components/schemas/resource"'422':@@ -8281,12 +8278,12 @@ paths:type: shipmentattributes:tracking: U10000- number: H78041163696+ number: H44064496615cost: '100.0'shipped_at:state: pending- created_at: '2021-11-08T15:18:25.806Z'- updated_at: '2021-11-08T15:18:25.810Z'+ created_at: '2021-11-09T11:27:53.690Z'+ updated_at: '2021-11-09T11:27:53.695Z'adjustment_total: '0.0'additional_tax_total: '0.0'promo_total: '0.0'@@ -8297,8 +8294,8 @@ paths:public_metadata: {}private_metadata: {}display_cost: "$100.00"- display_discounted_cost: "$100.00"display_item_cost: "$0.00"+ display_discounted_cost: "$100.00"display_final_price: "$100.00"display_amount: "$100.00"relationships:@@ -8330,12 +8327,12 @@ paths:type: shipmentattributes:tracking: U10000- number: H27823566859+ number: H74585843112cost: '100.0'shipped_at:state: pending- created_at: '2021-11-08T15:18:25.855Z'- updated_at: '2021-11-08T15:18:25.860Z'+ created_at: '2021-11-09T11:27:53.734Z'+ updated_at: '2021-11-09T11:27:53.739Z'adjustment_total: '0.0'additional_tax_total: '0.0'promo_total: '0.0'@@ -8346,8 +8343,8 @@ paths:public_metadata: {}private_metadata: {}display_cost: "$100.00"- display_discounted_cost: "$100.00"display_item_cost: "$0.00"+ display_discounted_cost: "$100.00"display_final_price: "$100.00"display_amount: "$100.00"relationships:@@ -8432,12 +8429,12 @@ paths:type: shipmentattributes:tracking: U10000- number: H20858024056+ number: H91252351044cost: '100.0'shipped_at:state: pending- created_at: '2021-11-08T15:18:26.338Z'- updated_at: '2021-11-08T15:18:26.376Z'+ created_at: '2021-11-09T11:27:54.164Z'+ updated_at: '2021-11-09T11:27:54.190Z'adjustment_total: '0.0'additional_tax_total: '0.0'promo_total: '0.0'@@ -8448,8 +8445,8 @@ paths:public_metadata: {}private_metadata: {}display_cost: "$100.00"- display_discounted_cost: "$100.00"display_item_cost: "$10.00"+ display_discounted_cost: "$100.00"display_final_price: "$100.00"display_amount: "$100.00"relationships:@@ -8573,12 +8570,12 @@ paths:type: shipmentattributes:tracking: U10000- number: H02485827676+ number: H24297189907cost: '100.0'shipped_at:state: ready- created_at: '2021-11-08T15:18:27.809Z'- updated_at: '2021-11-08T15:18:27.867Z'+ created_at: '2021-11-09T11:27:55.366Z'+ updated_at: '2021-11-09T11:27:55.413Z'adjustment_total: '0.0'additional_tax_total: '0.0'promo_total: '0.0'@@ -8589,8 +8586,8 @@ paths:public_metadata: {}private_metadata: {}display_cost: "$100.00"- display_discounted_cost: "$100.00"display_item_cost: "$10.00"+ display_discounted_cost: "$100.00"display_final_price: "$100.00"display_amount: "$100.00"relationships:@@ -8679,12 +8676,12 @@ paths:type: shipmentattributes:tracking: U10000- number: H71236205853+ number: H62964635302cost: '100.0'- shipped_at: '2021-11-08T15:18:28.576Z'+ shipped_at: '2021-11-09T11:27:56.037Z'state: shipped- created_at: '2021-11-08T15:18:28.524Z'- updated_at: '2021-11-08T15:18:28.576Z'+ created_at: '2021-11-09T11:27:55.991Z'+ updated_at: '2021-11-09T11:27:56.037Z'adjustment_total: '0.0'additional_tax_total: '0.0'promo_total: '0.0'@@ -8695,8 +8692,8 @@ paths:public_metadata: {}private_metadata: {}display_cost: "$100.00"- display_discounted_cost: "$100.00"display_item_cost: "$10.00"+ display_discounted_cost: "$100.00"display_final_price: "$100.00"display_amount: "$100.00"relationships:@@ -8785,12 +8782,12 @@ paths:type: shipmentattributes:tracking: U10000- number: H83042622495+ number: H35894389626cost: '100.0'shipped_at:state: canceled- created_at: '2021-11-08T15:18:29.234Z'- updated_at: '2021-11-08T15:18:29.274Z'+ created_at: '2021-11-09T11:27:56.625Z'+ updated_at: '2021-11-09T11:27:56.664Z'adjustment_total: '0.0'additional_tax_total: '0.0'promo_total: '0.0'@@ -8801,8 +8798,8 @@ paths:public_metadata: {}private_metadata: {}display_cost: "$100.00"- display_discounted_cost: "$100.00"display_item_cost: "$10.00"+ display_discounted_cost: "$100.00"display_final_price: "$100.00"display_amount: "$100.00"relationships:@@ -8891,12 +8888,12 @@ paths:type: shipmentattributes:tracking: U10000- number: H36395903719+ number: H04749971676cost: '100.0'shipped_at:state: ready- created_at: '2021-11-08T15:18:29.941Z'- updated_at: '2021-11-08T15:18:29.985Z'+ created_at: '2021-11-09T11:27:57.270Z'+ updated_at: '2021-11-09T11:27:57.312Z'adjustment_total: '0.0'additional_tax_total: '0.0'promo_total: '0.0'@@ -8907,8 +8904,8 @@ paths:public_metadata: {}private_metadata: {}display_cost: "$100.00"- display_discounted_cost: "$100.00"display_item_cost: "$10.00"+ display_discounted_cost: "$100.00"display_final_price: "$100.00"display_amount: "$100.00"relationships:@@ -8997,12 +8994,12 @@ paths:type: shipmentattributes:tracking: U10000- number: H71956341575+ number: H18373719662cost: '100.0'shipped_at:state: pending- created_at: '2021-11-08T15:18:30.667Z'- updated_at: '2021-11-08T15:18:30.714Z'+ created_at: '2021-11-09T11:27:57.902Z'+ updated_at: '2021-11-09T11:27:57.940Z'adjustment_total: '0.0'additional_tax_total: '0.0'promo_total: '0.0'@@ -9013,8 +9010,8 @@ paths:public_metadata: {}private_metadata: {}display_cost: "$100.00"- display_discounted_cost: "$100.00"display_item_cost: "$10.00"+ display_discounted_cost: "$100.00"display_final_price: "$100.00"display_amount: "$100.00"relationships:@@ -9107,14 +9104,14 @@ paths:type: shipping_categoryattributes:name: 'ShippingCategory #116'- created_at: '2021-11-08T15:18:31.118Z'- updated_at: '2021-11-08T15:18:31.118Z'+ created_at: '2021-11-09T11:27:58.303Z'+ updated_at: '2021-11-09T11:27:58.303Z'- id: '117'type: shipping_categoryattributes:name: 'ShippingCategory #117'- created_at: '2021-11-08T15:18:31.120Z'- updated_at: '2021-11-08T15:18:31.120Z'+ created_at: '2021-11-09T11:27:58.304Z'+ updated_at: '2021-11-09T11:27:58.304Z'meta:count: 2total_count: 2@@ -9159,8 +9156,8 @@ paths:type: shipping_categoryattributes:name: 'ShippingCategory #120'- created_at: '2021-11-08T15:18:31.208Z'- updated_at: '2021-11-08T15:18:31.208Z'+ created_at: '2021-11-09T11:27:58.395Z'+ updated_at: '2021-11-09T11:27:58.395Z'schema:"$ref": "#/components/schemas/resource"'422':@@ -9209,8 +9206,8 @@ paths:type: shipping_categoryattributes:name: 'ShippingCategory #121'- created_at: '2021-11-08T15:18:31.285Z'- updated_at: '2021-11-08T15:18:31.285Z'+ created_at: '2021-11-09T11:27:58.459Z'+ updated_at: '2021-11-09T11:27:58.459Z'schema:"$ref": "#/components/schemas/resource"'404':@@ -9260,8 +9257,8 @@ paths:type: shipping_categoryattributes:name: Default- created_at: '2021-11-08T15:18:31.383Z'- updated_at: '2021-11-08T15:18:31.393Z'+ created_at: '2021-11-09T11:27:58.562Z'+ updated_at: '2021-11-09T11:27:58.571Z'schema:"$ref": "#/components/schemas/resource"'422':@@ -9395,8 +9392,8 @@ paths:admin_name:display_on: bothtracking_url:- created_at: '2021-11-08T15:18:31.627Z'- updated_at: '2021-11-08T15:18:31.627Z'+ created_at: '2021-11-09T11:27:58.788Z'+ updated_at: '2021-11-09T11:27:58.788Z'deleted_at:public_metadata: {}private_metadata: {}@@ -9421,8 +9418,8 @@ paths:admin_name:display_on: bothtracking_url:- created_at: '2021-11-08T15:18:31.648Z'- updated_at: '2021-11-08T15:18:31.648Z'+ created_at: '2021-11-09T11:27:58.802Z'+ updated_at: '2021-11-09T11:27:58.802Z'deleted_at:public_metadata: {}private_metadata: {}@@ -9494,8 +9491,8 @@ paths:admin_name: DHL Express- Zone Adisplay_on: bothtracking_url:- created_at: '2021-11-08T15:18:31.788Z'- updated_at: '2021-11-08T15:18:31.788Z'+ created_at: '2021-11-09T11:27:58.937Z'+ updated_at: '2021-11-09T11:27:58.937Z'deleted_at:public_metadata: {}private_metadata: {}@@ -9581,8 +9578,8 @@ paths:admin_name:display_on: bothtracking_url:- created_at: '2021-11-08T15:18:31.875Z'- updated_at: '2021-11-08T15:18:31.875Z'+ created_at: '2021-11-09T11:27:59.015Z'+ updated_at: '2021-11-09T11:27:59.015Z'deleted_at:public_metadata: {}private_metadata: {}@@ -9659,8 +9656,8 @@ paths:admin_name:display_on: bothtracking_url:- created_at: '2021-11-08T15:18:32.012Z'- updated_at: '2021-11-08T15:18:32.036Z'+ created_at: '2021-11-09T11:27:59.151Z'+ updated_at: '2021-11-09T11:27:59.172Z'deleted_at:public_metadata: {}private_metadata: {}@@ -9754,6 +9751,501 @@ paths:error: The access token is invalidschema:"$ref": "#/components/schemas/error"+ "/api/v2/platform/store_credits":+ get:+ summary: Return a list of Store Credits+ tags:+ - Store Credits+ security:+ - bearer_auth: []+ description: Returns a list of Store Credits+ operationId: store-credits-list+ parameters:+ - name: page+ in: query+ example: 1+ schema:+ type: integer+ - name: per_page+ in: query+ example: 50+ schema:+ type: integer+ - name: include+ in: query+ description: 'Select which associated resources you would like to fetch, see:+ <a href="https://jsonapi.org/format/#fetching-includes">https://jsonapi.org/format/#fetching-includes</a>'+ example: user,created_by,category,credit_type+ schema:+ type: string+ - name: filter[user_id_eq]+ in: query+ description: ''+ example: '5'+ schema:+ type: string+ - name: filter[created_by_id_eq]+ in: query+ description: ''+ example: '2'+ schema:+ type: string+ - name: filter[amount_gteq]+ in: query+ description: ''+ example: 50.0+ schema:+ type: string+ - name: filter[currency_eq]+ in: query+ description: ''+ example: USD+ schema:+ type: string+ responses:+ '200':+ description: Records returned+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ data:+ - id: '2'+ type: store_credit+ attributes:+ amount: '150.0'+ amount_used: '0.0'+ memo:+ deleted_at:+ currency: USD+ amount_authorized: '0.0'+ originator_type:+ created_at: '2021-11-09T11:27:59.462Z'+ updated_at: '2021-11-09T11:27:59.462Z'+ public_metadata: {}+ private_metadata: {}+ display_amount_used: "$0.00"+ display_amount: "$150.00"+ relationships:+ user:+ data:+ id: '97'+ type: user+ created_by:+ data:+ id: '98'+ type: user+ store_credit_category:+ data:+ id: '2'+ type: store_credit_category+ store_credit_type:+ data:+ id: '2'+ type: store_credit_type+ store_credit_events:+ data:+ - id: '3'+ type: store_credit_event+ - id: '3'+ type: store_credit+ attributes:+ amount: '150.0'+ amount_used: '0.0'+ memo:+ deleted_at:+ currency: USD+ amount_authorized: '0.0'+ originator_type:+ created_at: '2021-11-09T11:27:59.472Z'+ updated_at: '2021-11-09T11:27:59.472Z'+ public_metadata: {}+ private_metadata: {}+ display_amount_used: "$0.00"+ display_amount: "$150.00"+ relationships:+ user:+ data:+ id: '97'+ type: user+ created_by:+ data:+ id: '99'+ type: user+ store_credit_category:+ data:+ id: '3'+ type: store_credit_category+ store_credit_type:+ data:+ id: '3'+ type: store_credit_type+ store_credit_events:+ data:+ - id: '4'+ type: store_credit_event+ meta:+ count: 2+ total_count: 2+ total_pages: 1+ links:+ self: http://www.example.com/api/v2/platform/store_credits?page=1&per_page=&include=&filter[user_id_eq]=&filter[created_by_id_eq]=&filter[amount_gteq]=&filter[currency_eq]=+ next: http://www.example.com/api/v2/platform/store_credits?filter%5Bamount_gteq%5D=&filter%5Bcreated_by_id_eq%5D=&filter%5Bcurrency_eq%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=+ prev: http://www.example.com/api/v2/platform/store_credits?filter%5Bamount_gteq%5D=&filter%5Bcreated_by_id_eq%5D=&filter%5Bcurrency_eq%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=+ last: http://www.example.com/api/v2/platform/store_credits?filter%5Bamount_gteq%5D=&filter%5Bcreated_by_id_eq%5D=&filter%5Bcurrency_eq%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=+ first: http://www.example.com/api/v2/platform/store_credits?filter%5Bamount_gteq%5D=&filter%5Bcreated_by_id_eq%5D=&filter%5Bcurrency_eq%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=+ schema:+ "$ref": "#/components/schemas/resources_list"+ '401':+ description: Authentication Failed+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: The access token is invalid+ schema:+ "$ref": "#/components/schemas/error"+ post:+ summary: Create a Store Credit+ tags:+ - Store Credits+ security:+ - bearer_auth: []+ description: Creates a Store Credit+ operationId: create-store-credit+ parameters:+ - name: include+ in: query+ description: 'Select which associated resources you would like to fetch, see:+ <a href="https://jsonapi.org/format/#fetching-includes">https://jsonapi.org/format/#fetching-includes</a>'+ example: user,created_by,category,credit_type+ schema:+ type: string+ responses:+ '201':+ description: Record created+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ data:+ id: '6'+ type: store_credit+ attributes:+ amount: '150.0'+ amount_used: '0.0'+ memo:+ deleted_at:+ currency: USD+ amount_authorized: '0.0'+ originator_type:+ created_at: '2021-11-09T11:27:59.613Z'+ updated_at: '2021-11-09T11:27:59.613Z'+ public_metadata: {}+ private_metadata: {}+ display_amount_used: "$0.00"+ display_amount: "$150.00"+ relationships:+ user:+ data:+ id: '103'+ type: user+ created_by:+ data:+ id: '104'+ type: user+ store_credit_category:+ data:+ id: '6'+ type: store_credit_category+ store_credit_type:+ data:+ id: '6'+ type: store_credit_type+ store_credit_events:+ data:+ - id: '7'+ type: store_credit_event+ schema:+ "$ref": "#/components/schemas/resource"+ '422':+ description: Invalid request+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: User can't be blank, Category can't be blank, Credit type+ can't be blank, Created by can't be blank, Currency can't be+ blank, Amount must be greater than 0, Amount used Cannot be+ greater than amount., and Amount authorized Exceeds total credits.+ errors:+ user:+ - can't be blank+ category:+ - can't be blank+ credit_type:+ - can't be blank+ created_by:+ - can't be blank+ currency:+ - can't be blank+ amount:+ - must be greater than 0+ amount_used:+ - Cannot be greater than amount.+ amount_authorized:+ - Exceeds total credits.+ schema:+ "$ref": "#/components/schemas/validation_errors"+ requestBody:+ content:+ application/json:+ schema:+ "$ref": "#/components/schemas/create_store_credit_params"+ "/api/v2/platform/store_credits/{id}":+ get:+ summary: Return a Store Credit+ tags:+ - Store Credits+ security:+ - bearer_auth: []+ description: Returns a Store Credit+ operationId: show-store-credit+ parameters:+ - name: id+ in: path+ required: true+ schema:+ type: string+ - name: include+ in: query+ description: 'Select which associated resources you would like to fetch, see:+ <a href="https://jsonapi.org/format/#fetching-includes">https://jsonapi.org/format/#fetching-includes</a>'+ example: user,created_by,category,credit_type+ schema:+ type: string+ responses:+ '200':+ description: Record found+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ data:+ id: '7'+ type: store_credit+ attributes:+ amount: '150.0'+ amount_used: '0.0'+ memo:+ deleted_at:+ currency: USD+ amount_authorized: '0.0'+ originator_type:+ created_at: '2021-11-09T11:27:59.693Z'+ updated_at: '2021-11-09T11:27:59.693Z'+ public_metadata: {}+ private_metadata: {}+ display_amount_used: "$0.00"+ display_amount: "$150.00"+ relationships:+ user:+ data:+ id: '105'+ type: user+ created_by:+ data:+ id: '106'+ type: user+ store_credit_category:+ data:+ id: '7'+ type: store_credit_category+ store_credit_type:+ data:+ id: '7'+ type: store_credit_type+ store_credit_events:+ data:+ - id: '8'+ type: store_credit_event+ schema:+ "$ref": "#/components/schemas/resource"+ '404':+ description: Record not found+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: The resource you were looking for could not be found.+ schema:+ "$ref": "#/components/schemas/error"+ '401':+ description: Authentication Failed+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: The access token is invalid+ schema:+ "$ref": "#/components/schemas/error"+ patch:+ summary: Update a Store Credit+ tags:+ - Store Credits+ security:+ - bearer_auth: []+ description: Updates a Store Credit+ operationId: update-store-credit+ parameters:+ - name: id+ in: path+ required: true+ schema:+ type: string+ - name: include+ in: query+ description: 'Select which associated resources you would like to fetch, see:+ <a href="https://jsonapi.org/format/#fetching-includes">https://jsonapi.org/format/#fetching-includes</a>'+ example: user,created_by,category,credit_type+ schema:+ type: string+ responses:+ '200':+ description: Record updated+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ data:+ id: '9'+ type: store_credit+ attributes:+ amount: '500.0'+ amount_used: '0.0'+ memo: The user is awarded+ deleted_at:+ currency: CAD+ amount_authorized: '0.0'+ originator_type:+ created_at: '2021-11-09T11:27:59.819Z'+ updated_at: '2021-11-09T11:27:59.836Z'+ public_metadata:+ loyalty_reward: true+ private_metadata: {}+ display_amount_used: "$0.00"+ display_amount: "$500.00"+ relationships:+ user:+ data:+ id: '109'+ type: user+ created_by:+ data:+ id: '110'+ type: user+ store_credit_category:+ data:+ id: '9'+ type: store_credit_category+ store_credit_type:+ data:+ id: '9'+ type: store_credit_type+ store_credit_events:+ data:+ - id: '10'+ type: store_credit_event+ schema:+ "$ref": "#/components/schemas/resource"+ '422':+ description: Invalid request+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: Amount must be greater than 0, Amount used Cannot be greater+ than amount., and Amount authorized Exceeds total credits.+ errors:+ amount:+ - must be greater than 0+ amount_used:+ - Cannot be greater than amount.+ amount_authorized:+ - Exceeds total credits.+ schema:+ "$ref": "#/components/schemas/validation_errors"+ '404':+ description: Record not found+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: The resource you were looking for could not be found.+ schema:+ "$ref": "#/components/schemas/error"+ '401':+ description: Authentication Failed+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: The access token is invalid+ schema:+ "$ref": "#/components/schemas/error"+ requestBody:+ content:+ application/json:+ schema:+ "$ref": "#/components/schemas/update_store_credit_params"+ delete:+ summary: Delete a Store Credit+ tags:+ - Store Credits+ security:+ - bearer_auth: []+ description: Deletes a Store Credit+ operationId: delete-store-credit+ parameters:+ - name: id+ in: path+ required: true+ schema:+ type: string+ responses:+ '204':+ description: Record deleted+ '404':+ description: Record not found+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: The resource you were looking for could not be found.+ schema:+ "$ref": "#/components/schemas/error"+ '401':+ description: Authentication Failed+ content:+ application/vnd.api+json:+ examples:+ Example:+ value:+ error: The access token is invalid+ schema:+ "$ref": "#/components/schemas/error""/api/v2/platform/tax_categories":get:summary: Return a list of Tax Categories@@ -9811,13 +10303,13 @@ paths:- id: '126'type: tax_categoryattributes:- name: TaxCategory - 647345- description: Quidem esse quibusdam non officiis ducimus hic- nisi rem.+ name: TaxCategory - 706655+ description: Rerum reiciendis asperiores expedita eveniet+ veritatis fugiat.is_default: falsedeleted_at:- created_at: '2021-11-08T15:18:32.484Z'- updated_at: '2021-11-08T15:18:32.484Z'+ created_at: '2021-11-09T11:28:00.107Z'+ updated_at: '2021-11-09T11:28:00.107Z'tax_code:relationships:tax_rates:@@ -9825,13 +10317,12 @@ paths:- id: '127'type: tax_categoryattributes:- name: TaxCategory - 284386- description: Sint autem velit cupiditate reiciendis officia- inventore atque.+ name: TaxCategory - 83786+ description: Nobis vel vero dignissimos porro.is_default: falsedeleted_at:- created_at: '2021-11-08T15:18:32.487Z'- updated_at: '2021-11-08T15:18:32.487Z'+ created_at: '2021-11-09T11:28:00.109Z'+ updated_at: '2021-11-09T11:28:00.109Z'tax_code:relationships:tax_rates:@@ -9886,12 +10377,13 @@ paths:id: '130'type: tax_categoryattributes:- name: TaxCategory - 344693- description: A alias qui quasi molestiae id rem praesentium.+ name: TaxCategory - 428541+ description: Veritatis quam ullam beatae in possimus sit cumque+ consequatur.is_default: falsedeleted_at:- created_at: '2021-11-08T15:18:32.583Z'- updated_at: '2021-11-08T15:18:32.583Z'+ created_at: '2021-11-09T11:28:00.192Z'+ updated_at: '2021-11-09T11:28:00.192Z'tax_code:relationships:tax_rates:@@ -9950,12 +10442,13 @@ paths:id: '131'type: tax_categoryattributes:- name: TaxCategory - 705374- description: Velit quibusdam aspernatur eligendi facere.+ name: TaxCategory - 58287+ description: Possimus eaque aperiam labore suscipit cum quas+ eius.is_default: falsedeleted_at:- created_at: '2021-11-08T15:18:32.654Z'- updated_at: '2021-11-08T15:18:32.654Z'+ created_at: '2021-11-09T11:28:00.259Z'+ updated_at: '2021-11-09T11:28:00.259Z'tax_code:relationships:tax_rates:@@ -10019,8 +10512,8 @@ paths:description: Men's, women's and children's clothingis_default: truedeleted_at:- created_at: '2021-11-08T15:18:32.770Z'- updated_at: '2021-11-08T15:18:32.780Z'+ created_at: '2021-11-09T11:28:00.354Z'+ updated_at: '2021-11-09T11:28:00.364Z'tax_code: 1233Krelationships:tax_rates:@@ -10161,8 +10654,8 @@ paths:attributes:amount: '0.1'included_in_price: false- created_at: '2021-11-08T15:18:33.002Z'- updated_at: '2021-11-08T15:18:33.002Z'+ created_at: '2021-11-09T11:28:00.583Z'+ updated_at: '2021-11-09T11:28:00.583Z'name:show_rate_in_label: truedeleted_at:@@ -10180,8 +10673,8 @@ paths:attributes:amount: '0.1'included_in_price: false- created_at: '2021-11-08T15:18:33.007Z'- updated_at: '2021-11-08T15:18:33.007Z'+ created_at: '2021-11-09T11:28:00.589Z'+ updated_at: '2021-11-09T11:28:00.589Z'name:show_rate_in_label: truedeleted_at:@@ -10246,8 +10739,8 @@ paths:attributes:amount: '0.1'included_in_price: false- created_at: '2021-11-08T15:18:33.120Z'- updated_at: '2021-11-08T15:18:33.120Z'+ created_at: '2021-11-09T11:28:00.702Z'+ updated_at: '2021-11-09T11:28:00.702Z'name:show_rate_in_label: truedeleted_at:@@ -10319,8 +10812,8 @@ paths:attributes:amount: '0.1'included_in_price: false- created_at: '2021-11-08T15:18:33.195Z'- updated_at: '2021-11-08T15:18:33.195Z'+ created_at: '2021-11-09T11:28:00.768Z'+ updated_at: '2021-11-09T11:28:00.768Z'name:show_rate_in_label: truedeleted_at:@@ -10390,8 +10883,8 @@ paths:attributes:amount: '25.9'included_in_price: true- created_at: '2021-11-08T15:18:33.311Z'- updated_at: '2021-11-08T15:18:33.325Z'+ created_at: '2021-11-09T11:28:00.881Z'+ updated_at: '2021-11-09T11:28:00.896Z'name:show_rate_in_label: truedeleted_at:@@ -10538,8 +11031,8 @@ paths:lft: 2rgt: 3description:- created_at: '2021-11-08T15:18:33.676Z'- updated_at: '2021-11-08T15:18:33.681Z'+ created_at: '2021-11-09T11:28:01.238Z'+ updated_at: '2021-11-09T11:28:01.243Z'meta_title:meta_description:meta_keywords:@@ -10575,8 +11068,8 @@ paths:lft: 4rgt: 5description:- created_at: '2021-11-08T15:18:33.767Z'- updated_at: '2021-11-08T15:18:33.773Z'+ created_at: '2021-11-09T11:28:01.328Z'+ updated_at: '2021-11-09T11:28:01.333Z'meta_title:meta_description:meta_keywords:@@ -10612,8 +11105,8 @@ paths:lft: 1rgt: 6description:- created_at: '2021-11-08T15:18:33.591Z'- updated_at: '2021-11-08T15:18:33.786Z'+ created_at: '2021-11-09T11:28:01.149Z'+ updated_at: '2021-11-09T11:28:01.347Z'meta_title:meta_description:meta_keywords:@@ -10696,8 +11189,8 @@ paths:lft: 2rgt: 3description:- created_at: '2021-11-08T15:18:34.164Z'- updated_at: '2021-11-08T15:18:34.170Z'+ created_at: '2021-11-09T11:28:01.717Z'+ updated_at: '2021-11-09T11:28:01.723Z'meta_title:meta_description:meta_keywords:@@ -10784,8 +11277,8 @@ paths:lft: 2rgt: 3description:- created_at: '2021-11-08T15:18:34.355Z'- updated_at: '2021-11-08T15:18:34.361Z'+ created_at: '2021-11-09T11:28:01.895Z'+ updated_at: '2021-11-09T11:28:01.900Z'meta_title:meta_description:meta_keywords:@@ -10875,8 +11368,8 @@ paths:lft: 2rgt: 3description:- created_at: '2021-11-08T15:18:34.724Z'- updated_at: '2021-11-08T15:18:34.761Z'+ created_at: '2021-11-09T11:28:02.255Z'+ updated_at: '2021-11-09T11:28:02.291Z'meta_title:meta_description:meta_keywords:@@ -11029,12 +11522,12 @@ paths:Example:value:data:- - id: '97'+ - id: '119'type: userattributes:- email: [email protected]- created_at: '2021-11-08T15:18:35.535Z'- updated_at: '2021-11-08T15:18:35.535Z'+ email: [email protected]+ created_at: '2021-11-09T11:28:03.062Z'+ updated_at: '2021-11-09T11:28:03.062Z'public_metadata: {}private_metadata: {}average_order_value: []@@ -11045,12 +11538,12 @@ paths:data:ship_address:data:- - id: '98'+ - id: '120'type: userattributes:- email: [email protected]- created_at: '2021-11-08T15:18:35.547Z'- updated_at: '2021-11-08T15:18:35.547Z'+ email: [email protected]+ created_at: '2021-11-09T11:28:03.070Z'+ updated_at: '2021-11-09T11:28:03.070Z'public_metadata: {}private_metadata: {}average_order_value: []@@ -11061,12 +11554,12 @@ paths:data:ship_address:data:- - id: '99'+ - id: '121'type: userattributes:- email: [email protected]- created_at: '2021-11-08T15:18:35.551Z'- updated_at: '2021-11-08T15:18:35.551Z'+ email: [email protected]+ created_at: '2021-11-09T11:28:03.073Z'+ updated_at: '2021-11-09T11:28:03.073Z'public_metadata: {}private_metadata: {}average_order_value: []@@ -11124,12 +11617,12 @@ paths:Example:value:data:- id: '104'+ id: '126'type: userattributes:- email: [email protected]- created_at: '2021-11-08T15:18:35.686Z'- updated_at: '2021-11-08T15:18:35.686Z'+ email: [email protected]+ created_at: '2021-11-09T11:28:03.364Z'+ updated_at: '2021-11-09T11:28:03.364Z'public_metadata: {}private_metadata: {}average_order_value: []@@ -11191,12 +11684,12 @@ paths:Example:value:data:- id: '107'+ id: '129'type: userattributes:- email: [email protected]- created_at: '2021-11-08T15:18:35.774Z'- updated_at: '2021-11-08T15:18:35.774Z'+ email: [email protected]+ created_at: '2021-11-09T11:28:03.454Z'+ updated_at: '2021-11-09T11:28:03.454Z'public_metadata: {}private_metadata: {}average_order_value: []@@ -11259,12 +11752,12 @@ paths:Example:value:data:- id: '112'+ id: '134'type: userattributes:email: [email protected]- created_at: '2021-11-08T15:18:35.915Z'- updated_at: '2021-11-08T15:18:35.926Z'+ created_at: '2021-11-09T11:28:03.579Z'+ updated_at: '2021-11-09T11:28:03.591Z'public_metadata: {}private_metadata: {}average_order_value: []@@ -11413,14 +11906,14 @@ paths:position: 1cost_currency: USDtrack_inventory: true- updated_at: '2021-11-08T15:18:36.265Z'+ updated_at: '2021-11-09T11:28:03.915Z'discontinue_on:- created_at: '2021-11-08T15:18:36.257Z'+ created_at: '2021-11-09T11:28:03.907Z'public_metadata: {}private_metadata: {}display_compare_at_price:display_price: "$19.99"- name: 'Product #181 - 9728'+ name: 'Product #181 - 9861'options_text: ''total_on_hand: 0purchasable: true@@ -11455,23 +11948,23 @@ paths:type: variantattributes:sku: SKU-249- weight: '159.57'- height: '182.38'- depth: '136.17'+ weight: '170.69'+ height: '59.95'+ depth: '16.92'deleted_at:is_master: falsecost_price: '17.0'position: 2cost_currency: USDtrack_inventory: true- updated_at: '2021-11-08T15:18:36.307Z'+ updated_at: '2021-11-09T11:28:03.953Z'discontinue_on:- created_at: '2021-11-08T15:18:36.297Z'+ created_at: '2021-11-09T11:28:03.944Z'public_metadata: {}private_metadata: {}display_compare_at_price:display_price: "$19.99"- name: 'Product #181 - 9728'+ name: 'Product #181 - 9861'options_text: 'Size: S'total_on_hand: 0purchasable: true@@ -11508,23 +12001,23 @@ paths:type: variantattributes:sku: SKU-250- weight: '112.78'- height: '165.94'- depth: '14.61'+ weight: '4.39'+ height: '107.73'+ depth: '58.55'deleted_at:is_master: falsecost_price: '17.0'position: 3cost_currency: USDtrack_inventory: true- updated_at: '2021-11-08T15:18:36.339Z'+ updated_at: '2021-11-09T11:28:03.979Z'discontinue_on:- created_at: '2021-11-08T15:18:36.329Z'+ created_at: '2021-11-09T11:28:03.970Z'public_metadata: {}private_metadata: {}display_compare_at_price:display_price: "$19.99"- name: 'Product #181 - 9728'+ name: 'Product #181 - 9861'options_text: 'Size: S'total_on_hand: 0purchasable: true@@ -11614,23 +12107,23 @@ paths:type: variantattributes:sku: SKU-255- weight: '33.0'- height: '98.3'- depth: '170.71'+ weight: '71.32'+ height: '113.34'+ depth: '157.89'deleted_at:is_master: falsecost_price: '17.0'position: 2cost_currency: USDtrack_inventory: true- updated_at: '2021-11-08T15:18:36.698Z'+ updated_at: '2021-11-09T11:28:04.290Z'discontinue_on:- created_at: '2021-11-08T15:18:36.689Z'+ created_at: '2021-11-09T11:28:04.281Z'public_metadata: {}private_metadata: {}display_compare_at_price:display_price: "$19.99"- name: 'Product #183 - 2883'+ name: 'Product #183 - 4490'options_text: 'Size: S'total_on_hand: 0purchasable: true@@ -11791,14 +12284,14 @@ paths:- id: '1'type: eventattributes:- execution_time: 94066+ execution_time: 90994name: order.canceledrequest_errors: ''response_code: '200'success: trueurl: https://www.url1.com/- created_at: '2021-11-08T15:18:37.256Z'- updated_at: '2021-11-08T15:18:37.256Z'+ created_at: '2021-11-09T11:28:04.777Z'+ updated_at: '2021-11-09T11:28:04.777Z'relationships:subscriber:data:@@ -11807,14 +12300,14 @@ paths:- id: '2'type: eventattributes:- execution_time: 19815+ execution_time: 43449name: order.canceledrequest_errors: ''response_code: '200'success: trueurl: https://www.url2.com/- created_at: '2021-11-08T15:18:37.260Z'- updated_at: '2021-11-08T15:18:37.260Z'+ created_at: '2021-11-09T11:28:04.780Z'+ updated_at: '2021-11-09T11:28:04.780Z'relationships:subscriber:data:@@ -11890,8 +12383,8 @@ paths:active: truesubscriptions:- "*"- created_at: '2021-11-08T15:18:37.359Z'- updated_at: '2021-11-08T15:18:37.359Z'+ created_at: '2021-11-09T11:28:04.861Z'+ updated_at: '2021-11-09T11:28:04.861Z'- id: '6'type: subscriberattributes:@@ -11899,8 +12392,8 @@ paths:active: truesubscriptions:- "*"- created_at: '2021-11-08T15:18:37.360Z'- updated_at: '2021-11-08T15:18:37.360Z'+ created_at: '2021-11-09T11:28:04.862Z'+ updated_at: '2021-11-09T11:28:04.862Z'meta:count: 2total_count: 2@@ -11948,8 +12441,8 @@ paths:active: truesubscriptions:- "*"- created_at: '2021-11-08T15:18:37.448Z'- updated_at: '2021-11-08T15:18:37.448Z'+ created_at: '2021-11-09T11:28:04.953Z'+ updated_at: '2021-11-09T11:28:04.953Z'schema:"$ref": "#/components/schemas/resource"'422':@@ -12004,8 +12497,8 @@ paths:active: truesubscriptions:- "*"- created_at: '2021-11-08T15:18:37.512Z'- updated_at: '2021-11-08T15:18:37.512Z'+ created_at: '2021-11-09T11:28:05.014Z'+ updated_at: '2021-11-09T11:28:05.014Z'schema:"$ref": "#/components/schemas/resource"'404':@@ -12058,8 +12551,8 @@ paths:active: truesubscriptions:- "*"- created_at: '2021-11-08T15:18:37.622Z'- updated_at: '2021-11-08T15:18:37.622Z'+ created_at: '2021-11-09T11:28:05.106Z'+ updated_at: '2021-11-09T11:28:05.106Z'schema:"$ref": "#/components/schemas/resource"'422':@@ -12180,8 +12673,8 @@ paths:type: wished_itemattributes:quantity: 1- created_at: '2021-11-08T15:18:38.036Z'- updated_at: '2021-11-08T15:18:38.036Z'+ created_at: '2021-11-09T11:28:05.507Z'+ updated_at: '2021-11-09T11:28:05.507Z'display_price: "$19.99"display_total: "$19.99"price: '19.99'@@ -12195,8 +12688,8 @@ paths:type: wished_itemattributes:quantity: 1- created_at: '2021-11-08T15:18:38.113Z'- updated_at: '2021-11-08T15:18:38.113Z'+ created_at: '2021-11-09T11:28:05.578Z'+ updated_at: '2021-11-09T11:28:05.578Z'display_price: "$19.99"display_total: "$19.99"price: '19.99'@@ -12210,8 +12703,8 @@ paths:type: wished_itemattributes:quantity: 1- created_at: '2021-11-08T15:18:38.194Z'- updated_at: '2021-11-08T15:18:38.194Z'+ created_at: '2021-11-09T11:28:05.655Z'+ updated_at: '2021-11-09T11:28:05.655Z'display_price: "$19.99"display_total: "$19.99"price: '19.99'@@ -12225,8 +12718,8 @@ paths:type: wished_itemattributes:quantity: 1- created_at: '2021-11-08T15:18:38.269Z'- updated_at: '2021-11-08T15:18:38.269Z'+ created_at: '2021-11-09T11:28:05.724Z'+ updated_at: '2021-11-09T11:28:05.724Z'display_price: "$19.99"display_total: "$19.99"price: '19.99'@@ -12287,8 +12780,8 @@ paths:type: wished_itemattributes:quantity: 1- created_at: '2021-11-08T15:18:39.073Z'- updated_at: '2021-11-08T15:18:39.073Z'+ created_at: '2021-11-09T11:28:06.258Z'+ updated_at: '2021-11-09T11:28:06.258Z'display_price: "$19.99"display_total: "$19.99"price: '19.99'@@ -12358,8 +12851,8 @@ paths:type: wished_itemattributes:quantity: 1- created_at: '2021-11-08T15:18:39.486Z'- updated_at: '2021-11-08T15:18:39.486Z'+ created_at: '2021-11-09T11:28:06.560Z'+ updated_at: '2021-11-09T11:28:06.560Z'display_price: "$19.99"display_total: "$19.99"price: '19.99'@@ -12425,8 +12918,8 @@ paths:type: wished_itemattributes:quantity: 3- created_at: '2021-11-08T15:18:40.065Z'- updated_at: '2021-11-08T15:18:40.076Z'+ created_at: '2021-11-09T11:28:07.056Z'+ updated_at: '2021-11-09T11:28:07.066Z'display_price: "$19.99"display_total: "$59.97"price: '19.99'@@ -12561,9 +13054,9 @@ paths:name: Black Fridayis_private: trueis_default: false- created_at: '2021-11-08T15:18:41.268Z'- updated_at: '2021-11-08T15:18:41.268Z'- token: EmZp9faqzV5xBqRHcrcXt4Ex+ created_at: '2021-11-09T11:28:08.100Z'+ updated_at: '2021-11-09T11:28:08.100Z'+ token: KZHvb2yX7ZhfozCmisyz3hFTvariant_included: falserelationships:wished_items:@@ -12578,9 +13071,9 @@ paths:name: Birthdayis_private: trueis_default: false- created_at: '2021-11-08T15:18:41.270Z'- updated_at: '2021-11-08T15:18:41.270Z'- token: mV37HuqBrj9C1WL5SZbuvoop+ created_at: '2021-11-09T11:28:08.103Z'+ updated_at: '2021-11-09T11:28:08.103Z'+ token: gQ3b51QMu3Z8MSm68cXNYcxevariant_included: falserelationships:wished_items:@@ -12642,9 +13135,9 @@ paths:name: Wishlist_26is_private: trueis_default: false- created_at: '2021-11-08T15:18:42.076Z'- updated_at: '2021-11-08T15:18:42.076Z'- token: dwyVxx1A8ozThKKAxabGYi4R+ created_at: '2021-11-09T11:28:08.781Z'+ updated_at: '2021-11-09T11:28:08.781Z'+ token: Fn3rAnHYePb9d7pB6odK2mUsvariant_included: falserelationships:wished_items:@@ -12708,9 +13201,9 @@ paths:name: My Wishlistis_private: trueis_default: false- created_at: '2021-11-08T15:18:42.160Z'- updated_at: '2021-11-08T15:18:42.160Z'- token: XfnTFx2vsbk7CoGDehsKzMwT+ created_at: '2021-11-09T11:28:08.859Z'+ updated_at: '2021-11-09T11:28:08.859Z'+ token: 486GWKopw2VcEc6dNpa7K2dLvariant_included: falserelationships:wished_items:@@ -12773,9 +13266,9 @@ paths:name: My Super Wishlistis_private: trueis_default: false- created_at: '2021-11-08T15:18:42.284Z'- updated_at: '2021-11-08T15:18:42.296Z'- token: KAn8YXMHYPdc9vorrmwWRJZZ+ created_at: '2021-11-09T11:28:08.999Z'+ updated_at: '2021-11-09T11:28:09.011Z'+ token: 2VhZsBysB8EoVbTowdTcRZyivariant_included: falserelationships:wished_items:@@ -12902,13 +13395,12 @@ paths:- id: '96'type: zoneattributes:- name: Mollitia temporibus quam quas repudiandae.- description: Quibusdam illo ipsum neque rem laborum voluptates- debitis repellat.+ name: Praesentium odio autem iure sequi.+ description: At sunt itaque voluptatibus magni suscipit.default_tax: falsezone_members_count: 0- created_at: '2021-11-08T15:18:42.725Z'- updated_at: '2021-11-08T15:18:42.725Z'+ created_at: '2021-11-09T11:28:09.246Z'+ updated_at: '2021-11-09T11:28:09.246Z'kind: staterelationships:zone_members:@@ -12916,14 +13408,13 @@ paths:- id: '97'type: zoneattributes:- name: Nostrum quas sed reprehenderit suscipit voluptatem repudiandae- minima.- description: Deleniti nobis modi placeat molestias unde quasi- alias natus.+ name: Inventore blanditiis autem rem quo odio officia consectetur.+ description: Delectus maiores ea iusto nisi sequi repellat+ quo similique.default_tax: falsezone_members_count: 0- created_at: '2021-11-08T15:18:42.727Z'- updated_at: '2021-11-08T15:18:42.727Z'+ created_at: '2021-11-09T11:28:09.248Z'+ updated_at: '2021-11-09T11:28:09.248Z'kind: staterelationships:zone_members:@@ -12978,13 +13469,12 @@ paths:id: '100'type: zoneattributes:- name: Perferendis tenetur saepe possimus consequatur voluptatem- alias.- description: Dolorem cupiditate reprehenderit omnis quas earum.+ name: Ratione doloribus error beatae ducimus nemo sequi.+ description: Optio quidem blanditiis nisi minima.default_tax: falsezone_members_count: 0- created_at: '2021-11-08T15:18:42.821Z'- updated_at: '2021-11-08T15:18:42.821Z'+ created_at: '2021-11-09T11:28:09.341Z'+ updated_at: '2021-11-09T11:28:09.341Z'kind: staterelationships:zone_members:@@ -13043,12 +13533,12 @@ paths:id: '101'type: zoneattributes:- name: Labore reiciendis soluta eligendi recusandae ea alias.- description: Cupiditate aperiam sit deserunt a.+ name: Assumenda asperiores cumque possimus enim.+ description: Nobis quod voluptas optio laborum fuga cupiditate.default_tax: falsezone_members_count: 0- created_at: '2021-11-08T15:18:42.883Z'- updated_at: '2021-11-08T15:18:42.883Z'+ created_at: '2021-11-09T11:28:09.402Z'+ updated_at: '2021-11-09T11:28:09.402Z'kind: staterelationships:zone_members:@@ -13112,8 +13602,8 @@ paths:description: The zone containing all EU countriesdefault_tax: falsezone_members_count: 0- created_at: '2021-11-08T15:18:42.989Z'- updated_at: '2021-11-08T15:18:42.999Z'+ created_at: '2021-11-09T11:28:09.496Z'+ updated_at: '2021-11-09T11:28:09.506Z'kind: staterelationships:zone_members:@@ -13222,6 +13712,7 @@ tags:- name: Shipments- name: Shipping Categories- name: Shipping Methods+- name: Store Credits- name: Tax Categories- name: Tax Rates- name: Taxons@@ -15116,7 +15607,7 @@ components:completed_at:type: stringformat: date_time- example: 2021-11-08 15:17:39 UTC+ example: 2021-11-09 11:27:12 UTCbill_address_id:type: stringexample: '1'@@ -15184,7 +15675,7 @@ components:approved_at:type: stringformat: date_time- example: 2021-11-08 15:17:39 UTC+ example: 2021-11-09 11:27:12 UTCconfirmation_delivered:type: booleanexample: true@@ -15255,7 +15746,7 @@ components:completed_at:type: stringformat: date_time- example: 2021-11-08 15:17:39 UTC+ example: 2021-11-09 11:27:12 UTCbill_address_id:type: stringexample: '1'@@ -15323,7 +15814,7 @@ components:approved_at:type: stringformat: date_time- example: 2021-11-08 15:17:39 UTC+ example: 2021-11-09 11:27:12 UTCconfirmation_delivered:type: booleanexample: true@@ -15783,6 +16274,120 @@ components:required:- typex-internal: true+ create_store_credit_params:+ type: object+ properties:+ store_credit:+ type: object+ required:+ - user_id+ - category_id+ - type_id+ - created_by_id+ - currency+ - store_id+ - amount+ properties:+ user_id:+ type: string+ example: '2'+ category_id:+ type: string+ example: '4'+ created_by_id:+ type: string+ example: '5'+ amount:+ type: number+ example: 25.0+ amount_used:+ type: number+ example: 10.0+ memo:+ type: string+ example: This credit was given as a refund+ currency:+ type: string+ example: USD+ amount_authorized:+ type: number+ example: 15.5+ originator_id:+ type: string+ example: '3'+ originator_type:+ type: string+ example: Refund+ type_id:+ type: string+ example: '1'+ store_id:+ type: string+ example: '2'+ public_metadata:+ type: object+ private_metadata:+ type: object+ required:+ - store_credit+ x-internal: true+ update_store_credit_params:+ type: object+ properties:+ store_credit:+ type: object+ required:+ - user_id+ - category_id+ - type_id+ - created_by_id+ - currency+ - store_id+ - amount+ properties:+ user_id:+ type: string+ example: '2'+ category_id:+ type: string+ example: '4'+ created_by_id:+ type: string+ example: '5'+ amount:+ type: number+ example: 25.0+ amount_used:+ type: number+ example: 10.0+ memo:+ type: string+ example: This credit was given as a refund+ currency:+ type: string+ example: USD+ amount_authorized:+ type: number+ example: 15.5+ originator_id:+ type: string+ example: '3'+ originator_type:+ type: string+ example: Refund+ type_id:+ type: string+ example: '1'+ store_id:+ type: string+ example: '2'+ public_metadata:+ type: object+ private_metadata:+ type: object+ required:+ - store_credit+ x-internal: truecreate_tax_category_params:type: objectproperties:diff --git a/api/spec/integration/api/v2/platform/store_credits_spec.rb b/api/spec/integration/api/v2/platform/store_credits_spec.rbnew file mode 100644index 0000000000..aacb65959b--- /dev/null+++ b/api/spec/integration/api/v2/platform/store_credits_spec.rb@@ -0,0 +1,35 @@+require 'swagger_helper'++describe 'Store Credits API', swagger: true do+ include_context 'Platform API v2'++ resource_name = 'Store Credit'+ options = {+ include_example: 'user,created_by,category,credit_type',+ filter_examples: [{ name: 'filter[user_id_eq]', example: '5' },+ { name: 'filter[created_by_id_eq]', example: '2' },+ { name: 'filter[amount_gteq]', example: 50.0 },+ { name: 'filter[currency_eq]', example: 'USD' }]+ }++ let(:user) { create(:user) }+ let(:id) { create(:store_credit, user: user).id }+ let(:records_list) { create_list(:store_credit, 2, user: user) }+ let(:valid_create_param_value) { build(:store_credit, user: user).attributes }+ let(:valid_update_param_value) do+ {+ amount: 500.0,+ memo: 'The user is awarded',+ currency: 'CAD',+ public_metadata: { loyalty_reward: true }+ }+ end+ let(:invalid_param_value) do+ {+ amount: -200,+ store: nil+ }+ end++ include_examples 'CRUD examples', resource_name, options+enddiff --git a/api/spec/swagger_helper.rb b/api/spec/swagger_helper.rbindex c7e4ab429f..5c31797910 100644--- a/api/spec/swagger_helper.rb+++ b/api/spec/swagger_helper.rb@@ -61,6 +61,7 @@ RSpec.configure do |config|{ name: 'Shipments' },{ name: 'Shipping Categories' },{ name: 'Shipping Methods' },+ { name: 'Store Credits' },{ name: 'Tax Categories' },{ name: 'Tax Rates' },{ name: 'Taxons' },@@ -1315,6 +1316,63 @@ RSpec.configure do |config|'x-internal': true},++ # Store Credit+ create_store_credit_params: {+ type: :object,+ properties: {+ store_credit: {+ type: :object,+ required: %w[user_id category_id type_id created_by_id currency store_id amount],+ properties: {+ user_id: { type: :string, example: '2' },+ category_id: { type: :string, example: '4' },+ created_by_id: { type: :string, example: '5' },+ amount: { type: :number, example: 25.0 },+ amount_used: { type: :number, example: 10.0 },+ memo: { type: :string, example: 'This credit was given as a refund' },+ currency: { type: :string, example: 'USD' },+ amount_authorized: { type: :number, example: 15.5 },+ originator_id: { type: :string, example: '3' },+ originator_type: { type: :string, example: 'Refund' },+ type_id: { type: :string, example: '1' },+ store_id: { type: :string, example: '2' },+ public_metadata: { type: :object },+ private_metadata: { type: :object }+ }+ }+ },+ required: %w[store_credit],+ 'x-internal': true+ },+ update_store_credit_params: {+ type: :object,+ properties: {+ store_credit: {+ type: :object,+ required: %w[user_id category_id type_id created_by_id currency store_id amount],+ properties: {+ user_id: { type: :string, example: '2' },+ category_id: { type: :string, example: '4' },+ created_by_id: { type: :string, example: '5' },+ amount: { type: :number, example: 25.0 },+ amount_used: { type: :number, example: 10.0 },+ memo: { type: :string, example: 'This credit was given as a refund' },+ currency: { type: :string, example: 'USD' },+ amount_authorized: { type: :number, example: 15.5 },+ originator_id: { type: :string, example: '3' },+ originator_type: { type: :string, example: 'Refund' },+ type_id: { type: :string, example: '1' },+ store_id: { type: :string, example: '2' },+ public_metadata: { type: :object },+ private_metadata: { type: :object }+ }+ }+ },+ required: %w[store_credit],+ 'x-internal': true+ },+# Tax Categorycreate_tax_category_params: {type: :object,diff --git a/core/app/models/spree/store_credit.rb b/core/app/models/spree/store_credit.rbindex 1024fae9cc..167480cbda 100644--- a/core/app/models/spree/store_credit.rb+++ b/core/app/models/spree/store_credit.rb@@ -42,6 +42,9 @@ module Spreeextend Spree::DisplayMoneymoney_methods :amount, :amount_used+ self.whitelisted_ransackable_attributes = %w[user_id created_by_id amount currency type_id]+ self.whitelisted_ransackable_associations = %w[type user created_by]+def amount_remainingamount - amount_used - amount_authorizedend