mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-27 01:43:22 +00:00
Make list of /products/{product_id}/variants endpoints correct according to current code
This commit is contained in:
44
swagger.yaml
44
swagger.yaml
@@ -241,27 +241,7 @@ paths:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Variant'
|
||||
|
||||
/products/{product_id}/variants/new:
|
||||
get:
|
||||
description: Gets an object consisting of an array of all Variant attributes and an array of required attributes to create a new Variant object.
|
||||
tags:
|
||||
- product variants
|
||||
parameters:
|
||||
- in: path
|
||||
name: product_id
|
||||
schema:
|
||||
type: integer
|
||||
required: true
|
||||
description: Numeric ID of the Product.
|
||||
responses:
|
||||
'200':
|
||||
description: successful operation
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/New'
|
||||
|
||||
|
||||
/products/{product_id}/variants/{variant_id}:
|
||||
get:
|
||||
description: Gets a Variant by ID.
|
||||
@@ -341,6 +321,28 @@ paths:
|
||||
'204':
|
||||
description: successful deletion
|
||||
|
||||
/products/{product_id}/variants/{variant_id}/soft_delete:
|
||||
delete:
|
||||
description: Soft-deletes the Variant with the given ID.
|
||||
tags:
|
||||
- product variants
|
||||
parameters:
|
||||
- in: path
|
||||
name: product_id
|
||||
schema:
|
||||
type: integer
|
||||
required: true
|
||||
description: Numeric ID of the Product.
|
||||
- in: path
|
||||
name: variant_id
|
||||
schema:
|
||||
type: integer
|
||||
required: true
|
||||
description: Numeric ID of the Variant.
|
||||
responses:
|
||||
'204':
|
||||
description: successful deletion
|
||||
|
||||
/taxonomies:
|
||||
get:
|
||||
description: Gets all Taxonomies.
|
||||
|
||||
Reference in New Issue
Block a user