Skip to content

armgit / spree

Public Imported from GitHub
0

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.

More Flexible Auto Gen Swagger Docs (#11390)

Matthew Kennedy1144a5a83354
diff --git a/api/docs/v2/platform/index.yaml b/api/docs/v2/platform/index.yaml
index ca97a4422c..32228de921 100644
--- a/api/docs/v2/platform/index.yaml
+++ b/api/docs/v2/platform/index.yaml
@@ -35,10 +35,16 @@ paths:
example: user,country,state
schema:
type: string
- - name: filter
+ - name: filter[user_id_eq]
in: query
description: ''
- example: user_id_eq=1&firstname_cont=Joh
+ example: '1'
+ schema:
+ type: string
+ - name: filter[firstname_cont]
+ in: query
+ description: ''
+ example: John
schema:
type: string
responses:
@@ -63,8 +69,8 @@ paths:
state_name:
alternative_phone: 555-555-0199
company: Company
- created_at: '2021-10-11T20:13:54.323Z'
- updated_at: '2021-10-11T20:13:54.323Z'
+ created_at: '2021-10-12T09:52:16.978Z'
+ updated_at: '2021-10-12T09:52:16.978Z'
deleted_at:
label:
relationships:
@@ -91,8 +97,8 @@ paths:
state_name:
alternative_phone: 555-555-0199
company: Company
- created_at: '2021-10-11T20:13:54.328Z'
- updated_at: '2021-10-11T20:13:54.328Z'
+ created_at: '2021-10-12T09:52:16.985Z'
+ updated_at: '2021-10-12T09:52:16.985Z'
deleted_at:
label:
relationships:
@@ -111,11 +117,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/addresses?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/addresses?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/addresses?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/addresses?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/addresses?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/addresses?page=1&per_page=&include=&filter[user_id_eq]=&filter[firstname_cont]=
+ next: http://www.example.com/api/v2/platform/addresses?filter%5Bfirstname_cont%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/addresses?filter%5Bfirstname_cont%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/addresses?filter%5Bfirstname_cont%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/addresses?filter%5Bfirstname_cont%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -162,8 +168,8 @@ paths:
state_name:
alternative_phone: 555-555-0199
company: Company
- created_at: '2021-10-11T20:13:54.574Z'
- updated_at: '2021-10-11T20:13:54.574Z'
+ created_at: '2021-10-12T09:52:17.265Z'
+ updated_at: '2021-10-12T09:52:17.265Z'
deleted_at:
label:
relationships:
@@ -253,8 +259,8 @@ paths:
state_name:
alternative_phone: 555-555-0199
company: Company
- created_at: '2021-10-11T20:13:54.625Z'
- updated_at: '2021-10-11T20:13:54.625Z'
+ created_at: '2021-10-12T09:52:17.320Z'
+ updated_at: '2021-10-12T09:52:17.320Z'
deleted_at:
label:
relationships:
@@ -327,8 +333,8 @@ paths:
state_name:
alternative_phone: 555-555-0199
company: Company
- created_at: '2021-10-11T20:13:54.705Z'
- updated_at: '2021-10-11T20:13:54.717Z'
+ created_at: '2021-10-12T09:52:17.403Z'
+ updated_at: '2021-10-12T09:52:17.416Z'
deleted_at:
label:
relationships:
@@ -436,10 +442,10 @@ paths:
example: order,adjustable
schema:
type: string
- - name: filter
+ - name: filter[order_id]
in: query
description: ''
- example: order_id=123456
+ example: '1234'
schema:
type: string
responses:
@@ -460,8 +466,8 @@ paths:
label: Shipping
mandatory:
eligible: true
- created_at: '2021-10-11T20:13:55.003Z'
- updated_at: '2021-10-11T20:13:55.003Z'
+ created_at: '2021-10-12T09:52:17.740Z'
+ updated_at: '2021-10-12T09:52:17.740Z'
state: open
included: false
display_amount: "$100.00"
@@ -487,8 +493,8 @@ paths:
label: Shipping
mandatory:
eligible: true
- created_at: '2021-10-11T20:13:55.033Z'
- updated_at: '2021-10-11T20:13:55.033Z'
+ created_at: '2021-10-12T09:52:17.769Z'
+ updated_at: '2021-10-12T09:52:17.769Z'
state: open
included: false
display_amount: "$100.00"
@@ -510,11 +516,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/adjustments?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/adjustments?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/adjustments?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/adjustments?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/adjustments?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/adjustments?page=1&per_page=&include=&filter[order_id]=
+ next: http://www.example.com/api/v2/platform/adjustments?filter%5Border_id%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/adjustments?filter%5Border_id%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/adjustments?filter%5Border_id%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/adjustments?filter%5Border_id%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -557,8 +563,8 @@ paths:
label: Shipping
mandatory:
eligible: true
- created_at: '2021-10-11T20:13:55.359Z'
- updated_at: '2021-10-11T20:13:55.359Z'
+ created_at: '2021-10-12T09:52:18.103Z'
+ updated_at: '2021-10-12T09:52:18.103Z'
state: open
included: false
display_amount: "$100.00"
@@ -636,8 +642,8 @@ paths:
label: Shipping
mandatory:
eligible: true
- created_at: '2021-10-11T20:13:55.494Z'
- updated_at: '2021-10-11T20:13:55.501Z'
+ created_at: '2021-10-12T09:52:18.246Z'
+ updated_at: '2021-10-12T09:52:18.253Z'
state: open
included: false
display_amount: "$1.00"
@@ -709,8 +715,8 @@ paths:
label: New label
mandatory:
eligible: true
- created_at: '2021-10-11T20:13:55.840Z'
- updated_at: '2021-10-11T20:13:55.856Z'
+ created_at: '2021-10-12T09:52:18.481Z'
+ updated_at: '2021-10-12T09:52:18.499Z'
state: open
included: false
display_amount: "$15.00"
@@ -819,10 +825,10 @@ paths:
example: product,taxon
schema:
type: string
- - name: filter
+ - name: filter[taxon_id_eq]
in: query
description: ''
- example: taxon_id_eq=1
+ example: '1'
schema:
type: string
responses:
@@ -838,8 +844,8 @@ paths:
type: classification
attributes:
position: 1
- created_at: '2021-10-11T20:13:56.619Z'
- updated_at: '2021-10-11T20:13:56.619Z'
+ created_at: '2021-10-12T09:52:19.238Z'
+ updated_at: '2021-10-12T09:52:19.238Z'
relationships:
product:
data:
@@ -853,8 +859,8 @@ paths:
type: classification
attributes:
position: 1
- created_at: '2021-10-11T20:13:56.781Z'
- updated_at: '2021-10-11T20:13:56.781Z'
+ created_at: '2021-10-12T09:52:19.426Z'
+ updated_at: '2021-10-12T09:52:19.426Z'
relationships:
product:
data:
@@ -869,11 +875,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/classifications?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/classifications?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/classifications?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/classifications?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/classifications?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/classifications?page=1&per_page=&include=&filter[taxon_id_eq]=
+ next: http://www.example.com/api/v2/platform/classifications?filter%5Btaxon_id_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/classifications?filter%5Btaxon_id_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/classifications?filter%5Btaxon_id_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/classifications?filter%5Btaxon_id_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -911,8 +917,8 @@ paths:
type: classification
attributes:
position: 1
- created_at: '2021-10-11T20:13:57.409Z'
- updated_at: '2021-10-11T20:13:57.409Z'
+ created_at: '2021-10-12T09:52:20.032Z'
+ updated_at: '2021-10-12T09:52:20.032Z'
relationships:
product:
data:
@@ -975,8 +981,8 @@ paths:
type: classification
attributes:
position: 1
- created_at: '2021-10-11T20:13:57.627Z'
- updated_at: '2021-10-11T20:13:57.627Z'
+ created_at: '2021-10-12T09:52:20.266Z'
+ updated_at: '2021-10-12T09:52:20.266Z'
relationships:
product:
data:
@@ -1036,8 +1042,8 @@ paths:
type: classification
attributes:
position: 1
- created_at: '2021-10-11T20:13:58.057Z'
- updated_at: '2021-10-11T20:13:58.057Z'
+ created_at: '2021-10-12T09:52:20.709Z'
+ updated_at: '2021-10-12T09:52:20.709Z'
relationships:
product:
data:
@@ -1147,8 +1153,8 @@ paths:
type: classification
attributes:
position: 2
- created_at: '2021-10-11T20:13:59.115Z'
- updated_at: '2021-10-11T20:13:59.144Z'
+ created_at: '2021-10-12T09:52:21.895Z'
+ updated_at: '2021-10-12T09:52:21.923Z'
relationships:
product:
data:
@@ -1215,10 +1221,16 @@ paths:
example: cms_sections
schema:
type: string
- - name: filter
+ - name: filter[type]
+ in: query
+ description: ''
+ example: homepage
+ schema:
+ type: string
+ - name: filter[title_cont]
in: query
description: ''
- example: type=homepage
+ example: About Us
schema:
type: string
responses:
@@ -1233,35 +1245,35 @@ paths:
- id: '1'
type: cms_page
attributes:
- title: Facere odio ex laudantium pariatur.
+ title: Inventore voluptatem at eveniet sequi labore rerum
+ magni quaerat.
meta_title:
content:
meta_description:
visible: true
- slug: facere-odio-ex-laudantium-pariatur
+ slug: inventore-voluptatem-at-eveniet-sequi-labore-rerum-magni-quaerat
type: Spree::Cms::Pages::StandardPage
locale: en
deleted_at:
- created_at: '2021-10-11T20:13:59.605Z'
- updated_at: '2021-10-11T20:13:59.605Z'
+ created_at: '2021-10-12T09:52:22.404Z'
+ updated_at: '2021-10-12T09:52:22.404Z'
relationships:
cms_sections:
data: []
- id: '2'
type: cms_page
attributes:
- title: Nemo quam odio molestias expedita commodi voluptatum
- qui.
+ title: Maxime temporibus quis voluptatibus reprehenderit.
meta_title:
content:
meta_description:
visible: true
- slug: nemo-quam-odio-molestias-expedita-commodi-voluptatum-qui
+ slug: maxime-temporibus-quis-voluptatibus-reprehenderit
type: Spree::Cms::Pages::StandardPage
locale: en
deleted_at:
- created_at: '2021-10-11T20:13:59.610Z'
- updated_at: '2021-10-11T20:13:59.610Z'
+ created_at: '2021-10-12T09:52:22.409Z'
+ updated_at: '2021-10-12T09:52:22.409Z'
relationships:
cms_sections:
data: []
@@ -1270,11 +1282,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/cms_pages?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/cms_pages?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/cms_pages?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/cms_pages?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/cms_pages?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/cms_pages?page=1&per_page=&include=&filter[type]=&filter[title_cont]=
+ next: http://www.example.com/api/v2/platform/cms_pages?filter%5Btitle_cont%5D=&filter%5Btype%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/cms_pages?filter%5Btitle_cont%5D=&filter%5Btype%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/cms_pages?filter%5Btitle_cont%5D=&filter%5Btype%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/cms_pages?filter%5Btitle_cont%5D=&filter%5Btype%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -1311,17 +1323,17 @@ paths:
id: '5'
type: cms_page
attributes:
- title: Eaque qui aliquid ullam perspiciatis a explicabo.
+ title: Distinctio corrupti ab ad odio nihil perspiciatis.
meta_title:
content:
meta_description:
visible: true
- slug: eaque-qui-aliquid-ullam-perspiciatis-a-explicabo
+ slug: distinctio-corrupti-ab-ad-odio-nihil-perspiciatis
type: Spree::Cms::Pages::StandardPage
locale: en
deleted_at:
- created_at: '2021-10-11T20:13:59.706Z'
- updated_at: '2021-10-11T20:13:59.706Z'
+ created_at: '2021-10-12T09:52:22.526Z'
+ updated_at: '2021-10-12T09:52:22.526Z'
relationships:
cms_sections:
data: []
@@ -1377,17 +1389,18 @@ paths:
id: '6'
type: cms_page
attributes:
- title: Unde cum itaque numquam amet.
+ title: Rerum explicabo cupiditate facilis quo ipsam ut consequatur
+ maiores.
meta_title:
content:
meta_description:
visible: true
- slug: unde-cum-itaque-numquam-amet
+ slug: rerum-explicabo-cupiditate-facilis-quo-ipsam-ut-consequatur-maiores
type: Spree::Cms::Pages::StandardPage
locale: en
deleted_at:
- created_at: '2021-10-11T20:13:59.753Z'
- updated_at: '2021-10-11T20:13:59.753Z'
+ created_at: '2021-10-12T09:52:22.578Z'
+ updated_at: '2021-10-12T09:52:22.578Z'
relationships:
cms_sections:
data: []
@@ -1445,12 +1458,12 @@ paths:
content:
meta_description:
visible: true
- slug: eos-temporibus-quo-sunt-labore-consequuntur-impedit
+ slug: reprehenderit-facere-voluptate-ipsam-beatae
type: Spree::Cms::Pages::StandardPage
locale: en
deleted_at:
- created_at: '2021-10-11T20:13:59.838Z'
- updated_at: '2021-10-11T20:13:59.851Z'
+ created_at: '2021-10-12T09:52:22.657Z'
+ updated_at: '2021-10-12T09:52:22.671Z'
relationships:
cms_sections:
data: []
@@ -1546,10 +1559,10 @@ paths:
example: product
schema:
type: string
- - name: filter
+ - name: filter[name_eq]
in: query
description: ''
- example: name_eq=Hero
+ example: Hero
schema:
type: string
responses:
@@ -1564,8 +1577,7 @@ paths:
- id: '1'
type: cms_section
attributes:
- name: Laborum molestiae ad voluptatem doloremque rerum eius
- et illo.
+ name: Doloribus laboriosam ad consequatur nemo veniam eveniet.
content: {}
settings:
gutters: No Gutters
@@ -1574,8 +1586,8 @@ paths:
type: Spree::Cms::Sections::HeroImage
position: 1
linked_resource_type: Spree::Taxon
- created_at: '2021-10-11T20:14:00.079Z'
- updated_at: '2021-10-11T20:14:00.079Z'
+ created_at: '2021-10-12T09:52:22.904Z'
+ updated_at: '2021-10-12T09:52:22.904Z'
relationships:
cms_page:
data:
@@ -1586,7 +1598,8 @@ paths:
- id: '2'
type: cms_section
attributes:
- name: Mollitia placeat quaerat asperiores blanditiis.
+ name: Voluptatibus quas voluptate soluta sed reiciendis a
+ quae.
content:
link_type_one: Spree::Taxon
link_type_two: Spree::Taxon
@@ -1598,8 +1611,8 @@ paths:
type: Spree::Cms::Sections::ImageGallery
position: 2
linked_resource_type:
- created_at: '2021-10-11T20:14:00.084Z'
- updated_at: '2021-10-11T20:14:00.084Z'
+ created_at: '2021-10-12T09:52:22.909Z'
+ updated_at: '2021-10-12T09:52:22.909Z'
relationships:
cms_page:
data:
@@ -1610,8 +1623,7 @@ paths:
- id: '3'
type: cms_section
attributes:
- name: Suscipit mollitia reprehenderit dignissimos voluptatum
- sequi alias iusto.
+ name: Eos repellat doloremque non esse.
content: {}
settings:
gutters: No Gutters
@@ -1620,8 +1632,8 @@ paths:
type: Spree::Cms::Sections::FeaturedArticle
position: 3
linked_resource_type: Spree::Taxon
- created_at: '2021-10-11T20:14:00.096Z'
- updated_at: '2021-10-11T20:14:00.096Z'
+ created_at: '2021-10-12T09:52:22.921Z'
+ updated_at: '2021-10-12T09:52:22.921Z'
relationships:
cms_page:
data:
@@ -1632,7 +1644,7 @@ paths:
- id: '4'
type: cms_section
attributes:
- name: Numquam architecto nemo ad eligendi.
+ name: Tenetur cumque velit minus dolor eius aliquam.
content: {}
settings:
gutters: No Gutters
@@ -1641,8 +1653,8 @@ paths:
type: Spree::Cms::Sections::HeroImage
position: 4
linked_resource_type: Spree::Product
- created_at: '2021-10-11T20:14:00.108Z'
- updated_at: '2021-10-11T20:14:00.108Z'
+ created_at: '2021-10-12T09:52:22.934Z'
+ updated_at: '2021-10-12T09:52:22.934Z'
relationships:
cms_page:
data:
@@ -1655,7 +1667,7 @@ paths:
- id: '5'
type: cms_section
attributes:
- name: Quia soluta ut labore ipsa.
+ name: Ullam eius voluptatum minus nemo id.
content: {}
settings:
gutters: No Gutters
@@ -1664,8 +1676,8 @@ paths:
type: Spree::Cms::Sections::HeroImage
position: 5
linked_resource_type: Spree::Product
- created_at: '2021-10-11T20:14:00.118Z'
- updated_at: '2021-10-11T20:14:00.118Z'
+ created_at: '2021-10-12T09:52:22.945Z'
+ updated_at: '2021-10-12T09:52:22.945Z'
relationships:
cms_page:
data:
@@ -1680,11 +1692,11 @@ paths:
total_count: 5
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/cms_sections?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/cms_sections?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/cms_sections?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/cms_sections?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/cms_sections?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/cms_sections?page=1&per_page=&include=&filter[name_eq]=
+ next: http://www.example.com/api/v2/platform/cms_sections?filter%5Bname_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/cms_sections?filter%5Bname_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/cms_sections?filter%5Bname_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/cms_sections?filter%5Bname_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -1721,7 +1733,7 @@ paths:
id: '14'
type: cms_section
attributes:
- name: A numquam totam repudiandae explicabo.
+ name: Commodi neque provident esse maxime.
content: {}
settings:
gutters: No Gutters
@@ -1730,8 +1742,8 @@ paths:
type: Spree::Cms::Sections::HeroImage
position: 4
linked_resource_type: Spree::Product
- created_at: '2021-10-11T20:14:00.317Z'
- updated_at: '2021-10-11T20:14:00.317Z'
+ created_at: '2021-10-12T09:52:23.151Z'
+ updated_at: '2021-10-12T09:52:23.151Z'
relationships:
cms_page:
data:
@@ -1793,7 +1805,7 @@ paths:
id: '21'
type: cms_section
attributes:
- name: Labore tempore aut nisi sapiente pariatur porro quis.
+ name: Adipisci eveniet quisquam quae eius doloremque accusamus.
content: {}
settings:
gutters: No Gutters
@@ -1802,8 +1814,8 @@ paths:
type: Spree::Cms::Sections::HeroImage
position: 4
linked_resource_type: Spree::Product
- created_at: '2021-10-11T20:14:00.485Z'
- updated_at: '2021-10-11T20:14:00.485Z'
+ created_at: '2021-10-12T09:52:23.330Z'
+ updated_at: '2021-10-12T09:52:23.330Z'
relationships:
cms_page:
data:
@@ -1871,8 +1883,8 @@ paths:
type: Spree::Cms::Sections::HeroImage
position: 4
linked_resource_type: Spree::Product
- created_at: '2021-10-11T20:14:00.731Z'
- updated_at: '2021-10-11T20:14:00.747Z'
+ created_at: '2021-10-12T09:52:23.627Z'
+ updated_at: '2021-10-12T09:52:23.643Z'
relationships:
cms_page:
data:
@@ -1974,7 +1986,7 @@ paths:
id: '58'
type: cms_section
attributes:
- name: Quibusdam occaecati dolor eum aut consequatur.
+ name: Est quos earum animi magni odit magnam.
content: {}
settings:
gutters: No Gutters
@@ -1983,8 +1995,8 @@ paths:
type: Spree::Cms::Sections::HeroImage
position: 3
linked_resource_type: Spree::Product
- created_at: '2021-10-11T20:14:01.342Z'
- updated_at: '2021-10-11T20:14:01.357Z'
+ created_at: '2021-10-12T09:52:24.266Z'
+ updated_at: '2021-10-12T09:52:24.281Z'
relationships:
cms_page:
data:
@@ -2042,9 +2054,9 @@ paths:
name: United States of America
numcode: 840
states_required: true
- updated_at: '2021-10-11T20:14:01.545Z'
+ updated_at: '2021-10-12T09:52:24.470Z'
zipcode_required: true
- created_at: '2021-10-11T20:14:01.545Z'
+ created_at: '2021-10-12T09:52:24.470Z'
relationships:
states:
data: []
@@ -2057,9 +2069,9 @@ paths:
name: NAME_2
numcode: 840
states_required: false
- updated_at: '2021-10-11T20:14:01.553Z'
+ updated_at: '2021-10-12T09:52:24.478Z'
zipcode_required: true
- created_at: '2021-10-11T20:14:01.553Z'
+ created_at: '2021-10-12T09:52:24.478Z'
relationships:
states:
data: []
@@ -2072,9 +2084,9 @@ paths:
name: NAME_3
numcode: 840
states_required: false
- updated_at: '2021-10-11T20:14:01.556Z'
+ updated_at: '2021-10-12T09:52:24.481Z'
zipcode_required: true
- created_at: '2021-10-11T20:14:01.556Z'
+ created_at: '2021-10-12T09:52:24.481Z'
relationships:
states:
data: []
@@ -2129,9 +2141,9 @@ paths:
name: NAME_6
numcode: 840
states_required: false
- updated_at: '2021-10-11T20:14:01.624Z'
+ updated_at: '2021-10-12T09:52:24.550Z'
zipcode_required: true
- created_at: '2021-10-11T20:14:01.624Z'
+ created_at: '2021-10-12T09:52:24.550Z'
relationships:
states:
data: []
@@ -2178,10 +2190,10 @@ paths:
example: order,tax_category,variant.product
schema:
type: string
- - name: filter
+ - name: filter[order_id_eq]
in: query
description: ''
- example: order_id_eq=1
+ example: '123'
schema:
type: string
responses:
@@ -2198,8 +2210,8 @@ paths:
attributes:
quantity: 1
price: '10.0'
- created_at: '2021-10-11T20:14:01.755Z'
- updated_at: '2021-10-11T20:14:01.762Z'
+ created_at: '2021-10-12T09:52:24.678Z'
+ updated_at: '2021-10-12T09:52:24.685Z'
currency: USD
cost_price: '17.0'
adjustment_total: '0.0'
@@ -2209,18 +2221,18 @@ paths:
pre_tax_amount: '10.0'
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
- display_amount: "$10.00"
display_price: "$10.00"
single_display_amount: "$10.00"
display_discounted_amount: "$10.00"
display_total: "$10.00"
display_subtotal: "$10.00"
- display_final_amount: "$10.00"
display_adjustment_total: "$0.00"
+ display_final_amount: "$10.00"
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
display_pre_tax_amount: "$10.00"
+ display_amount: "$10.00"
relationships:
order:
data:
@@ -2243,8 +2255,8 @@ paths:
attributes:
quantity: 1
price: '10.0'
- created_at: '2021-10-11T20:14:01.801Z'
- updated_at: '2021-10-11T20:14:01.807Z'
+ created_at: '2021-10-12T09:52:24.723Z'
+ updated_at: '2021-10-12T09:52:24.730Z'
currency: USD
cost_price: '17.0'
adjustment_total: '0.0'
@@ -2254,18 +2266,18 @@ paths:
pre_tax_amount: '10.0'
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
- display_amount: "$10.00"
display_price: "$10.00"
single_display_amount: "$10.00"
display_discounted_amount: "$10.00"
display_total: "$10.00"
display_subtotal: "$10.00"
- display_final_amount: "$10.00"
display_adjustment_total: "$0.00"
+ display_final_amount: "$10.00"
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
display_pre_tax_amount: "$10.00"
+ display_amount: "$10.00"
relationships:
order:
data:
@@ -2288,11 +2300,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/line_items?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/line_items?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/line_items?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/line_items?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/line_items?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/line_items?page=1&per_page=&include=&filter[order_id_eq]=
+ next: http://www.example.com/api/v2/platform/line_items?filter%5Border_id_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/line_items?filter%5Border_id_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/line_items?filter%5Border_id_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/line_items?filter%5Border_id_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -2331,8 +2343,8 @@ paths:
attributes:
quantity: 1
price: '10.0'
- created_at: '2021-10-11T20:14:02.058Z'
- updated_at: '2021-10-11T20:14:02.095Z'
+ created_at: '2021-10-12T09:52:25.010Z'
+ updated_at: '2021-10-12T09:52:25.047Z'
currency: USD
cost_price: '17.0'
adjustment_total: '0.0'
@@ -2342,18 +2354,18 @@ paths:
pre_tax_amount: '10.0'
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
- display_amount: "$10.00"
display_price: "$10.00"
single_display_amount: "$10.00"
display_discounted_amount: "$10.00"
display_total: "$10.00"
display_subtotal: "$10.00"
- display_final_amount: "$10.00"
display_adjustment_total: "$0.00"
+ display_final_amount: "$10.00"
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
display_pre_tax_amount: "$10.00"
+ display_amount: "$10.00"
relationships:
order:
data:
@@ -2428,8 +2440,8 @@ paths:
attributes:
quantity: 1
price: '10.0'
- created_at: '2021-10-11T20:14:02.279Z'
- updated_at: '2021-10-11T20:14:02.286Z'
+ created_at: '2021-10-12T09:52:25.227Z'
+ updated_at: '2021-10-12T09:52:25.234Z'
currency: USD
cost_price: '17.0'
adjustment_total: '0.0'
@@ -2439,18 +2451,18 @@ paths:
pre_tax_amount: '10.0'
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
- display_amount: "$10.00"
display_price: "$10.00"
single_display_amount: "$10.00"
display_discounted_amount: "$10.00"
display_total: "$10.00"
display_subtotal: "$10.00"
- display_final_amount: "$10.00"
display_adjustment_total: "$0.00"
+ display_final_amount: "$10.00"
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
display_pre_tax_amount: "$10.00"
+ display_amount: "$10.00"
relationships:
order:
data:
@@ -2519,8 +2531,8 @@ paths:
attributes:
quantity: 4
price: '10.0'
- created_at: '2021-10-11T20:14:02.566Z'
- updated_at: '2021-10-11T20:14:02.612Z'
+ created_at: '2021-10-12T09:52:25.542Z'
+ updated_at: '2021-10-12T09:52:25.592Z'
currency: USD
cost_price: '17.0'
adjustment_total: '0.0'
@@ -2530,18 +2542,18 @@ paths:
pre_tax_amount: '40.0'
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
- display_amount: "$40.00"
display_price: "$10.00"
single_display_amount: "$10.00"
display_discounted_amount: "$40.00"
display_total: "$40.00"
display_subtotal: "$40.00"
- display_final_amount: "$40.00"
display_adjustment_total: "$0.00"
+ display_final_amount: "$40.00"
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
display_pre_tax_amount: "$40.00"
+ display_amount: "$40.00"
relationships:
order:
data:
@@ -2566,10 +2578,10 @@ paths:
examples:
Example:
value:
- error: 'Quantity selected of "Product #52 - 1305" is not available.'
+ error: 'Quantity selected of "Product #52 - 4665" is not available.'
errors:
quantity:
- - 'selected of "Product #52 - 1305" is not available.'
+ - 'selected of "Product #52 - 4665" is not available.'
'404':
description: Record not found
content:
@@ -2651,10 +2663,10 @@ paths:
example: linked_resource
schema:
type: string
- - name: filter
+ - name: filter[menu_item_name_eq]
in: query
description: ''
- example: menu_item_name_eq=Women
+ example: Women
schema:
type: string
responses:
@@ -2679,8 +2691,8 @@ paths:
lft: 2
rgt: 3
depth: 1
- created_at: '2021-10-11T20:14:03.360Z'
- updated_at: '2021-10-11T20:14:03.379Z'
+ created_at: '2021-10-12T09:52:26.394Z'
+ updated_at: '2021-10-12T09:52:26.403Z'
link:
is_container: false
is_root: false
@@ -2716,8 +2728,8 @@ paths:
lft: 4
rgt: 5
depth: 1
- created_at: '2021-10-11T20:14:03.472Z'
- updated_at: '2021-10-11T20:14:03.478Z'
+ created_at: '2021-10-12T09:52:26.495Z'
+ updated_at: '2021-10-12T09:52:26.502Z'
link:
is_container: false
is_root: false
@@ -2753,8 +2765,8 @@ paths:
lft: 6
rgt: 7
depth: 1
- created_at: '2021-10-11T20:14:03.563Z'
- updated_at: '2021-10-11T20:14:03.569Z'
+ created_at: '2021-10-12T09:52:26.593Z'
+ updated_at: '2021-10-12T09:52:26.600Z'
link:
is_container: false
is_root: false
@@ -2790,8 +2802,8 @@ paths:
lft: 8
rgt: 9
depth: 1
- created_at: '2021-10-11T20:14:03.658Z'
- updated_at: '2021-10-11T20:14:03.664Z'
+ created_at: '2021-10-12T09:52:26.690Z'
+ updated_at: '2021-10-12T09:52:26.695Z'
link:
is_container: false
is_root: false
@@ -2827,8 +2839,8 @@ paths:
lft: 10
rgt: 11
depth: 1
- created_at: '2021-10-11T20:14:03.752Z'
- updated_at: '2021-10-11T20:14:03.758Z'
+ created_at: '2021-10-12T09:52:26.786Z'
+ updated_at: '2021-10-12T09:52:26.793Z'
link:
is_container: false
is_root: false
@@ -2864,8 +2876,8 @@ paths:
lft: 12
rgt: 13
depth: 1
- created_at: '2021-10-11T20:14:03.846Z'
- updated_at: '2021-10-11T20:14:03.853Z'
+ created_at: '2021-10-12T09:52:26.896Z'
+ updated_at: '2021-10-12T09:52:26.904Z'
link:
is_container: false
is_root: false
@@ -2901,8 +2913,8 @@ paths:
lft: 14
rgt: 15
depth: 1
- created_at: '2021-10-11T20:14:03.940Z'
- updated_at: '2021-10-11T20:14:03.947Z'
+ created_at: '2021-10-12T09:52:26.993Z'
+ updated_at: '2021-10-12T09:52:26.999Z'
link:
is_container: false
is_root: false
@@ -2928,7 +2940,8 @@ paths:
- id: '1'
type: menu_item
attributes:
- name: Provident earum commodi itaque ea eveniet.
+ name: Natus debitis ratione dolores repudiandae sint accusantium
+ tenetur.
subtitle:
destination:
new_window: false
@@ -2938,8 +2951,8 @@ paths:
lft: 1
rgt: 16
depth: 0
- created_at: '2021-10-11T20:14:03.271Z'
- updated_at: '2021-10-11T20:14:03.964Z'
+ created_at: '2021-10-12T09:52:26.303Z'
+ updated_at: '2021-10-12T09:52:27.015Z'
link:
is_container: true
is_root: true
@@ -2977,11 +2990,11 @@ paths:
total_count: 8
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/menu_items?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/menu_items?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/menu_items?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/menu_items?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/menu_items?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/menu_items?page=1&per_page=&include=&filter[menu_item_name_eq]=
+ next: http://www.example.com/api/v2/platform/menu_items?filter%5Bmenu_item_name_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/menu_items?filter%5Bmenu_item_name_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/menu_items?filter%5Bmenu_item_name_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/menu_items?filter%5Bmenu_item_name_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -3028,8 +3041,8 @@ paths:
lft: 8
rgt: 9
depth: 1
- created_at: '2021-10-11T20:14:05.124Z'
- updated_at: '2021-10-11T20:14:05.129Z'
+ created_at: '2021-10-12T09:52:28.285Z'
+ updated_at: '2021-10-12T09:52:28.290Z'
link:
is_container: false
is_root: false
@@ -3115,8 +3128,8 @@ paths:
lft: 8
rgt: 9
depth: 1
- created_at: '2021-10-11T20:14:05.873Z'
- updated_at: '2021-10-11T20:14:05.882Z'
+ created_at: '2021-10-12T09:52:29.063Z'
+ updated_at: '2021-10-12T09:52:29.070Z'
link:
is_container: false
is_root: false
@@ -3198,8 +3211,8 @@ paths:
lft: 8
rgt: 9
depth: 1
- created_at: '2021-10-11T20:14:07.059Z'
- updated_at: '2021-10-11T20:14:07.096Z'
+ created_at: '2021-10-12T09:52:30.308Z'
+ updated_at: '2021-10-12T09:52:30.343Z'
link:
is_container: false
is_root: false
@@ -3324,8 +3337,8 @@ paths:
lft: 5
rgt: 6
depth: 2
- created_at: '2021-10-11T20:14:09.900Z'
- updated_at: '2021-10-11T20:14:09.940Z'
+ created_at: '2021-10-12T09:52:33.245Z'
+ updated_at: '2021-10-12T09:52:33.283Z'
link:
is_container: false
is_root: false
@@ -3396,10 +3409,10 @@ paths:
example: menu_items
schema:
type: string
- - name: filter
+ - name: filter[location_eq]
in: query
description: ''
- example: location_eq=header
+ example: header
schema:
type: string
responses:
@@ -3417,25 +3430,25 @@ paths:
name: Main Menu
location: header
locale: en
- created_at: '2021-10-11T20:14:10.739Z'
- updated_at: '2021-10-11T20:14:10.950Z'
+ created_at: '2021-10-12T09:52:34.120Z'
+ updated_at: '2021-10-12T09:52:34.347Z'
relationships:
menu_items:
data:
+ - id: '89'
+ type: menu_item
- id: '87'
type: menu_item
- id: '90'
type: menu_item
- - id: '89'
- type: menu_item
- id: '19'
type: menu
attributes:
name: Footer Menu
location: footer
locale: en
- created_at: '2021-10-11T20:14:10.751Z'
- updated_at: '2021-10-11T20:14:11.143Z'
+ created_at: '2021-10-12T09:52:34.133Z'
+ updated_at: '2021-10-12T09:52:34.555Z'
relationships:
menu_items:
data:
@@ -3450,11 +3463,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/menus?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/menus?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/menus?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/menus?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/menus?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/menus?page=1&per_page=&include=&filter[location_eq]=
+ next: http://www.example.com/api/v2/platform/menus?filter%5Blocation_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/menus?filter%5Blocation_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/menus?filter%5Blocation_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/menus?filter%5Blocation_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -3494,8 +3507,8 @@ paths:
name: Main Menu
location: header
locale: en
- created_at: '2021-10-11T20:14:11.637Z'
- updated_at: '2021-10-11T20:14:11.647Z'
+ created_at: '2021-10-12T09:52:35.137Z'
+ updated_at: '2021-10-12T09:52:35.147Z'
relationships:
menu_items:
data:
@@ -3559,8 +3572,8 @@ paths:
name: Main Menu
location: header
locale: en
- created_at: '2021-10-11T20:14:11.698Z'
- updated_at: '2021-10-11T20:14:11.706Z'
+ created_at: '2021-10-12T09:52:35.205Z'
+ updated_at: '2021-10-12T09:52:35.213Z'
relationships:
menu_items:
data:
@@ -3618,8 +3631,8 @@ paths:
name: Main Menu
location: header
locale: en
- created_at: '2021-10-11T20:14:11.798Z'
- updated_at: '2021-10-11T20:14:11.808Z'
+ created_at: '2021-10-12T09:52:35.317Z'
+ updated_at: '2021-10-12T09:52:35.326Z'
relationships:
menu_items:
data:
@@ -3715,17 +3728,16 @@ paths:
example: 50
schema:
type: integer
- - name: include
+ - name: filter[option_type_id_eq]
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: ''
+ description: ''
+ example: '1'
schema:
type: string
- - name: filter
+ - name: filter[name_cont]
in: query
description: ''
- example: option_type_id_eq=1&name_cont=Size
+ example: Size
schema:
type: string
responses:
@@ -3743,8 +3755,8 @@ paths:
name: foo-size-1
presentation: Size
position: 1
- created_at: '2021-10-11T20:14:12.051Z'
- updated_at: '2021-10-11T20:14:12.051Z'
+ created_at: '2021-10-12T09:52:35.647Z'
+ updated_at: '2021-10-12T09:52:35.647Z'
filterable: true
relationships:
option_values:
@@ -3755,8 +3767,8 @@ paths:
name: foo-size-2
presentation: Size
position: 2
- created_at: '2021-10-11T20:14:12.054Z'
- updated_at: '2021-10-11T20:14:12.054Z'
+ created_at: '2021-10-12T09:52:35.651Z'
+ updated_at: '2021-10-12T09:52:35.651Z'
filterable: true
relationships:
option_values:
@@ -3766,11 +3778,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/option_types?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/option_types?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/option_types?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/option_types?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/option_types?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/option_types?page=1&per_page=&filter[option_type_id_eq]=&filter[name_cont]=
+ next: http://www.example.com/api/v2/platform/option_types?filter%5Bname_cont%5D=&filter%5Boption_type_id_eq%5D=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/option_types?filter%5Bname_cont%5D=&filter%5Boption_type_id_eq%5D=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/option_types?filter%5Bname_cont%5D=&filter%5Boption_type_id_eq%5D=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/option_types?filter%5Bname_cont%5D=&filter%5Boption_type_id_eq%5D=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -3787,14 +3799,7 @@ paths:
- bearer_auth: []
description: Creates an Option Type
operationId: create-option-type
- 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: ''
- schema:
- type: string
+ parameters: []
responses:
'201':
description: record created
@@ -3810,8 +3815,8 @@ paths:
name: foo-size-5
presentation: Size
position: 1
- created_at: '2021-10-11T20:14:12.133Z'
- updated_at: '2021-10-11T20:14:12.133Z'
+ created_at: '2021-10-12T09:52:35.740Z'
+ updated_at: '2021-10-12T09:52:35.740Z'
filterable: true
relationships:
option_values:
@@ -3849,13 +3854,6 @@ paths:
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: ''
- schema:
- type: string
responses:
'200':
description: Record found
@@ -3871,8 +3869,8 @@ paths:
name: foo-size-6
presentation: Size
position: 1
- created_at: '2021-10-11T20:14:12.178Z'
- updated_at: '2021-10-11T20:14:12.178Z'
+ created_at: '2021-10-12T09:52:35.803Z'
+ updated_at: '2021-10-12T09:52:35.803Z'
filterable: true
relationships:
option_values:
@@ -3907,13 +3905,6 @@ paths:
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: ''
- schema:
- type: string
responses:
'200':
description: record updated
@@ -3929,8 +3920,8 @@ paths:
name: Size-X
presentation: Size
position: 1
- created_at: '2021-10-11T20:14:12.245Z'
- updated_at: '2021-10-11T20:14:12.256Z'
+ created_at: '2021-10-12T09:52:35.892Z'
+ updated_at: '2021-10-12T09:52:35.907Z'
filterable: true
relationships:
option_values:
@@ -4027,10 +4018,16 @@ paths:
example: option_type
schema:
type: string
- - name: filter
+ - name: filter[option_type_id_eq]
in: query
description: ''
- example: option_type_id_eq=1&name_cont=M
+ example: '1'
+ schema:
+ type: string
+ - name: filter[name_cont]
+ in: query
+ description: ''
+ example: Red
schema:
type: string
responses:
@@ -4048,8 +4045,8 @@ paths:
position: 1
name: Size-1
presentation: S
- created_at: '2021-10-11T20:14:12.409Z'
- updated_at: '2021-10-11T20:14:12.409Z'
+ created_at: '2021-10-12T09:52:36.116Z'
+ updated_at: '2021-10-12T09:52:36.116Z'
relationships:
option_type:
data:
@@ -4061,8 +4058,8 @@ paths:
position: 1
name: Size-2
presentation: S
- created_at: '2021-10-11T20:14:12.417Z'
- updated_at: '2021-10-11T20:14:12.417Z'
+ created_at: '2021-10-12T09:52:36.125Z'
+ updated_at: '2021-10-12T09:52:36.125Z'
relationships:
option_type:
data:
@@ -4073,11 +4070,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/option_values?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/option_values?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/option_values?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/option_values?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/option_values?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/option_values?page=1&per_page=&include=&filter[option_type_id_eq]=&filter[name_cont]=
+ next: http://www.example.com/api/v2/platform/option_values?filter%5Bname_cont%5D=&filter%5Boption_type_id_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/option_values?filter%5Bname_cont%5D=&filter%5Boption_type_id_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/option_values?filter%5Bname_cont%5D=&filter%5Boption_type_id_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/option_values?filter%5Bname_cont%5D=&filter%5Boption_type_id_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -4117,8 +4114,8 @@ paths:
position: 1
name: Size-5
presentation: S
- created_at: '2021-10-11T20:14:12.490Z'
- updated_at: '2021-10-11T20:14:12.490Z'
+ created_at: '2021-10-12T09:52:36.221Z'
+ updated_at: '2021-10-12T09:52:36.221Z'
relationships:
option_type:
data:
@@ -4177,8 +4174,8 @@ paths:
position: 1
name: Size-6
presentation: S
- created_at: '2021-10-11T20:14:12.542Z'
- updated_at: '2021-10-11T20:14:12.542Z'
+ created_at: '2021-10-12T09:52:36.275Z'
+ updated_at: '2021-10-12T09:52:36.275Z'
relationships:
option_type:
data:
@@ -4236,8 +4233,8 @@ paths:
position: 1
name: M
presentation: S
- created_at: '2021-10-11T20:14:12.619Z'
- updated_at: '2021-10-11T20:14:12.631Z'
+ created_at: '2021-10-12T09:52:36.360Z'
+ updated_at: '2021-10-12T09:52:36.373Z'
relationships:
option_type:
data:
@@ -4332,13 +4329,13 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
- - name: filter
+ - name: filter[state_eq]
in: query
description: ''
- example: state_eq=complete
+ example: complete
schema:
type: string
responses:
@@ -4353,7 +4350,7 @@ paths:
- id: '26'
type: order
attributes:
- number: R206830616
+ number: R405901975
item_total: '0.0'
total: '0.0'
state: cart
@@ -4362,10 +4359,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:12.814Z'
- updated_at: '2021-10-11T20:14:12.814Z'
+ created_at: '2021-10-12T09:52:36.600Z'
+ updated_at: '2021-10-12T09:52:36.600Z'
currency: USD
last_ip_address:
shipment_total: '0.0'
@@ -4381,6 +4378,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$0.00"
+ display_ship_total: "$0.00"
+ display_shipment_total: "$0.00"
display_total: "$0.00"
display_outstanding_balance: "$0.00"
display_item_total: "$0.00"
@@ -4391,9 +4391,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$0.00"
- display_ship_total: "$0.00"
- display_shipment_total: "$0.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$0.00"
@@ -4437,7 +4434,7 @@ paths:
- id: '27'
type: order
attributes:
- number: R956088101
+ number: R894484933
item_total: '0.0'
total: '0.0'
state: cart
@@ -4446,10 +4443,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:12.826Z'
- updated_at: '2021-10-11T20:14:12.826Z'
+ created_at: '2021-10-12T09:52:36.613Z'
+ updated_at: '2021-10-12T09:52:36.613Z'
currency: USD
last_ip_address:
shipment_total: '0.0'
@@ -4465,6 +4462,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$0.00"
+ display_ship_total: "$0.00"
+ display_shipment_total: "$0.00"
display_total: "$0.00"
display_outstanding_balance: "$0.00"
display_item_total: "$0.00"
@@ -4475,9 +4475,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$0.00"
- display_ship_total: "$0.00"
- display_shipment_total: "$0.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$0.00"
@@ -4523,11 +4520,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/orders?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/orders?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/orders?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/orders?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/orders?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/orders?page=1&per_page=&include=&filter[state_eq]=
+ next: http://www.example.com/api/v2/platform/orders?filter%5Bstate_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/orders?filter%5Bstate_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/orders?filter%5Bstate_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/orders?filter%5Bstate_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -4549,7 +4546,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -4564,7 +4561,7 @@ paths:
id: '30'
type: order
attributes:
- number: R278538747
+ number: R683783866
item_total: '0.0'
total: '0.0'
state: cart
@@ -4575,8 +4572,8 @@ paths:
payment_state:
email:
special_instructions:
- created_at: '2021-10-11T20:14:13.168Z'
- updated_at: '2021-10-11T20:14:13.184Z'
+ created_at: '2021-10-12T09:52:37.007Z'
+ updated_at: '2021-10-12T09:52:37.025Z'
currency: USD
last_ip_address:
shipment_total: '0.0'
@@ -4592,6 +4589,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$20.00"
+ display_ship_total: "$0.00"
+ display_shipment_total: "$0.00"
display_total: "$0.00"
display_outstanding_balance: "$0.00"
display_item_total: "$0.00"
@@ -4602,9 +4602,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$20.00"
- display_ship_total: "$0.00"
- display_shipment_total: "$0.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$0.00"
@@ -4673,7 +4670,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -4688,7 +4685,7 @@ paths:
id: '31'
type: order
attributes:
- number: R104023850
+ number: R411944683
item_total: '10.0'
total: '110.0'
state: delivery
@@ -4697,10 +4694,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:13.234Z'
- updated_at: '2021-10-11T20:14:13.397Z'
+ created_at: '2021-10-12T09:52:37.085Z'
+ updated_at: '2021-10-12T09:52:37.254Z'
currency: USD
last_ip_address:
shipment_total: '100.0'
@@ -4716,6 +4713,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$10.00"
+ display_ship_total: "$100.00"
+ display_shipment_total: "$100.00"
display_total: "$110.00"
display_outstanding_balance: "$110.00"
display_item_total: "$10.00"
@@ -4726,9 +4726,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$10.00"
- display_ship_total: "$100.00"
- display_shipment_total: "$100.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$110.00"
@@ -4809,7 +4806,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -4824,7 +4821,7 @@ paths:
id: '33'
type: order
attributes:
- number: R877281653
+ number: R779245855
item_total: '10.0'
total: '110.0'
state: delivery
@@ -4835,8 +4832,8 @@ paths:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:13.624Z'
- updated_at: '2021-10-11T20:14:13.742Z'
+ created_at: '2021-10-12T09:52:37.534Z'
+ updated_at: '2021-10-12T09:52:37.678Z'
currency: USD
last_ip_address:
shipment_total: '100.0'
@@ -4852,6 +4849,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$10.00"
+ display_ship_total: "$100.00"
+ display_shipment_total: "$100.00"
display_total: "$110.00"
display_outstanding_balance: "$110.00"
display_item_total: "$10.00"
@@ -4862,9 +4862,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$10.00"
- display_ship_total: "$100.00"
- display_shipment_total: "$100.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$110.00"
@@ -4995,7 +4992,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -5010,7 +5007,7 @@ paths:
id: '38'
type: order
attributes:
- number: R630016414
+ number: R051236352
item_total: '10.0'
total: '110.0'
state: payment
@@ -5019,10 +5016,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:14.610Z'
- updated_at: '2021-10-11T20:14:14.775Z'
+ created_at: '2021-10-12T09:52:38.558Z'
+ updated_at: '2021-10-12T09:52:38.741Z'
currency: USD
last_ip_address:
shipment_total: '100.0'
@@ -5038,6 +5035,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$110.00"
+ display_ship_total: "$100.00"
+ display_shipment_total: "$100.00"
display_total: "$110.00"
display_outstanding_balance: "$110.00"
display_item_total: "$10.00"
@@ -5048,9 +5048,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$110.00"
- display_ship_total: "$100.00"
- display_shipment_total: "$100.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$110.00"
@@ -5134,7 +5131,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -5149,7 +5146,7 @@ paths:
id: '40'
type: order
attributes:
- number: R231605491
+ number: R875525276
item_total: '10.0'
total: '110.0'
state: payment
@@ -5158,10 +5155,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:14.997Z'
- updated_at: '2021-10-11T20:14:15.152Z'
+ created_at: '2021-10-12T09:52:39.170Z'
+ updated_at: '2021-10-12T09:52:39.351Z'
currency: USD
last_ip_address:
shipment_total: '100.0'
@@ -5177,6 +5174,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$110.00"
+ display_ship_total: "$100.00"
+ display_shipment_total: "$100.00"
display_total: "$110.00"
display_outstanding_balance: "$110.00"
display_item_total: "$10.00"
@@ -5187,9 +5187,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$110.00"
- display_ship_total: "$100.00"
- display_shipment_total: "$100.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$110.00"
@@ -5273,7 +5270,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -5288,19 +5285,19 @@ paths:
id: '42'
type: order
attributes:
- number: R920334041
+ number: R285593451
item_total: '10.0'
total: '110.0'
state: complete
adjustment_total: '0.0'
- completed_at: '2021-10-11T20:14:15.621Z'
+ completed_at: '2021-10-12T09:52:39.915Z'
payment_total: '0.0'
shipment_state: pending
payment_state: balance_due
special_instructions:
- created_at: '2021-10-11T20:14:15.367Z'
- updated_at: '2021-10-11T20:14:15.621Z'
+ created_at: '2021-10-12T09:52:39.609Z'
+ updated_at: '2021-10-12T09:52:39.915Z'
currency: USD
last_ip_address:
shipment_total: '100.0'
@@ -5316,6 +5313,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$110.00"
+ display_ship_total: "$100.00"
+ display_shipment_total: "$100.00"
display_total: "$110.00"
display_outstanding_balance: "$110.00"
display_item_total: "$10.00"
@@ -5326,9 +5326,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$110.00"
- display_ship_total: "$100.00"
- display_shipment_total: "$100.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$110.00"
@@ -5423,7 +5420,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -5438,7 +5435,7 @@ paths:
id: '45'
type: order
attributes:
- number: R964414747
+ number: R270864115
item_total: '0.0'
total: '0.0'
state: cart
@@ -5447,10 +5444,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:15.991Z'
- updated_at: '2021-10-11T20:14:16.126Z'
+ created_at: '2021-10-12T09:52:40.336Z'
+ updated_at: '2021-10-12T09:52:40.481Z'
currency: USD
last_ip_address:
shipment_total: '0.0'
@@ -5466,6 +5463,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$0.00"
+ display_ship_total: "$0.00"
+ display_shipment_total: "$0.00"
display_total: "$0.00"
display_outstanding_balance: "$0.00"
display_item_total: "$0.00"
@@ -5476,9 +5476,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$0.00"
- display_ship_total: "$0.00"
- display_shipment_total: "$0.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$0.00"
@@ -5557,7 +5554,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -5572,7 +5569,7 @@ paths:
id: '47'
type: order
attributes:
- number: R423177027
+ number: R291835383
item_total: '10.0'
total: '110.0'
state: delivery
@@ -5581,10 +5578,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:16.346Z'
- updated_at: '2021-10-11T20:14:16.450Z'
+ created_at: '2021-10-12T09:52:40.721Z'
+ updated_at: '2021-10-12T09:52:40.832Z'
currency: USD
last_ip_address:
shipment_total: '100.0'
@@ -5600,6 +5597,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$10.00"
+ display_ship_total: "$100.00"
+ display_shipment_total: "$100.00"
display_total: "$110.00"
display_outstanding_balance: "$110.00"
display_item_total: "$10.00"
@@ -5610,9 +5610,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$10.00"
- display_ship_total: "$100.00"
- display_shipment_total: "$100.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$110.00"
@@ -5695,7 +5692,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -5710,19 +5707,19 @@ paths:
id: '49'
type: order
attributes:
- number: R132977227
+ number: R844362570
item_total: '10.0'
total: '10.0'
state: canceled
adjustment_total: '0.0'
- completed_at: '2021-10-11T20:14:16.787Z'
+ completed_at: '2021-10-12T09:52:41.264Z'
payment_total: '0.0'
shipment_state: canceled
payment_state: void
special_instructions:
- created_at: '2021-10-11T20:14:16.663Z'
- updated_at: '2021-10-11T20:14:16.880Z'
+ created_at: '2021-10-12T09:52:41.103Z'
+ updated_at: '2021-10-12T09:52:41.403Z'
currency: USD
last_ip_address:
shipment_total: '0.0'
@@ -5738,6 +5735,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$10.00"
+ display_ship_total: "$0.00"
+ display_shipment_total: "$0.00"
display_total: "$10.00"
display_outstanding_balance: "$0.00"
display_item_total: "$10.00"
@@ -5748,9 +5748,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$10.00"
- display_ship_total: "$0.00"
- display_shipment_total: "$0.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$10.00"
@@ -5849,7 +5846,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -5864,7 +5861,7 @@ paths:
id: '52'
type: order
attributes:
- number: R357694375
+ number: R741527327
item_total: '10.0'
total: '110.0'
state: delivery
@@ -5873,10 +5870,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:17.233Z'
- updated_at: '2021-10-11T20:14:17.407Z'
+ created_at: '2021-10-12T09:52:41.902Z'
+ updated_at: '2021-10-12T09:52:42.110Z'
currency: USD
last_ip_address:
shipment_total: '100.0'
@@ -5892,6 +5889,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$10.00"
+ display_ship_total: "$100.00"
+ display_shipment_total: "$100.00"
display_total: "$110.00"
display_outstanding_balance: "$110.00"
display_item_total: "$10.00"
@@ -5902,9 +5902,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "$0.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$10.00"
- display_ship_total: "$100.00"
- display_shipment_total: "$100.00"
display_total_applicable_store_credit: "-$15.00"
display_total_applied_store_credit: "-$15.00"
display_order_total_after_store_credit: "$95.00"
@@ -6002,7 +5999,7 @@ paths:
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: line_items.variants.product
+ example: line_items,variants,product
schema:
type: string
responses:
@@ -6017,7 +6014,7 @@ paths:
id: '55'
type: order
attributes:
- number: R370317205
+ number: R217987993
item_total: '10.0'
total: '10.0'
state: delivery
@@ -6026,10 +6023,10 @@ paths:
payment_total: '0.0'
shipment_state:
payment_state:
special_instructions:
- created_at: '2021-10-11T20:14:17.808Z'
- updated_at: '2021-10-11T20:14:17.978Z'
+ created_at: '2021-10-12T09:52:42.635Z'
+ updated_at: '2021-10-12T09:52:42.998Z'
currency: USD
last_ip_address:
shipment_total: '100.0'
@@ -6045,6 +6042,9 @@ paths:
taxable_adjustment_total: '0.0'
non_taxable_adjustment_total: '0.0'
store_owner_notification_delivered:
+ display_pre_tax_total: "$10.00"
+ display_ship_total: "$100.00"
+ display_shipment_total: "$100.00"
display_total: "$10.00"
display_outstanding_balance: "$10.00"
display_item_total: "$10.00"
@@ -6055,9 +6055,6 @@ paths:
display_additional_tax_total: "$0.00"
display_promo_total: "-$100.00"
display_included_tax_total: "$0.00"
- display_pre_tax_total: "$10.00"
- display_ship_total: "$100.00"
- display_shipment_total: "$100.00"
display_total_applicable_store_credit: "$0.00"
display_total_applied_store_credit: "$0.00"
display_order_total_after_store_credit: "$10.00"
@@ -6161,13 +6158,13 @@ paths:
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: ''
+ example: cms_sections
schema:
type: string
- - name: filter
+ - name: filter[name_i_cont]
in: query
description: ''
- example: name_i_cont=defa
+ example: default
schema:
type: string
responses:
@@ -6183,24 +6180,24 @@ paths:
type: shipping_category
attributes:
name: 'ShippingCategory #77'
- created_at: '2021-10-11T20:14:18.345Z'
- updated_at: '2021-10-11T20:14:18.345Z'
+ created_at: '2021-10-12T09:52:43.419Z'
+ updated_at: '2021-10-12T09:52:43.419Z'
- id: '78'
type: shipping_category
attributes:
name: 'ShippingCategory #78'
- created_at: '2021-10-11T20:14:18.347Z'
- updated_at: '2021-10-11T20:14:18.347Z'
+ created_at: '2021-10-12T09:52:43.421Z'
+ updated_at: '2021-10-12T09:52:43.421Z'
meta:
count: 2
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/shipping_categories?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/shipping_categories?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/shipping_categories?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/shipping_categories?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/shipping_categories?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/shipping_categories?page=1&per_page=&include=&filter[name_i_cont]=
+ next: http://www.example.com/api/v2/platform/shipping_categories?filter%5Bname_i_cont%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/shipping_categories?filter%5Bname_i_cont%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/shipping_categories?filter%5Bname_i_cont%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/shipping_categories?filter%5Bname_i_cont%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -6222,7 +6219,7 @@ paths:
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: ''
+ example: cms_sections
schema:
type: string
responses:
@@ -6238,8 +6235,8 @@ paths:
type: shipping_category
attributes:
name: 'ShippingCategory #81'
- created_at: '2021-10-11T20:14:18.419Z'
- updated_at: '2021-10-11T20:14:18.419Z'
+ created_at: '2021-10-12T09:52:43.487Z'
+ updated_at: '2021-10-12T09:52:43.487Z'
'422':
description: invalid request
content:
@@ -6275,7 +6272,7 @@ paths:
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: ''
+ example: cms_sections
schema:
type: string
responses:
@@ -6291,8 +6288,8 @@ paths:
type: shipping_category
attributes:
name: 'ShippingCategory #82'
- created_at: '2021-10-11T20:14:18.460Z'
- updated_at: '2021-10-11T20:14:18.460Z'
+ created_at: '2021-10-12T09:52:43.532Z'
+ updated_at: '2021-10-12T09:52:43.532Z'
'404':
description: Record not found
content:
@@ -6327,7 +6324,7 @@ paths:
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: ''
+ example: cms_sections
schema:
type: string
responses:
@@ -6343,8 +6340,8 @@ paths:
type: shipping_category
attributes:
name: Default
- created_at: '2021-10-11T20:14:18.528Z'
- updated_at: '2021-10-11T20:14:18.538Z'
+ created_at: '2021-10-12T09:52:43.603Z'
+ updated_at: '2021-10-12T09:52:43.613Z'
'422':
description: invalid request
content:
@@ -6437,10 +6434,16 @@ paths:
example: taxonomy,parent,children
schema:
type: string
- - name: filter
+ - name: filter[taxonomy_id_eq]
+ in: query
+ description: ''
+ example: '1'
+ schema:
+ type: string
+ - name: filter[name_cont]
in: query
description: ''
- example: taxonomy_id_eq=1&name_cont=Shirts
+ example: Shirts
schema:
type: string
responses:
@@ -6461,8 +6464,8 @@ paths:
lft: 2
rgt: 3
description:
- created_at: '2021-10-11T20:14:18.782Z'
- updated_at: '2021-10-11T20:14:18.788Z'
+ created_at: '2021-10-12T09:52:43.924Z'
+ updated_at: '2021-10-12T09:52:43.929Z'
meta_title:
meta_description:
meta_keywords:
@@ -6496,8 +6499,8 @@ paths:
lft: 4
rgt: 5
description:
- created_at: '2021-10-11T20:14:18.882Z'
- updated_at: '2021-10-11T20:14:18.888Z'
+ created_at: '2021-10-12T09:52:44.032Z'
+ updated_at: '2021-10-12T09:52:44.037Z'
meta_title:
meta_description:
meta_keywords:
@@ -6531,8 +6534,8 @@ paths:
lft: 1
rgt: 6
description:
- created_at: '2021-10-11T20:14:18.692Z'
- updated_at: '2021-10-11T20:14:18.902Z'
+ created_at: '2021-10-12T09:52:43.821Z'
+ updated_at: '2021-10-12T09:52:44.052Z'
meta_title:
meta_description:
meta_keywords:
@@ -6562,11 +6565,11 @@ paths:
total_count: 3
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/taxons?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/taxons?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/taxons?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/taxons?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/taxons?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/taxons?page=1&per_page=&include=&filter[taxonomy_id_eq]=&filter[name_cont]=
+ next: http://www.example.com/api/v2/platform/taxons?filter%5Bname_cont%5D=&filter%5Btaxonomy_id_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/taxons?filter%5Bname_cont%5D=&filter%5Btaxonomy_id_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/taxons?filter%5Bname_cont%5D=&filter%5Btaxonomy_id_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/taxons?filter%5Bname_cont%5D=&filter%5Btaxonomy_id_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -6609,8 +6612,8 @@ paths:
lft: 2
rgt: 3
description:
- created_at: '2021-10-11T20:14:19.257Z'
- updated_at: '2021-10-11T20:14:19.263Z'
+ created_at: '2021-10-12T09:52:44.570Z'
+ updated_at: '2021-10-12T09:52:44.589Z'
meta_title:
meta_description:
meta_keywords:
@@ -6691,8 +6694,8 @@ paths:
lft: 2
rgt: 3
description:
- created_at: '2021-10-11T20:14:19.412Z'
- updated_at: '2021-10-11T20:14:19.417Z'
+ created_at: '2021-10-12T09:52:44.816Z'
+ updated_at: '2021-10-12T09:52:44.822Z'
meta_title:
meta_description:
meta_keywords:
@@ -6774,8 +6777,8 @@ paths:
lft: 2
rgt: 3
description:
- created_at: '2021-10-11T20:14:19.756Z'
- updated_at: '2021-10-11T20:14:19.795Z'
+ created_at: '2021-10-12T09:52:45.284Z'
+ updated_at: '2021-10-12T09:52:45.327Z'
meta_title:
meta_description:
meta_keywords:
@@ -6892,10 +6895,16 @@ paths:
example: ship_address,bill_address
schema:
type: string
- - name: filter
+ - name: filter[user_id_eq]
+ in: query
+ description: ''
+ example: '1'
+ schema:
+ type: string
+ - name: filter[email_cont]
in: query
description: ''
- example: user_id_eq=1&[email protected]
schema:
type: string
responses:
@@ -6910,9 +6919,9 @@ paths:
- id: '59'
type: user
attributes:
- created_at: '2021-10-11T20:14:20.492Z'
- updated_at: '2021-10-11T20:14:20.492Z'
+ created_at: '2021-10-12T09:52:46.158Z'
+ updated_at: '2021-10-12T09:52:46.158Z'
average_order_value: []
lifetime_value: []
store_credits: []
@@ -6924,9 +6933,9 @@ paths:
- id: '60'
type: user
attributes:
- created_at: '2021-10-11T20:14:20.509Z'
- updated_at: '2021-10-11T20:14:20.509Z'
+ created_at: '2021-10-12T09:52:46.172Z'
+ updated_at: '2021-10-12T09:52:46.172Z'
average_order_value: []
lifetime_value: []
store_credits: []
@@ -6938,9 +6947,9 @@ paths:
- id: '61'
type: user
attributes:
- created_at: '2021-10-11T20:14:20.513Z'
- updated_at: '2021-10-11T20:14:20.513Z'
+ created_at: '2021-10-12T09:52:46.177Z'
+ updated_at: '2021-10-12T09:52:46.177Z'
average_order_value: []
lifetime_value: []
store_credits: []
@@ -6954,11 +6963,11 @@ paths:
total_count: 3
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/users?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/users?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/users?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/users?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/users?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/users?page=1&per_page=&include=&filter[user_id_eq]=&filter[email_cont]=
+ next: http://www.example.com/api/v2/platform/users?filter%5Bemail_cont%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/users?filter%5Bemail_cont%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/users?filter%5Bemail_cont%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/users?filter%5Bemail_cont%5D=&filter%5Buser_id_eq%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -6995,9 +7004,9 @@ paths:
id: '66'
type: user
attributes:
- created_at: '2021-10-11T20:14:20.614Z'
- updated_at: '2021-10-11T20:14:20.614Z'
+ created_at: '2021-10-12T09:52:46.315Z'
+ updated_at: '2021-10-12T09:52:46.315Z'
average_order_value: []
lifetime_value: []
store_credits: []
@@ -7056,9 +7065,9 @@ paths:
id: '69'
type: user
attributes:
- created_at: '2021-10-11T20:14:20.680Z'
- updated_at: '2021-10-11T20:14:20.680Z'
+ created_at: '2021-10-12T09:52:46.424Z'
+ updated_at: '2021-10-12T09:52:46.424Z'
average_order_value: []
lifetime_value: []
store_credits: []
@@ -7117,8 +7126,8 @@ paths:
type: user
attributes:
- created_at: '2021-10-11T20:14:20.772Z'
- updated_at: '2021-10-11T20:14:20.784Z'
+ created_at: '2021-10-12T09:52:46.581Z'
+ updated_at: '2021-10-12T09:52:46.599Z'
average_order_value: []
lifetime_value: []
store_credits: []
@@ -7232,8 +7241,8 @@ paths:
type: wished_item
attributes:
quantity: 1
- created_at: '2021-10-11T20:14:21.165Z'
- updated_at: '2021-10-11T20:14:21.165Z'
+ created_at: '2021-10-12T09:52:47.158Z'
+ updated_at: '2021-10-12T09:52:47.158Z'
display_total: "$19.99"
display_price: "$19.99"
price: '19.99'
@@ -7247,8 +7256,8 @@ paths:
type: wished_item
attributes:
quantity: 1
- created_at: '2021-10-11T20:14:21.226Z'
- updated_at: '2021-10-11T20:14:21.226Z'
+ created_at: '2021-10-12T09:52:47.235Z'
+ updated_at: '2021-10-12T09:52:47.235Z'
display_total: "$19.99"
display_price: "$19.99"
price: '19.99'
@@ -7262,8 +7271,8 @@ paths:
type: wished_item
attributes:
quantity: 1
- created_at: '2021-10-11T20:14:21.284Z'
- updated_at: '2021-10-11T20:14:21.284Z'
+ created_at: '2021-10-12T09:52:47.316Z'
+ updated_at: '2021-10-12T09:52:47.316Z'
display_total: "$19.99"
display_price: "$19.99"
price: '19.99'
@@ -7277,8 +7286,8 @@ paths:
type: wished_item
attributes:
quantity: 1
- created_at: '2021-10-11T20:14:21.356Z'
- updated_at: '2021-10-11T20:14:21.356Z'
+ created_at: '2021-10-12T09:52:47.391Z'
+ updated_at: '2021-10-12T09:52:47.391Z'
display_total: "$19.99"
display_price: "$19.99"
price: '19.99'
@@ -7335,8 +7344,8 @@ paths:
type: wished_item
attributes:
quantity: 1
- created_at: '2021-10-11T20:14:21.841Z'
- updated_at: '2021-10-11T20:14:21.841Z'
+ created_at: '2021-10-12T09:52:48.227Z'
+ updated_at: '2021-10-12T09:52:48.227Z'
display_total: "$19.99"
display_price: "$19.99"
price: '19.99'
@@ -7402,8 +7411,8 @@ paths:
type: wished_item
attributes:
quantity: 1
- created_at: '2021-10-11T20:14:22.127Z'
- updated_at: '2021-10-11T20:14:22.127Z'
+ created_at: '2021-10-12T09:52:48.565Z'
+ updated_at: '2021-10-12T09:52:48.565Z'
display_total: "$19.99"
display_price: "$19.99"
price: '19.99'
@@ -7463,8 +7472,8 @@ paths:
type: wished_item
attributes:
quantity: 3
- created_at: '2021-10-11T20:14:22.727Z'
- updated_at: '2021-10-11T20:14:22.738Z'
+ created_at: '2021-10-12T09:52:49.140Z'
+ updated_at: '2021-10-12T09:52:49.153Z'
display_total: "$59.97"
display_price: "$19.99"
price: '19.99'
@@ -7566,10 +7575,10 @@ paths:
example: wished_items
schema:
type: string
- - name: filter
+ - name: filter[name_cont]
in: query
description: ''
- example: name_cont=Birthday
+ example: Birthday
schema:
type: string
responses:
@@ -7587,9 +7596,9 @@ paths:
name: Black Friday
is_private: true
is_default: false
- created_at: '2021-10-11T20:14:23.661Z'
- updated_at: '2021-10-11T20:14:23.661Z'
- token: ExaY6rx1RRcJxY9oNYbfYucg
+ created_at: '2021-10-12T09:52:50.434Z'
+ updated_at: '2021-10-12T09:52:50.434Z'
+ token: 2J9qzjrtYDGn15QfZoEvZ4QB
variant_included: false
relationships:
wished_items:
@@ -7604,9 +7613,9 @@ paths:
name: Birthday
is_private: true
is_default: false
- created_at: '2021-10-11T20:14:23.664Z'
- updated_at: '2021-10-11T20:14:23.664Z'
- token: 4fYw7kuBwqgAbKKpCMaDEMSp
+ created_at: '2021-10-12T09:52:50.436Z'
+ updated_at: '2021-10-12T09:52:50.436Z'
+ token: SvjQEY9k8jmonkDBEznpvoJf
variant_included: false
relationships:
wished_items:
@@ -7620,11 +7629,11 @@ paths:
total_count: 2
total_pages: 1
links:
- self: http://www.example.com/api/v2/platform/wishlists?page=1&per_page=&include=&filter=
- next: http://www.example.com/api/v2/platform/wishlists?include=&page=1&per_page=
- prev: http://www.example.com/api/v2/platform/wishlists?include=&page=1&per_page=
- last: http://www.example.com/api/v2/platform/wishlists?include=&page=1&per_page=
- first: http://www.example.com/api/v2/platform/wishlists?include=&page=1&per_page=
+ self: http://www.example.com/api/v2/platform/wishlists?page=1&per_page=&include=&filter[name_cont]=
+ next: http://www.example.com/api/v2/platform/wishlists?filter%5Bname_cont%5D=&include=&page=1&per_page=
+ prev: http://www.example.com/api/v2/platform/wishlists?filter%5Bname_cont%5D=&include=&page=1&per_page=
+ last: http://www.example.com/api/v2/platform/wishlists?filter%5Bname_cont%5D=&include=&page=1&per_page=
+ first: http://www.example.com/api/v2/platform/wishlists?filter%5Bname_cont%5D=&include=&page=1&per_page=
'401':
description: Authentication Failed
content:
@@ -7664,9 +7673,9 @@ paths:
name: Wishlist_26
is_private: true
is_default: false
- created_at: '2021-10-11T20:14:24.241Z'
- updated_at: '2021-10-11T20:14:24.241Z'
- token: GgnkhMtiHtxLtvP8dHGkK6pe
+ created_at: '2021-10-12T09:52:51.118Z'
+ updated_at: '2021-10-12T09:52:51.118Z'
+ token: CwcfrYAEoUEWCL8oA18c5hza
variant_included: false
relationships:
wished_items:
@@ -7726,9 +7735,9 @@ paths:
name: My Wishlist
is_private: true
is_default: false
- created_at: '2021-10-11T20:14:24.298Z'
- updated_at: '2021-10-11T20:14:24.298Z'
- token: dud7wqRmJANtBP4g1ccWDKRa
+ created_at: '2021-10-12T09:52:51.171Z'
+ updated_at: '2021-10-12T09:52:51.171Z'
+ token: 6QgZiAqh84BHYzCqk5rvUJcz
variant_included: false
relationships:
wished_items:
@@ -7785,9 +7794,9 @@ paths:
name: My Super Wishlist
is_private: true
is_default: false
- created_at: '2021-10-11T20:14:24.382Z'
- updated_at: '2021-10-11T20:14:24.393Z'
- token: tS5Jw42MBTwiZndy47VR2vhT
+ created_at: '2021-10-12T09:52:51.279Z'
+ updated_at: '2021-10-12T09:52:51.294Z'
+ token: VhEcmk8VkwyZpeGjBNN51Equ
variant_included: false
relationships:
wished_items:
@@ -8059,7 +8068,7 @@ components:
completed_at:
type: string
format: date_time
- example: 2021-10-11 20:13:53 UTC
+ example: 2021-10-12 09:52:15 UTC
bill_address_id:
type: string
example: '1'
@@ -8127,7 +8136,7 @@ components:
approved_at:
type: string
format: date_time
- example: 2021-10-11 20:13:53 UTC
+ example: 2021-10-12 09:52:15 UTC
confirmation_delivered:
type: boolean
example: true
diff --git a/api/lib/spree/api/testing_support/v2/platform_contexts.rb b/api/lib/spree/api/testing_support/v2/platform_contexts.rb
index 860302f76a..e60c406b1e 100644
--- a/api/lib/spree/api/testing_support/v2/platform_contexts.rb
+++ b/api/lib/spree/api/testing_support/v2/platform_contexts.rb
@@ -53,9 +53,14 @@ def json_api_include_parameter(example = '')
parameter name: :include, in: :query, type: :string, description: JSON_API_INCLUDES_DESCRIPTION, example: example
end
-def json_api_filter_parameter(example = '')
- let(:filter) { nil }
- parameter name: :filter, in: :query, type: :string, description: JSON_API_FILTER_DESCRIPTION, example: example
+def json_api_filter_parameter(examples = [])
+ examples.each do |api_filter|
+ name = api_filter[:name].to_sym
+ example = api_filter[:example]
+ let(name) { nil }
+
+ parameter name: name, in: :query, type: :string, description: JSON_API_FILTER_DESCRIPTION, example: example
+ end
end
shared_examples 'authentication failed' do
@@ -117,18 +122,17 @@ shared_examples 'invalid request' do |param_name|
end
# index action
-shared_examples 'GET records list' do |resource_name, include_example, filter_example|
- get "Return a list of #{resource_name.pluralize}" do
- tags resource_name.pluralize
+shared_examples 'GET records list' do |resource_name, **options|
+ endpoint_name = options[:custom_endpoint_name] || resource_name
+
+ get "Return a list of #{endpoint_name.pluralize}" do
+ tags endpoint_name.pluralize
security [ bearer_auth: [] ]
- description "Returns a list of #{resource_name.pluralize}"
+ description "Returns a list of #{endpoint_name.pluralize}"
operationId "#{resource_name.parameterize.pluralize.to_sym}-list"
include_context 'jsonapi pagination'
- json_api_include_parameter(include_example)
-
- if filter_example.present?
- json_api_filter_parameter(filter_example)
- end
+ json_api_include_parameter(options[:include_example]) unless options[:include_example].nil?
+ json_api_filter_parameter(options[:filter_examples]) unless options[:filter_examples].nil?
before { records_list }
@@ -138,14 +142,16 @@ shared_examples 'GET records list' do |resource_name, include_example, filter_ex
end
# show
-shared_examples 'GET record' do |resource_name, include_example|
- get "Return #{resource_name.articleize}" do
- tags resource_name.pluralize
+shared_examples 'GET record' do |resource_name, **options|
+ endpoint_name = options[:custom_endpoint_name] || resource_name
+
+ get "Return #{endpoint_name.articleize}" do
+ tags endpoint_name.pluralize
security [ bearer_auth: [] ]
- description "Returns #{resource_name.articleize}"
+ description "Returns #{endpoint_name.articleize}"
operationId "show-#{resource_name.parameterize.to_sym}"
parameter name: :id, in: :path, type: :string
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example]) unless options[:include_example].nil?
it_behaves_like 'record found'
it_behaves_like 'record not found'
@@ -154,17 +160,25 @@ shared_examples 'GET record' do |resource_name, include_example|
end
# create
-shared_examples 'POST create record' do |resource_name, include_example|
+shared_examples 'POST create record' do |resource_name, **options|
+ endpoint_name = options[:custom_endpoint_name] || resource_name
param_name = resource_name.parameterize(separator: '_').to_sym
-
- post "Create #{resource_name.articleize}" do
- tags resource_name.pluralize
- consumes 'application/json'
+ consumes_kind = options[:consumes_kind] || 'application/json'
+ request_data_type = case consumes_kind
+ when 'multipart/form-data'
+ :formData
+ else
+ :body
+ end
+
+ post "Create #{endpoint_name.articleize}" do
+ tags endpoint_name.pluralize
+ consumes consumes_kind
security [ bearer_auth: [] ]
- description "Creates #{resource_name.articleize}"
+ description "Creates #{endpoint_name.articleize}"
operationId "create-#{resource_name.parameterize.to_sym}"
- parameter name: param_name, in: :body, schema: { '$ref' => "#/components/schemas/#{param_name}_params" }
- json_api_include_parameter(include_example)
+ parameter name: param_name, in: request_data_type, schema: { '$ref' => "#/components/schemas/#{param_name}_params" }
+ json_api_include_parameter(options[:include_example]) unless options[:include_example].nil?
let(param_name) { valid_create_param_value }
@@ -174,18 +188,26 @@ shared_examples 'POST create record' do |resource_name, include_example|
end
# update
-shared_examples 'PATCH update record' do |resource_name, include_example|
+shared_examples 'PATCH update record' do |resource_name, **options|
+ endpoint_name = options[:custom_endpoint_name] || resource_name
param_name = resource_name.parameterize(separator: '_').to_sym
-
- patch "Update #{resource_name.articleize}" do
- tags resource_name.pluralize
+ consumes_kind = options[:consumes_kind] || 'application/json'
+ request_data_type = case consumes_kind
+ when 'multipart/form-data'
+ :formData
+ else
+ :body
+ end
+
+ patch "Update #{endpoint_name.articleize}" do
+ tags endpoint_name.pluralize
security [ bearer_auth: [] ]
- description "Updates #{resource_name.articleize}"
+ description "Updates #{endpoint_name.articleize}"
operationId "update-#{resource_name.parameterize.to_sym}"
- consumes 'application/json'
+ consumes consumes_kind
parameter name: :id, in: :path, type: :string
- parameter name: param_name, in: :body, schema: { '$ref' => "#/components/schemas/#{param_name}_params" }
- json_api_include_parameter(include_example)
+ parameter name: param_name, in: request_data_type, schema: { '$ref' => "#/components/schemas/#{param_name}_params" }
+ json_api_include_parameter(options[:include_example]) unless options[:include_example].nil?
let(param_name) { valid_update_param_value }
@@ -197,11 +219,13 @@ shared_examples 'PATCH update record' do |resource_name, include_example|
end
# destroy
-shared_examples 'DELETE record' do |resource_name|
- delete "Delete #{resource_name.articleize}" do
- tags resource_name.pluralize
+shared_examples 'DELETE record' do |resource_name, **options|
+ endpoint_name = options[:custom_endpoint_name] || resource_name
+
+ delete "Delete #{endpoint_name.articleize}" do
+ tags endpoint_name.pluralize
security [ bearer_auth: [] ]
- description "Deletes #{resource_name.articleize}"
+ description "Deletes #{endpoint_name.articleize}"
operationId "delete-#{resource_name.parameterize.to_sym}"
parameter name: :id, in: :path, type: :string
@@ -211,17 +235,17 @@ shared_examples 'DELETE record' do |resource_name|
end
end
-shared_examples 'CRUD examples' do |resource_name, include_example, filter_example|
+shared_examples 'CRUD examples' do |resource_name, **options|
resource_path = resource_name.parameterize(separator: '_').pluralize
path "/api/v2/platform/#{resource_path}" do
- include_examples 'GET records list', resource_name, include_example, filter_example
- include_examples 'POST create record', resource_name, include_example
+ include_examples 'GET records list', resource_name, options
+ include_examples 'POST create record', resource_name, options
end
path "/api/v2/platform/#{resource_path}/{id}" do
- include_examples 'GET record', resource_name, include_example
- include_examples 'PATCH update record', resource_name, include_example
- include_examples 'DELETE record', resource_name
+ include_examples 'GET record', resource_name, options
+ include_examples 'PATCH update record', resource_name, options
+ include_examples 'DELETE record', resource_name, options
end
end
diff --git a/api/spec/integration/api/v2/platform/addresses_spec.rb b/api/spec/integration/api/v2/platform/addresses_spec.rb
index c10d5549f3..ba1b2f4974 100644
--- a/api/spec/integration/api/v2/platform/addresses_spec.rb
+++ b/api/spec/integration/api/v2/platform/addresses_spec.rb
@@ -4,8 +4,11 @@ describe 'Addresses API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Address'
- include_example = 'user,country,state'
- filter_example = 'user_id_eq=1&firstname_cont=Joh'
+ options = {
+ include_example: 'user,country,state',
+ filter_examples: [{ name: 'filter[user_id_eq]', example: '1' },
+ { name: 'filter[firstname_cont]', example: 'John' }]
+ }
let(:id) { create(:address).id }
let(:records_list) { create_list(:address, 2) }
@@ -25,5 +28,5 @@ describe 'Addresses API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/adjustments_spec.rb b/api/spec/integration/api/v2/platform/adjustments_spec.rb
index 3e6b7b38dd..9e6c7ae2c7 100644
--- a/api/spec/integration/api/v2/platform/adjustments_spec.rb
+++ b/api/spec/integration/api/v2/platform/adjustments_spec.rb
@@ -4,8 +4,10 @@ describe 'Adjustments API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Adjustment'
- include_example = 'order,adjustable'
- filter_example = 'order_id=123456'
+ options = {
+ include_example: 'order,adjustable',
+ filter_examples: [{ name: 'filter[order_id]', example: '1234' }]
+ }
let(:line_item) { create(:line_item, order: order) }
let(:id) { create(:adjustment, order: order, adjustable: line_item).id }
@@ -24,5 +26,5 @@ describe 'Adjustments API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/classifications_spec.rb b/api/spec/integration/api/v2/platform/classifications_spec.rb
index 3393dc23e8..c2919d39fa 100644
--- a/api/spec/integration/api/v2/platform/classifications_spec.rb
+++ b/api/spec/integration/api/v2/platform/classifications_spec.rb
@@ -4,8 +4,10 @@ describe 'Classifications API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Classification'
- include_example = 'product,taxon'
- filter_example = 'taxon_id_eq=1'
+ options = {
+ include_example: 'product,taxon',
+ filter_examples: [{ name: 'filter[taxon_id_eq]', example: '1' }]
+ }
let(:id) { create(:classification).id }
let(:records_list) { create_list(:classification, 2) }
@@ -23,7 +25,7 @@ describe 'Classifications API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
path '/api/v2/platform/classifications/{id}/reposition' do
patch 'Reposition a Classification' do
@@ -34,7 +36,7 @@ describe 'Classifications API', swagger: true do
consumes 'application/json'
parameter name: :id, in: :path, type: :string
parameter name: :classification, in: :body, schema: { '$ref' => '#/components/schemas/classification_params' }
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
let(:classification) { valid_update_param_value }
let(:invalid_param_value) do
diff --git a/api/spec/integration/api/v2/platform/cms_pages_spec.rb b/api/spec/integration/api/v2/platform/cms_pages_spec.rb
index 5a68270e10..4ad65acdfc 100644
--- a/api/spec/integration/api/v2/platform/cms_pages_spec.rb
+++ b/api/spec/integration/api/v2/platform/cms_pages_spec.rb
@@ -4,8 +4,11 @@ describe 'CMS Pages API', swagger: true do
include_context 'Platform API v2'
resource_name = 'CMS Page'
- include_example = 'cms_sections'
- filter_example = 'type=homepage'
+ options = {
+ include_example: 'cms_sections',
+ filter_examples: [{ name: 'filter[type]', example: 'homepage' },
+ { name: 'filter[title_cont]', example: 'About Us' }]
+ }
let(:store) { Spree::Store.default }
@@ -23,5 +26,5 @@ describe 'CMS Pages API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/cms_sections_spec.rb b/api/spec/integration/api/v2/platform/cms_sections_spec.rb
index 8ce9517414..99ad8e4d32 100644
--- a/api/spec/integration/api/v2/platform/cms_sections_spec.rb
+++ b/api/spec/integration/api/v2/platform/cms_sections_spec.rb
@@ -4,8 +4,10 @@ describe 'CMS Section API', swagger: true do
include_context 'Platform API v2'
resource_name = 'CMS Section'
- include_example = 'product'
- filter_example = 'name_eq=Hero'
+ options = {
+ include_example: 'product',
+ filter_examples: [{ name: 'filter[name_eq]', example: 'Hero' }]
+ }
let!(:store) { Spree::Store.default }
let!(:product) { create(:product) }
@@ -34,7 +36,7 @@ describe 'CMS Section API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
path '/api/v2/platform/cms_sections/{id}/reposition' do
patch 'Reposition a CMS Section' do
diff --git a/api/spec/integration/api/v2/platform/line_items_spec.rb b/api/spec/integration/api/v2/platform/line_items_spec.rb
index ee2aa8b92d..de11dd4164 100644
--- a/api/spec/integration/api/v2/platform/line_items_spec.rb
+++ b/api/spec/integration/api/v2/platform/line_items_spec.rb
@@ -4,8 +4,10 @@ describe 'Line Items API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Line Item'
- include_example = 'order,tax_category,variant.product'
- filter_example = 'order_id_eq=1'
+ options = {
+ include_example: 'order,tax_category,variant.product',
+ filter_examples: [{ name: 'filter[order_id_eq]', example: '123' }]
+ }
let(:product) { create(:product_in_stock, :without_backorder, stores: [store]) }
let(:variant) { product.master }
@@ -26,5 +28,5 @@ describe 'Line Items API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/menu_items_spec.rb b/api/spec/integration/api/v2/platform/menu_items_spec.rb
index cf0ee1b4b3..226d0b4eb7 100644
--- a/api/spec/integration/api/v2/platform/menu_items_spec.rb
+++ b/api/spec/integration/api/v2/platform/menu_items_spec.rb
@@ -4,8 +4,10 @@ describe 'Menu Items API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Menu Item'
- include_example = 'linked_resource'
- filter_example = 'menu_item_name_eq=Women'
+ options = {
+ include_example: 'linked_resource',
+ filter_examples: [{ name: 'filter[menu_item_name_eq]', example: 'Women' }]
+ }
let(:menu) { create(:menu, store: store) }
let(:id) { create(:menu_item, menu: menu).id }
@@ -32,7 +34,7 @@ describe 'Menu Items API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
path '/api/v2/platform/menu_items/{id}/reposition' do
patch 'Reposition a Menu Item' do
diff --git a/api/spec/integration/api/v2/platform/menus_spec.rb b/api/spec/integration/api/v2/platform/menus_spec.rb
index 7998195a51..c50e5adc9a 100644
--- a/api/spec/integration/api/v2/platform/menus_spec.rb
+++ b/api/spec/integration/api/v2/platform/menus_spec.rb
@@ -4,8 +4,10 @@ describe 'Menus API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Menu'
- include_example = 'menu_items'
- filter_example = 'location_eq=header'
+ options = {
+ include_example: 'menu_items',
+ filter_examples: [{ name: 'filter[location_eq]', example: 'header' }]
+ }
let(:id) { create(:menu, name: 'Main Menu').id }
let(:records_list) do
@@ -47,5 +49,5 @@ describe 'Menus API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/option_types_spec.rb b/api/spec/integration/api/v2/platform/option_types_spec.rb
index 9af4a29701..b76c9fe7f3 100644
--- a/api/spec/integration/api/v2/platform/option_types_spec.rb
+++ b/api/spec/integration/api/v2/platform/option_types_spec.rb
@@ -4,8 +4,10 @@ describe 'Option Types API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Option Type'
- include_example = ''
- filter_example = 'option_type_id_eq=1&name_cont=Size'
+ options = {
+ filter_examples: [{ name: 'filter[option_type_id_eq]', example: '1' },
+ { name: 'filter[name_cont]', example: 'Size' }]
+ }
let(:id) { create(:option_type).id }
let(:option_type) { create(:option_type) }
@@ -22,5 +24,5 @@ describe 'Option Types API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/option_values_spec.rb b/api/spec/integration/api/v2/platform/option_values_spec.rb
index 7e6dcbb36c..72dec896bf 100644
--- a/api/spec/integration/api/v2/platform/option_values_spec.rb
+++ b/api/spec/integration/api/v2/platform/option_values_spec.rb
@@ -4,8 +4,11 @@ describe 'Option Values API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Option Value'
- include_example = 'option_type'
- filter_example = 'option_type_id_eq=1&name_cont=M'
+ options = {
+ include_example: 'option_type',
+ filter_examples: [{ name: 'filter[option_type_id_eq]', example: '1' },
+ { name: 'filter[name_cont]', example: 'Red' }]
+ }
let(:id) { create(:option_value).id }
let(:option_type) { create(:option_value) }
@@ -22,5 +25,5 @@ describe 'Option Values API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/orders_spec.rb b/api/spec/integration/api/v2/platform/orders_spec.rb
index 9de56a8a8c..1d49a92062 100644
--- a/api/spec/integration/api/v2/platform/orders_spec.rb
+++ b/api/spec/integration/api/v2/platform/orders_spec.rb
@@ -5,8 +5,10 @@ describe 'Orders API', swagger: true do
resource_name = 'Order'
resource_path = 'orders'
- include_example = 'line_items.variants.product'
- filter_example = 'state_eq=complete'
+ options = {
+ include_example: 'line_items,variants,product',
+ filter_examples: [{ name: 'filter[state_eq]', example: 'complete' }]
+ }
let(:persisted_order) { create(:order_with_line_items, state: :delivery) }
let(:id) { persisted_order.number }
@@ -54,7 +56,7 @@ describe 'Orders API', swagger: true do
end
path "/api/v2/platform/#{resource_path}" do
- include_examples 'GET records list', resource_name, include_example, filter_example
+ include_examples 'GET records list', resource_name, options
param_name = resource_name.parameterize(separator: '_').to_sym
post "Creates #{resource_name.articleize}" do
@@ -64,7 +66,7 @@ describe 'Orders API', swagger: true do
description "Creates #{resource_name.articleize}"
operationId "create-#{resource_name.parameterize.to_sym}"
parameter name: param_name, in: :body, schema: { '$ref' => "#/components/schemas/#{param_name}_params" }
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
let(param_name) { valid_create_param_value }
@@ -74,8 +76,8 @@ describe 'Orders API', swagger: true do
end
path "/api/v2/platform/#{resource_path}/{id}" do
- include_examples 'GET record', resource_name, include_example
- include_examples 'PATCH update record', resource_name, include_example
+ include_examples 'GET record', resource_name, options
+ include_examples 'PATCH update record', resource_name, options
include_examples 'DELETE record', resource_name
end
@@ -87,7 +89,7 @@ describe 'Orders API', swagger: true do
operationId "advance-#{resource_name.parameterize.to_sym}"
consumes 'application/json'
parameter name: :id, in: :path, type: :string
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
response '200', 'record updated' do
run_test!
@@ -105,7 +107,7 @@ describe 'Orders API', swagger: true do
operationId "next-#{resource_name.parameterize.to_sym}"
consumes 'application/json'
parameter name: :id, in: :path, type: :string
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
response '200', 'record updated' do
run_test!
@@ -127,7 +129,7 @@ describe 'Orders API', swagger: true do
operationId "complete-#{resource_name.parameterize.to_sym}"
consumes 'application/json'
parameter name: :id, in: :path, type: :string
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
response '200', 'record updated' do
run_test!
@@ -145,7 +147,7 @@ describe 'Orders API', swagger: true do
operationId "empty-#{resource_name.parameterize.to_sym}"
consumes 'application/json'
parameter name: :id, in: :path, type: :string
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
response '200', 'record updated' do
run_test!
@@ -163,7 +165,7 @@ describe 'Orders API', swagger: true do
operationId "approve-#{resource_name.parameterize.to_sym}"
consumes 'application/json'
parameter name: :id, in: :path, type: :string
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
response '200', 'record approved' do
run_test!
@@ -181,7 +183,7 @@ describe 'Orders API', swagger: true do
operationId "cancel-#{resource_name.parameterize.to_sym}"
consumes 'application/json'
parameter name: :id, in: :path, type: :string
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
response '200', 'record cancelled' do
let(:id) { create(:completed_order_with_totals).id }
@@ -204,7 +206,7 @@ describe 'Orders API', swagger: true do
consumes 'application/json'
parameter name: :id, in: :path, type: :string
parameter name: :amount, in: :body, schema: { '$ref' => '#/components/schemas/amount_param' }
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
let!(:store_credit_payment_method) { create(:store_credit_payment_method) }
@@ -231,7 +233,7 @@ describe 'Orders API', swagger: true do
consumes 'application/json'
parameter name: :id, in: :path, type: :string
parameter name: :coupon_code, in: :body, schema: { '$ref' => '#/components/schemas/coupon_code_param' }
- json_api_include_parameter(include_example)
+ json_api_include_parameter(options[:include_example])
let!(:promotion) { create(:promotion, name: 'Free shipping', code: 'freeship', stores: [store]) }
let(:coupon_code) { { coupon_code: promotion.code } }
diff --git a/api/spec/integration/api/v2/platform/shipping_categories_spec.rb b/api/spec/integration/api/v2/platform/shipping_categories_spec.rb
index 6018e52a45..4c953a9132 100644
--- a/api/spec/integration/api/v2/platform/shipping_categories_spec.rb
+++ b/api/spec/integration/api/v2/platform/shipping_categories_spec.rb
@@ -4,8 +4,10 @@ describe 'Taxons API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Shipping Category'
- include_example = ''
- filter_example = 'name_i_cont=defa'
+ options = {
+ include_example: 'cms_sections',
+ filter_examples: [{ name: 'filter[name_i_cont]', example: 'default' }]
+ }
let(:id) { create(:shipping_category).id }
let(:records_list) { create_list(:shipping_category, 2) }
@@ -21,5 +23,5 @@ describe 'Taxons API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/taxons_spec.rb b/api/spec/integration/api/v2/platform/taxons_spec.rb
index d1d7162ad9..737ba98840 100644
--- a/api/spec/integration/api/v2/platform/taxons_spec.rb
+++ b/api/spec/integration/api/v2/platform/taxons_spec.rb
@@ -4,8 +4,11 @@ describe 'Taxons API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Taxon'
- include_example = 'taxonomy,parent,children'
- filter_example = 'taxonomy_id_eq=1&name_cont=Shirts'
+ options = {
+ include_example: 'taxonomy,parent,children',
+ filter_examples: [{ name: 'filter[taxonomy_id_eq]', example: '1' },
+ { name: 'filter[name_cont]', example: 'Shirts' }]
+ }
let(:id) { create(:taxon).id }
let(:taxonomy) { create(:taxonomy, store: store) }
@@ -22,5 +25,5 @@ describe 'Taxons API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/users_spec.rb b/api/spec/integration/api/v2/platform/users_spec.rb
index bd1409b41f..e9eda5ff1d 100644
--- a/api/spec/integration/api/v2/platform/users_spec.rb
+++ b/api/spec/integration/api/v2/platform/users_spec.rb
@@ -4,8 +4,11 @@ describe 'Users API', swagger: true do
include_context 'Platform API v2'
resource_name = 'User'
- include_example = 'ship_address,bill_address'
- filter_example = 'user_id_eq=1&[email protected]'
+ options = {
+ include_example: 'ship_address,bill_address',
+ filter_examples: [{ name: 'filter[user_id_eq]', example: '1' },
+ { name: 'filter[email_cont]', example: '[email protected]' }]
+ }
let(:id) { create(:user).id }
let(:option_type) { create(:user, store: store) }
@@ -24,5 +27,5 @@ describe 'Users API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/wished_items_spec.rb b/api/spec/integration/api/v2/platform/wished_items_spec.rb
index 16a0b43110..886819243d 100644
--- a/api/spec/integration/api/v2/platform/wished_items_spec.rb
+++ b/api/spec/integration/api/v2/platform/wished_items_spec.rb
@@ -4,7 +4,9 @@ describe 'Wished Item API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Wished Item'
- include_example = 'variant'
+ options = {
+ include_example: 'variant'
+ }
let!(:user) { create(:user) }
let!(:wishlist) { create(:wishlist) }
@@ -25,5 +27,5 @@ describe 'Wished Item API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example
+ include_examples 'CRUD examples', resource_name, options
end
diff --git a/api/spec/integration/api/v2/platform/wishlists_spec.rb b/api/spec/integration/api/v2/platform/wishlists_spec.rb
index 93bb13e7e8..30b494e35f 100644
--- a/api/spec/integration/api/v2/platform/wishlists_spec.rb
+++ b/api/spec/integration/api/v2/platform/wishlists_spec.rb
@@ -4,8 +4,10 @@ describe 'Wishlists API', swagger: true do
include_context 'Platform API v2'
resource_name = 'Wishlist'
- include_example = 'wished_items'
- filter_example = 'name_cont=Birthday'
+ options = {
+ include_example: 'wished_items',
+ filter_examples: [{ name: 'filter[name_cont]', example: 'Birthday' }]
+ }
let!(:user) { create(:user) }
@@ -43,5 +45,5 @@ describe 'Wishlists API', swagger: true do
}
end
- include_examples 'CRUD examples', resource_name, include_example, filter_example
+ include_examples 'CRUD examples', resource_name, options
end