chore(oas): [11/n] improve oas schemas (#9188)

Improve OAS schemas [11/n]
This commit is contained in:
Shahed Nasser
2024-09-19 17:24:54 +03:00
committed by GitHub
parent 8dd72acee2
commit 89928dfdf3
20 changed files with 98 additions and 804 deletions

View File

@@ -1,741 +0,0 @@
/**
* @schema AdminProductVariantParams
* type: object
* description: SUMMARY
* x-schemaName: AdminProductVariantParams
* properties:
* q:
* type: string
* title: q
* description: The product's q.
* id:
* oneOf:
* - type: string
* title: id
* description: The product's ID.
* - type: array
* description: The product's ID.
* items:
* type: string
* title: id
* description: The id's ID.
* manage_inventory:
* type: boolean
* title: manage_inventory
* description: The product's manage inventory.
* allow_backorder:
* type: boolean
* title: allow_backorder
* description: The product's allow backorder.
* created_at:
* type: object
* description: The product's created at.
* properties:
* $and:
* type: array
* description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $and
* $or:
* type: array
* description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $or
* $eq:
* oneOf:
* - type: string
* title: $eq
* description: Filter by an exact match.
* - type: array
* description: Filter by an exact match.
* items:
* type: string
* title: $eq
* description: Filter by an exact match.
* $ne:
* type: string
* title: $ne
* description: Filter by values not equal to this parameter.
* $in:
* type: array
* description: Filter by values in this array.
* items:
* type: string
* title: $in
* description: Filter by values in this array.
* $nin:
* type: array
* description: Filter by values not in this array.
* items:
* type: string
* title: $nin
* description: Filter by values not in this array.
* $not:
* oneOf:
* - type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* - type: object
* description: Filter by values not matching the conditions in this parameter.
* properties:
* $and:
* type: array
* description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $and
* $or:
* type: array
* description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $or
* $eq:
* oneOf:
* - type: string
* title: $eq
* description: Filter by an exact match.
* - type: array
* description: Filter by an exact match.
* items:
* type: string
* title: $eq
* description: Filter by an exact match.
* $ne:
* type: string
* title: $ne
* description: Filter by values not equal to this parameter.
* $in:
* type: array
* description: Filter by values in this array.
* items:
* type: string
* title: $in
* description: Filter by values in this array.
* $nin:
* type: array
* description: Filter by values not in this array.
* items:
* type: string
* title: $nin
* description: Filter by values not in this array.
* $not:
* oneOf:
* - type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* - type: object
* description: Filter by values not matching the conditions in this parameter.
* - type: array
* description: Filter by values not matching the conditions in this parameter.
* items:
* type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* $gt:
* type: string
* title: $gt
* description: Filter by values greater than this parameter. Useful for numbers and dates only.
* $gte:
* type: string
* title: $gte
* description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only.
* $lt:
* type: string
* title: $lt
* description: Filter by values less than this parameter. Useful for numbers and dates only.
* $lte:
* type: string
* title: $lte
* description: Filter by values less than or equal to this parameter. Useful for numbers and dates only.
* $like:
* type: string
* title: $like
* description: Apply a `like` filter. Useful for strings only.
* $re:
* type: string
* title: $re
* description: Apply a regex filter. Useful for strings only.
* $ilike:
* type: string
* title: $ilike
* description: Apply a case-insensitive `like` filter. Useful for strings only.
* $fulltext:
* type: string
* title: $fulltext
* description: Filter to apply on full-text properties.
* $overlap:
* type: array
* description: Filter arrays that have overlapping values with this parameter.
* items:
* type: string
* title: $overlap
* description: Filter arrays that have overlapping values with this parameter.
* $contains:
* type: array
* description: Filter arrays that contain some of the values of this parameter.
* items:
* type: string
* title: $contains
* description: Filter arrays that contain some of the values of this parameter.
* $contained:
* type: array
* description: Filter arrays that contain all values of this parameter.
* items:
* type: string
* title: $contained
* description: Filter arrays that contain all values of this parameter.
* $exists:
* type: boolean
* title: $exists
* description: Filter by whether a value for this parameter exists (not `null`).
* - type: array
* description: Filter by values not matching the conditions in this parameter.
* items:
* type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* $gt:
* type: string
* title: $gt
* description: Filter by values greater than this parameter. Useful for numbers and dates only.
* $gte:
* type: string
* title: $gte
* description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only.
* $lt:
* type: string
* title: $lt
* description: Filter by values less than this parameter. Useful for numbers and dates only.
* $lte:
* type: string
* title: $lte
* description: Filter by values less than or equal to this parameter. Useful for numbers and dates only.
* $like:
* type: string
* title: $like
* description: Apply a `like` filter. Useful for strings only.
* $re:
* type: string
* title: $re
* description: Apply a regex filter. Useful for strings only.
* $ilike:
* type: string
* title: $ilike
* description: Apply a case-insensitive `like` filter. Useful for strings only.
* $fulltext:
* type: string
* title: $fulltext
* description: Filter to apply on full-text properties.
* $overlap:
* type: array
* description: Filter arrays that have overlapping values with this parameter.
* items:
* type: string
* title: $overlap
* description: Filter arrays that have overlapping values with this parameter.
* $contains:
* type: array
* description: Filter arrays that contain some of the values of this parameter.
* items:
* type: string
* title: $contains
* description: Filter arrays that contain some of the values of this parameter.
* $contained:
* type: array
* description: Filter arrays that contain all values of this parameter.
* items:
* type: string
* title: $contained
* description: Filter arrays that contain all values of this parameter.
* $exists:
* type: boolean
* title: $exists
* description: Filter by whether a value for this parameter exists (not `null`).
* updated_at:
* type: object
* description: The product's updated at.
* properties:
* $and:
* type: array
* description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $and
* $or:
* type: array
* description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $or
* $eq:
* oneOf:
* - type: string
* title: $eq
* description: Filter by an exact match.
* - type: array
* description: Filter by an exact match.
* items:
* type: string
* title: $eq
* description: Filter by an exact match.
* $ne:
* type: string
* title: $ne
* description: Filter by values not equal to this parameter.
* $in:
* type: array
* description: Filter by values in this array.
* items:
* type: string
* title: $in
* description: Filter by values in this array.
* $nin:
* type: array
* description: Filter by values not in this array.
* items:
* type: string
* title: $nin
* description: Filter by values not in this array.
* $not:
* oneOf:
* - type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* - type: object
* description: Filter by values not matching the conditions in this parameter.
* properties:
* $and:
* type: array
* description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $and
* $or:
* type: array
* description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $or
* $eq:
* oneOf:
* - type: string
* title: $eq
* description: Filter by an exact match.
* - type: array
* description: Filter by an exact match.
* items:
* type: string
* title: $eq
* description: Filter by an exact match.
* $ne:
* type: string
* title: $ne
* description: Filter by values not equal to this parameter.
* $in:
* type: array
* description: Filter by values in this array.
* items:
* type: string
* title: $in
* description: Filter by values in this array.
* $nin:
* type: array
* description: Filter by values not in this array.
* items:
* type: string
* title: $nin
* description: Filter by values not in this array.
* $not:
* oneOf:
* - type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* - type: object
* description: Filter by values not matching the conditions in this parameter.
* - type: array
* description: Filter by values not matching the conditions in this parameter.
* items:
* type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* $gt:
* type: string
* title: $gt
* description: Filter by values greater than this parameter. Useful for numbers and dates only.
* $gte:
* type: string
* title: $gte
* description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only.
* $lt:
* type: string
* title: $lt
* description: Filter by values less than this parameter. Useful for numbers and dates only.
* $lte:
* type: string
* title: $lte
* description: Filter by values less than or equal to this parameter. Useful for numbers and dates only.
* $like:
* type: string
* title: $like
* description: Apply a `like` filter. Useful for strings only.
* $re:
* type: string
* title: $re
* description: Apply a regex filter. Useful for strings only.
* $ilike:
* type: string
* title: $ilike
* description: Apply a case-insensitive `like` filter. Useful for strings only.
* $fulltext:
* type: string
* title: $fulltext
* description: Filter to apply on full-text properties.
* $overlap:
* type: array
* description: Filter arrays that have overlapping values with this parameter.
* items:
* type: string
* title: $overlap
* description: Filter arrays that have overlapping values with this parameter.
* $contains:
* type: array
* description: Filter arrays that contain some of the values of this parameter.
* items:
* type: string
* title: $contains
* description: Filter arrays that contain some of the values of this parameter.
* $contained:
* type: array
* description: Filter arrays that contain all values of this parameter.
* items:
* type: string
* title: $contained
* description: Filter arrays that contain all values of this parameter.
* $exists:
* type: boolean
* title: $exists
* description: Filter by whether a value for this parameter exists (not `null`).
* - type: array
* description: Filter by values not matching the conditions in this parameter.
* items:
* type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* $gt:
* type: string
* title: $gt
* description: Filter by values greater than this parameter. Useful for numbers and dates only.
* $gte:
* type: string
* title: $gte
* description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only.
* $lt:
* type: string
* title: $lt
* description: Filter by values less than this parameter. Useful for numbers and dates only.
* $lte:
* type: string
* title: $lte
* description: Filter by values less than or equal to this parameter. Useful for numbers and dates only.
* $like:
* type: string
* title: $like
* description: Apply a `like` filter. Useful for strings only.
* $re:
* type: string
* title: $re
* description: Apply a regex filter. Useful for strings only.
* $ilike:
* type: string
* title: $ilike
* description: Apply a case-insensitive `like` filter. Useful for strings only.
* $fulltext:
* type: string
* title: $fulltext
* description: Filter to apply on full-text properties.
* $overlap:
* type: array
* description: Filter arrays that have overlapping values with this parameter.
* items:
* type: string
* title: $overlap
* description: Filter arrays that have overlapping values with this parameter.
* $contains:
* type: array
* description: Filter arrays that contain some of the values of this parameter.
* items:
* type: string
* title: $contains
* description: Filter arrays that contain some of the values of this parameter.
* $contained:
* type: array
* description: Filter arrays that contain all values of this parameter.
* items:
* type: string
* title: $contained
* description: Filter arrays that contain all values of this parameter.
* $exists:
* type: boolean
* title: $exists
* description: Filter by whether a value for this parameter exists (not `null`).
* deleted_at:
* type: object
* description: The product's deleted at.
* properties:
* $and:
* type: array
* description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $and
* $or:
* type: array
* description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $or
* $eq:
* oneOf:
* - type: string
* title: $eq
* description: Filter by an exact match.
* - type: array
* description: Filter by an exact match.
* items:
* type: string
* title: $eq
* description: Filter by an exact match.
* $ne:
* type: string
* title: $ne
* description: Filter by values not equal to this parameter.
* $in:
* type: array
* description: Filter by values in this array.
* items:
* type: string
* title: $in
* description: Filter by values in this array.
* $nin:
* type: array
* description: Filter by values not in this array.
* items:
* type: string
* title: $nin
* description: Filter by values not in this array.
* $not:
* oneOf:
* - type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* - type: object
* description: Filter by values not matching the conditions in this parameter.
* properties:
* $and:
* type: array
* description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $and
* $or:
* type: array
* description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $or
* $eq:
* oneOf:
* - type: string
* title: $eq
* description: Filter by an exact match.
* - type: array
* description: Filter by an exact match.
* items:
* type: string
* title: $eq
* description: Filter by an exact match.
* $ne:
* type: string
* title: $ne
* description: Filter by values not equal to this parameter.
* $in:
* type: array
* description: Filter by values in this array.
* items:
* type: string
* title: $in
* description: Filter by values in this array.
* $nin:
* type: array
* description: Filter by values not in this array.
* items:
* type: string
* title: $nin
* description: Filter by values not in this array.
* $not:
* oneOf:
* - type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* - type: object
* description: Filter by values not matching the conditions in this parameter.
* - type: array
* description: Filter by values not matching the conditions in this parameter.
* items:
* type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* $gt:
* type: string
* title: $gt
* description: Filter by values greater than this parameter. Useful for numbers and dates only.
* $gte:
* type: string
* title: $gte
* description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only.
* $lt:
* type: string
* title: $lt
* description: Filter by values less than this parameter. Useful for numbers and dates only.
* $lte:
* type: string
* title: $lte
* description: Filter by values less than or equal to this parameter. Useful for numbers and dates only.
* $like:
* type: string
* title: $like
* description: Apply a `like` filter. Useful for strings only.
* $re:
* type: string
* title: $re
* description: Apply a regex filter. Useful for strings only.
* $ilike:
* type: string
* title: $ilike
* description: Apply a case-insensitive `like` filter. Useful for strings only.
* $fulltext:
* type: string
* title: $fulltext
* description: Filter to apply on full-text properties.
* $overlap:
* type: array
* description: Filter arrays that have overlapping values with this parameter.
* items:
* type: string
* title: $overlap
* description: Filter arrays that have overlapping values with this parameter.
* $contains:
* type: array
* description: Filter arrays that contain some of the values of this parameter.
* items:
* type: string
* title: $contains
* description: Filter arrays that contain some of the values of this parameter.
* $contained:
* type: array
* description: Filter arrays that contain all values of this parameter.
* items:
* type: string
* title: $contained
* description: Filter arrays that contain all values of this parameter.
* $exists:
* type: boolean
* title: $exists
* description: Filter by whether a value for this parameter exists (not `null`).
* - type: array
* description: Filter by values not matching the conditions in this parameter.
* items:
* type: string
* title: $not
* description: Filter by values not matching the conditions in this parameter.
* $gt:
* type: string
* title: $gt
* description: Filter by values greater than this parameter. Useful for numbers and dates only.
* $gte:
* type: string
* title: $gte
* description: Filter by values greater than or equal to this parameter. Useful for numbers and dates only.
* $lt:
* type: string
* title: $lt
* description: Filter by values less than this parameter. Useful for numbers and dates only.
* $lte:
* type: string
* title: $lte
* description: Filter by values less than or equal to this parameter. Useful for numbers and dates only.
* $like:
* type: string
* title: $like
* description: Apply a `like` filter. Useful for strings only.
* $re:
* type: string
* title: $re
* description: Apply a regex filter. Useful for strings only.
* $ilike:
* type: string
* title: $ilike
* description: Apply a case-insensitive `like` filter. Useful for strings only.
* $fulltext:
* type: string
* title: $fulltext
* description: Filter to apply on full-text properties.
* $overlap:
* type: array
* description: Filter arrays that have overlapping values with this parameter.
* items:
* type: string
* title: $overlap
* description: Filter arrays that have overlapping values with this parameter.
* $contains:
* type: array
* description: Filter arrays that contain some of the values of this parameter.
* items:
* type: string
* title: $contains
* description: Filter arrays that contain some of the values of this parameter.
* $contained:
* type: array
* description: Filter arrays that contain all values of this parameter.
* items:
* type: string
* title: $contained
* description: Filter arrays that contain all values of this parameter.
* $exists:
* type: boolean
* title: $exists
* description: Filter by whether a value for this parameter exists (not `null`).
* limit:
* type: number
* title: limit
* description: The product's limit.
* offset:
* type: number
* title: offset
* description: The product's offset.
* order:
* type: string
* title: order
* description: The product's order.
* fields:
* type: string
* title: fields
* description: The product's fields.
* $and:
* type: array
* description: Join query parameters with an AND condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $and
* $or:
* type: array
* description: Join query parameters with an OR condition. Each object's content is the same type as the expected query parameters.
* items:
* type: object
* title: $or
*
*/

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminProductVariantResponse
* type: object
* description: SUMMARY
* description: The product variant's details.
* x-schemaName: AdminProductVariantResponse
* required:
* - variant

View File

@@ -14,6 +14,7 @@
* type: string
* title: code
* description: The promotion's code.
* example: OFF50
* type:
* type: string
* description: The promotion's type.
@@ -23,7 +24,7 @@
* is_automatic:
* type: boolean
* title: is_automatic
* description: The promotion's is automatic.
* description: Whether the promotion is applied on a cart automatically if it matches the promotion's rules.
* application_method:
* $ref: "#/components/schemas/BaseApplicationMethod"
* rules:
@@ -34,7 +35,7 @@
* campaign_id:
* type: string
* title: campaign_id
* description: The promotion's campaign id.
* description: The ID of the campaign this promotion belongs to.
* campaign:
* $ref: "#/components/schemas/AdminCampaign"
*

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminPromotionResponse
* type: object
* description: SUMMARY
* description: The promotion's details.
* x-schemaName: AdminPromotionResponse
* required:
* - promotion

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminPromotionRule
* type: object
* description: The updated's details.
* description: The promotion rule's details.
* x-schemaName: AdminPromotionRule
* required:
* - id
@@ -10,15 +10,16 @@
* id:
* type: string
* title: id
* description: The updated's ID.
* description: The promotion rule's ID.
* description:
* type: string
* title: description
* description: The updated's description.
* description: The promotion rule's description.
* attribute:
* type: string
* title: attribute
* description: The updated's attribute.
* description: The promotion rule's attribute.
* example: customer_group_id
* operator:
* type: string
* description: The updated's operator.
@@ -33,6 +34,8 @@
* values:
* type: array
* description: The updated's values.
* example:
* - "cusgroup_123"
* items:
* $ref: "#/components/schemas/BasePromotionRuleValue"
*

View File

@@ -24,17 +24,17 @@
* description: The refund reason's description.
* metadata:
* type: object
* description: The refund reason's metadata.
* description: The refund reason's metadata, can hold custom key-value pairs.
* created_at:
* type: string
* format: date-time
* title: created_at
* description: The refund reason's created at.
* description: The date the refund reason was created.
* updated_at:
* type: string
* format: date-time
* title: updated_at
* description: The refund reason's updated at.
* description: The date the refund reason was updated.
*
*/

View File

@@ -20,15 +20,16 @@
* type: string
* title: currency_code
* description: The region's currency code.
* example: usd
* automatic_taxes:
* type: boolean
* title: automatic_taxes
* description: The region's automatic taxes.
* description: Whether taxes are applied automatically during checkout.
* countries:
* type: array
* description: The region's countries.
* items:
* $ref: "#/components/schemas/BaseRegionCountry"
* $ref: "#/components/schemas/AdminRegionCountry"
* payment_providers:
* type: array
* description: The region's payment providers.
@@ -36,17 +37,17 @@
* $ref: "#/components/schemas/AdminPaymentProvider"
* metadata:
* type: object
* description: The region's metadata.
* description: The region's metadata, can hold custom key-value pairs.
* created_at:
* type: string
* format: date-time
* title: created_at
* description: The region's created at.
* description: The date the region was created.
* updated_at:
* type: string
* format: date-time
* title: updated_at
* description: The region's updated at.
* description: The date the region was updated.
*
*/

View File

@@ -1,8 +1,38 @@
/**
* @schema AdminRegionCountry
* type: object
* description: The billing address's country.
* description: The country's details.
* x-schemaName: AdminRegionCountry
* required:
* - id
* properties:
* id:
* type: string
* title: id
* description: The country's ID.
* iso_2:
* type: string
* title: iso_2
* description: The country's iso 2.
* example: us
* iso_3:
* type: string
* title: iso_3
* description: The country's iso 3.
* example: usa
* num_code:
* type: string
* title: num_code
* description: The country's num code.
* example: 840
* name:
* type: string
* title: name
* description: The country's name.
* display_name:
* type: string
* title: display_name
* description: The country's display name.
*
*/

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminRegionResponse
* type: object
* description: SUMMARY
* description: The region's details.
* x-schemaName: AdminRegionResponse
* required:
* - region

View File

@@ -20,11 +20,11 @@
* line_item_id:
* type: string
* title: line_item_id
* description: The reservation's line item id.
* description: The ID of the line item this reservation is for.
* location_id:
* type: string
* title: location_id
* description: The reservation's location id.
* description: The ID of the location the quantity is reserved from.
* quantity:
* type: number
* title: quantity
@@ -32,7 +32,7 @@
* external_id:
* type: string
* title: external_id
* description: The reservation's external id.
* description: An ID in an external system
* description:
* type: string
* title: description
@@ -40,32 +40,32 @@
* inventory_item_id:
* type: string
* title: inventory_item_id
* description: The reservation's inventory item id.
* description: The ID of the inventory item this reservation is associated with.
* inventory_item:
* type: object
* description: The reservation's inventory item.
* description: The associated inventory item.
* metadata:
* type: object
* description: The reservation's metadata.
* description: The reservation's metadata, can hold custom key-value pairs.
* created_by:
* type: string
* title: created_by
* description: The reservation's created by.
* description: The ID of the user that created this reservation.
* deleted_at:
* type: string
* format: date-time
* title: deleted_at
* description: The reservation's deleted at.
* description: The date this reservation was deleted.
* created_at:
* type: string
* format: date-time
* title: created_at
* description: The reservation's created at.
* description: The date this reservation was created.
* updated_at:
* type: string
* format: date-time
* title: updated_at
* description: The reservation's updated at.
* description: The date this reservation was updated.
*
*/

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminReservationResponse
* type: object
* description: SUMMARY
* description: The reservation's details.
* x-schemaName: AdminReservationResponse
* required:
* - reservation

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminReturn
* type: object
* description: The exchange's return.
* description: The return's details.
* x-schemaName: AdminReturn
* required:
* - id
@@ -20,7 +20,7 @@
* order_id:
* type: string
* title: order_id
* description: The return's order id.
* description: The ID of the order this return is created for.
* status:
* type: string
* title: status
@@ -28,19 +28,19 @@
* exchange_id:
* type: string
* title: exchange_id
* description: The return's exchange id.
* description: The ID of the exchange that this return belongs to.
* location_id:
* type: string
* title: location_id
* description: The return's location id.
* description: The ID of the location the items are returned to.
* claim_id:
* type: string
* title: claim_id
* description: The return's claim id.
* description: The ID of the claim that this return belongs to.
* order_version:
* type: number
* title: order_version
* description: The return's order version.
* description: The version of the order once the return is applied.
* display_id:
* type: number
* title: display_id
@@ -48,11 +48,11 @@
* no_notification:
* type: boolean
* title: no_notification
* description: The return's no notification.
* description: Whether the customer should receive notifications about the return's updates.
* refund_amount:
* type: number
* title: refund_amount
* description: The return's refund amount.
* description: The amount to refund as a result of the return.
* items:
* type: array
* description: The return's items.
@@ -61,16 +61,16 @@
* received_at:
* type: string
* title: received_at
* description: The return's received at.
* description: The date the return was received.
* created_at:
* type: string
* format: date-time
* title: created_at
* description: The return's created at.
* description: The date the return was created.
* canceled_at:
* type: string
* title: canceled_at
* description: The return's canceled at.
* description: The date the return was canceled.
*
*/

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminReturnItem
* type: object
* description: The return item's return items.
* description: The return item's details.
* x-schemaName: AdminReturnItem
* required:
* - id
@@ -22,30 +22,30 @@
* received_quantity:
* type: number
* title: received_quantity
* description: The return item's received quantity.
* description: The received quantity of the item. This quantity is added to the stocked inventory quantity of the item.
* damaged_quantity:
* type: number
* title: damaged_quantity
* description: The return item's damaged quantity.
* description: The received damaged quantity of the item, which isn't added to the stocked inventory quantity of the item.
* reason_id:
* type: string
* title: reason_id
* description: The return item's reason id.
* description: The ID of the return reason associated with the item.
* note:
* type: string
* title: note
* description: The return item's note.
* description: A note about why the item was returned.
* item_id:
* type: string
* title: item_id
* description: The return item's item id.
* description: The ID of the associated order item.
* return_id:
* type: string
* title: return_id
* description: The return item's return id.
* description: The ID of the return this return item belongs to.
* metadata:
* type: object
* description: The return item's metadata.
* description: The return item's metadata, can hold custom key-value pairs.
*
*/

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminReturnPreviewResponse
* type: object
* description: SUMMARY
* description: The details of a return and a preview of the order once the return is applied.
* x-schemaName: AdminReturnPreviewResponse
* required:
* - order_preview

View File

@@ -28,17 +28,17 @@
* description: The return reason's description.
* metadata:
* type: object
* description: The return reason's metadata.
* description: The return reason's metadata, can hold custom key-value pairs.
* created_at:
* type: string
* format: date-time
* title: created_at
* description: The return reason's created at.
* description: The date the return reason was created.
* updated_at:
* type: string
* format: date-time
* title: updated_at
* description: The return reason's updated at.
* description: The date the return reason was updated.
*
*/

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminReturnReasonDeleteResponse
* type: object
* description: SUMMARY
* description: The details of the return reason deletion.
* x-schemaName: AdminReturnReasonDeleteResponse
* required:
* - id
@@ -20,7 +20,7 @@
* deleted:
* type: boolean
* title: deleted
* description: Whether the Return Reason was deleted.
* description: Whether the return reason was deleted.
*
*/

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminReturnReasonListResponse
* type: object
* description: SUMMARY
* description: The paginated list of return reasons.
* x-schemaName: AdminReturnReasonListResponse
* required:
* - limit
@@ -12,18 +12,18 @@
* limit:
* type: number
* title: limit
* description: The return reason's limit.
* description: The maximum number of items returned.
* offset:
* type: number
* title: offset
* description: The return reason's offset.
* description: The number of items skipped before retrieving the returned items.
* count:
* type: number
* title: count
* description: The return reason's count.
* description: The total number of items.
* return_reasons:
* type: array
* description: The return reason's return reasons.
* description: The list of return reasons.
* items:
* $ref: "#/components/schemas/AdminReturnReason"
*

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminReturnReasonResponse
* type: object
* description: SUMMARY
* description: The return reason's details.
* x-schemaName: AdminReturnReasonResponse
* required:
* - return_reason

View File

@@ -1,7 +1,7 @@
/**
* @schema AdminReturnResponse
* type: object
* description: SUMMARY
* description: The return's details.
* x-schemaName: AdminReturnResponse
* required:
* - return

View File

@@ -1,13 +1,13 @@
/**
* @schema AdminRevokeApiKey
* type: object
* description: SUMMARY
* description: The details of revoking the API key.
* x-schemaName: AdminRevokeApiKey
* properties:
* revoke_in:
* type: number
* title: revoke_in
* description: The api key's revoke in.
* description: The time in seconds to revoke the API key after. If not set, the API key is revoked immediately.
*
*/