chore(docs): Updated API Reference (v2) (#9437)

Automated changes by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

Co-authored-by: Shahed Nasser <27354907+shahednasser@users.noreply.github.com>
This commit is contained in:
github-actions[bot]
2024-10-03 07:48:54 +00:00
committed by GitHub
co-authored by Shahed Nasser
parent 97c193be1b
commit 21badd069d
894 changed files with 35649 additions and 28168 deletions
@@ -60,7 +60,7 @@
* $ref: "#/components/responses/invalid_request_error"
* "500":
* $ref: "#/components/responses/500_error"
* x-workflow: deleteCustomersWorkflow
* x-workflow: removeCustomerAccountWorkflow
*
*/
@@ -21,26 +21,6 @@
* required: true
* schema:
* type: string
* - name: expand
* in: query
* description: Comma-separated relations that should be expanded in the returned data.
* required: false
* schema:
* type: string
* title: expand
* description: Comma-separated relations that should be expanded in the returned data.
* - name: fields
* in: query
* description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default
* fields. without prefix it will replace the entire default fields.
* required: false
* schema:
* type: string
* title: fields
* description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default
* fields. without prefix it will replace the entire default fields.
* externalDocs:
* url: "#select-fields-and-relations"
* security:
* - api_token: []
* - cookie_auth: []
@@ -36,7 +36,7 @@
* $ref: "#/components/responses/invalid_request_error"
* "500":
* $ref: "#/components/responses/500_error"
* x-workflow: deleteUsersWorkflow
* x-workflow: removeUserAccountWorkflow
*
*/
@@ -3,12 +3,10 @@
* operationId: GetPromotionsIdRule_type
* summary: List Rules of a Promotion
* x-sidebar-summary: List Rules
* description: >
* description: |
* Retrieve a list of rules in a promotion. The type of rules retrieved depend on the value of the `rule_type` path parameter:
*
* - If `rule_type` is `rules`, the promotion's rules are retrivied. - If `rule_type` is `target-rules`, the target rules of the promotion's application method are retrieved.
*
*
* - If `rule_type` is `buy-rules`, the buy rules of the promotion's application method are retrieved.
* x-authenticated: true
* parameters:
@@ -0,0 +1,69 @@
/**
* @oas [get] /admin/shipping-options/{id}
* operationId: GetShippingOptionsId
* summary: Get a Shipping Option
* description: Retrieve a shipping option by its ID. You can expand the shipping option's relations or select the fields that should be returned.
* x-authenticated: true
* parameters:
* - name: id
* in: path
* description: The shipping option's ID.
* required: true
* schema:
* type: string
* - name: expand
* in: query
* description: Comma-separated relations that should be expanded in the returned data.
* required: false
* schema:
* type: string
* title: expand
* description: Comma-separated relations that should be expanded in the returned data.
* - name: fields
* in: query
* description: |-
* Comma-separated fields that should be included in the returned data.
* * if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default fields.
* * without prefix it will replace the entire default fields.
* required: false
* schema:
* type: string
* title: fields
* description: Comma-separated fields that should be included in the returned data. if a field is prefixed with `+` it will be added to the default fields, using `-` will remove it from the default
* fields. without prefix it will replace the entire default fields.
* externalDocs:
* url: "#select-fields-and-relations"
* security:
* - api_token: []
* - cookie_auth: []
* - jwt_token: []
* x-codeSamples:
* - lang: Shell
* label: cURL
* source: |-
* curl '{backend_url}/admin/shipping-options/{id}' \
* -H 'Authorization: Bearer {access_token}'
* tags:
* - Shipping Options
* responses:
* "200":
* description: OK
* content:
* application/json:
* schema:
* $ref: "#/components/schemas/AdminShippingOptionResponse"
* "400":
* $ref: "#/components/responses/400_error"
* "401":
* $ref: "#/components/responses/unauthorized"
* "404":
* $ref: "#/components/responses/not_found_error"
* "409":
* $ref: "#/components/responses/invalid_state_error"
* "422":
* $ref: "#/components/responses/invalid_request_error"
* "500":
* $ref: "#/components/responses/500_error"
*
*/
@@ -63,10 +63,6 @@
* $ref: "#/components/responses/invalid_request_error"
* "500":
* $ref: "#/components/responses/500_error"
* requestBody:
* content:
* application/json:
* schema: {}
* x-workflow: confirmClaimRequestWorkflow
*
*/
@@ -63,10 +63,6 @@
* "500":
* $ref: "#/components/responses/500_error"
* x-workflow: confirmExchangeRequestWorkflow
* requestBody:
* content:
* application/json:
* schema: {}
*
*/
@@ -56,10 +56,6 @@
* $ref: "#/components/responses/invalid_request_error"
* "500":
* $ref: "#/components/responses/500_error"
* requestBody:
* content:
* application/json:
* schema: {}
* x-workflow: refreshInviteTokensWorkflow
*
*/
@@ -62,10 +62,6 @@
* $ref: "#/components/responses/invalid_request_error"
* "500":
* $ref: "#/components/responses/500_error"
* requestBody:
* content:
* application/json:
* schema: {}
*
*/
@@ -35,11 +35,6 @@
* - api_token: []
* - cookie_auth: []
* - jwt_token: []
* requestBody:
* content:
* application/json:
* schema:
* $ref: "#/components/schemas/AdminArchiveOrder"
* x-codeSamples:
* - lang: Shell
* label: cURL
@@ -70,10 +70,6 @@
* $ref: "#/components/responses/invalid_request_error"
* "500":
* $ref: "#/components/responses/500_error"
* requestBody:
* content:
* application/json:
* schema: {}
* x-workflow: cancelOrderWorkflow
*
*/
@@ -42,11 +42,6 @@
* - api_token: []
* - cookie_auth: []
* - jwt_token: []
* requestBody:
* content:
* application/json:
* schema:
* $ref: "#/components/schemas/AdminMarkOrderFulfillmentDelivered"
* x-codeSamples:
* - lang: Shell
* label: cURL
@@ -31,8 +31,8 @@
* description: A price's details.
* required:
* - currency_code
* - amount
* - variant_id
* - amount
* properties:
* currency_code:
* type: string
@@ -33,7 +33,7 @@
* content:
* application/json:
* schema:
* $ref: "#/components/schemas/AdminCreateProduct"
* $ref: "#/components/schemas/AdminCreateProductType"
* x-codeSamples:
* - lang: Shell
* label: cURL
@@ -30,9 +30,9 @@
* type: object
* description: The associations to create between a product variant and an inventory item.
* required:
* - required_quantity
* - inventory_item_id
* - variant_id
* - inventory_item_id
* - required_quantity
* properties:
* required_quantity:
* type: number
@@ -53,9 +53,9 @@
* type: object
* description: Update a product variant's association with an inventory item.
* required:
* - required_quantity
* - inventory_item_id
* - variant_id
* - inventory_item_id
* - required_quantity
* properties:
* required_quantity:
* type: number
@@ -76,8 +76,8 @@
* type: object
* description: Delete a product variant's association with an inventory item.
* required:
* - inventory_item_id
* - variant_id
* - inventory_item_id
* properties:
* inventory_item_id:
* type: string
@@ -47,93 +47,12 @@
* type: array
* description: The buy rules to create.
* items:
* type: object
* description: A buy rule's details.
* required:
* - operator
* - attribute
* - values
* properties:
* operator:
* type: string
* description: The operator used to check whether the buy rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value.
* enum:
* - gte
* - lte
* - gt
* - lt
* - eq
* - ne
* - in
* description:
* type: string
* title: description
* description: The buy rule's description.
* attribute:
* type: string
* title: attribute
* description: The attribute to compare against when checking whether a promotion can be applied on a cart.
* example: items.product.id
* values:
* oneOf:
* - type: string
* title: values
* description: The attribute's value.
* example: prod_123
* - type: array
* description: The allowed attribute values.
* items:
* type: string
* title: values
* description: An attribute value.
* example: prod_123
* $ref: "#/components/schemas/AdminCreatePromotionRule"
* update:
* type: array
* description: The buy rules to update.
* items:
* type: object
* description: The properties to update in a buy rule.
* required:
* - id
* - values
* properties:
* id:
* type: string
* title: id
* description: The buy rule's ID.
* operator:
* type: string
* description: The operator used to check whether the buy rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value.
* enum:
* - gte
* - lte
* - gt
* - lt
* - eq
* - ne
* - in
* description:
* type: string
* title: description
* description: The buy rule's description.
* attribute:
* type: string
* title: attribute
* description: The attribute to compare against when checking whether a promotion can be applied on a cart.
* example: items.product.id
* values:
* oneOf:
* - type: string
* title: values
* description: The attribute's value.
* example: prod_123
* - type: array
* description: The allowed attribute values.
* items:
* type: string
* title: values
* description: An attribute value.
* example: prod_123
* $ref: "#/components/schemas/AdminUpdatePromotionRule"
* delete:
* type: array
* description: The buy rules to delete.
@@ -47,93 +47,12 @@
* type: array
* description: The rules to create.
* items:
* type: object
* description: A rule's details.
* required:
* - operator
* - attribute
* - values
* properties:
* operator:
* type: string
* description: The operator used to check whether the rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value.
* enum:
* - gte
* - lte
* - gt
* - lt
* - eq
* - ne
* - in
* description:
* type: string
* title: description
* description: The rule's description.
* attribute:
* type: string
* title: attribute
* description: The attribute to compare against when checking whether a promotion can be applied on a cart.
* example: items.product.id
* values:
* oneOf:
* - type: string
* title: values
* description: The attribute's value.
* example: prod_123
* - type: array
* description: The allowed attribute values.
* items:
* type: string
* title: values
* description: An attribute value.
* example: prod_123
* $ref: "#/components/schemas/AdminCreatePromotionRule"
* update:
* type: array
* description: The rules to update.
* items:
* type: object
* description: The properties to update in a rule.
* required:
* - id
* - values
* properties:
* id:
* type: string
* title: id
* description: The rule's ID.
* operator:
* type: string
* description: The operator used to check whether the rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value.
* enum:
* - gte
* - lte
* - gt
* - lt
* - eq
* - ne
* - in
* description:
* type: string
* title: description
* description: The rule's description.
* attribute:
* type: string
* title: attribute
* description: The attribute to compare against when checking whether a promotion can be applied on a cart.
* example: items.product.id
* values:
* oneOf:
* - type: string
* title: values
* description: The attribute's value.
* example: prod_123
* - type: array
* description: The allowed attribute values.
* items:
* type: string
* title: values
* description: An attribute value.
* example: prod_123
* $ref: "#/components/schemas/AdminUpdatePromotionRule"
* delete:
* type: array
* description: The rules to delete.
@@ -47,93 +47,12 @@
* type: array
* description: The target rules to create.
* items:
* type: object
* description: A target rule's details.
* required:
* - operator
* - attribute
* - values
* properties:
* operator:
* type: string
* description: The operator used to check whether the target rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value.
* enum:
* - gte
* - lte
* - gt
* - lt
* - eq
* - ne
* - in
* description:
* type: string
* title: description
* description: The target rule's description.
* attribute:
* type: string
* title: attribute
* description: The attribute to compare against when checking whether a promotion can be applied on a cart.
* example: items.product.id
* values:
* oneOf:
* - type: string
* title: values
* description: The attribute's value.
* example: prod_123
* - type: array
* description: The allowed attribute values.
* items:
* type: string
* title: values
* description: An attribute value.
* example: prod_123
* $ref: "#/components/schemas/AdminCreatePromotionRule"
* update:
* type: array
* description: The target rules to update.
* items:
* type: object
* description: The properties to update in a target rule.
* required:
* - id
* - values
* properties:
* id:
* type: string
* title: id
* description: The target rule's ID.
* operator:
* type: string
* description: The operator used to check whether the target rule applies on a cart. For example, `eq` means that the cart's value for the specified attribute must match the specified value.
* enum:
* - gte
* - lte
* - gt
* - lt
* - eq
* - ne
* - in
* description:
* type: string
* title: description
* description: The target rule's description.
* attribute:
* type: string
* title: attribute
* description: The attribute to compare against when checking whether a promotion can be applied on a cart.
* example: items.product.id
* values:
* oneOf:
* - type: string
* title: values
* description: The attribute's value.
* example: prod_123
* - type: array
* description: The allowed attribute values.
* items:
* type: string
* title: values
* description: An attribute value.
* example: prod_123
* $ref: "#/components/schemas/AdminUpdatePromotionRule"
* delete:
* type: array
* description: The target rules to delete.
@@ -33,7 +33,7 @@
* content:
* application/json:
* schema:
* $ref: "#/components/schemas/CreateOrderReturnReason"
* $ref: "#/components/schemas/AdminCreateReturnReason"
* x-codeSamples:
* - lang: Shell
* label: cURL
@@ -39,7 +39,7 @@
* content:
* application/json:
* schema:
* $ref: "#/components/schemas/UpdateOrderReturnReason"
* $ref: "#/components/schemas/AdminUpdateReturnReason"
* x-codeSamples:
* - lang: Shell
* label: cURL
@@ -71,9 +71,9 @@
* type: object
* description: The shipping option's type.
* required:
* - label
* - description
* - code
* - description
* - label
* properties:
* label:
* type: string
@@ -47,89 +47,12 @@
* type: array
* description: The shipping option rules to create.
* items:
* type: object
* description: A shipping option's details.
* required:
* - operator
* - attribute
* - value
* properties:
* operator:
* type: string
* description: The operator used to check whether a rule applies.
* enum:
* - in
* - eq
* - ne
* - gt
* - gte
* - lt
* - lte
* - nin
* attribute:
* type: string
* title: attribute
* description: The name of a property or table that the rule applies to.
* example: customer_group
* value:
* oneOf:
* - type: string
* title: value
* description: A value of the attribute that enables this rule.
* example: cusgroup_123
* - type: array
* description: Values of the attribute that enable this rule.
* items:
* type: string
* title: value
* description: A value of the attribute that enables this rule.
* example: cusgroup_123
* $ref: "#/components/schemas/AdminCreateShippingOptionRule"
* update:
* type: array
* description: The shipping option rules to update.
* items:
* type: object
* description: The properties to update in the shipping option rule.
* required:
* - id
* - operator
* - attribute
* - value
* properties:
* id:
* type: string
* title: id
* description: The rule's ID.
* operator:
* type: string
* description: The operator used to check whether a rule applies.
* enum:
* - in
* - eq
* - ne
* - gt
* - gte
* - lt
* - lte
* - nin
* attribute:
* type: string
* title: attribute
* description: The name of a property or table that the rule applies to.
* example: customer_group
* value:
* oneOf:
* - type: string
* title: value
* description: A value of the attribute that enables this rule.
* example: cusgroup_123
* - type: array
* description: Values of the attribute that enable this rule.
* items:
* type: string
* title: value
* description: A value of the attribute that enables this rule.
* example: cusgroup_123
* $ref: "#/components/schemas/AdminUpdateShippingOptionRule"
* delete:
* type: array
* description: The shipping option rules to delete.
@@ -43,8 +43,8 @@
* type: object
* description: The fulfillment set to create.
* required:
* - name
* - type
* - name
* properties:
* name:
* type: string