docs: added dividers + see also section (#2899)

This commit is contained in:
Shahed Nasser
2022-12-26 15:52:08 +02:00
committed by GitHub
parent b0e5769e27
commit b0ebfd6bcf
100 changed files with 1047 additions and 291 deletions
@@ -29,6 +29,8 @@ You can use Medusas Admin APIs to achieve more functionalities as well. Check
:::
---
# Prerequisites
### Medusa Components
@@ -47,6 +49,8 @@ You must be an authenticated admin user before following along with the steps in
You can learn more about [authenticating as an admin user in the API reference](/api/admin/#section/Authentication).
---
## Create a Discount
You can create a discount by sending a request to the [Create Discount](/api/admin/#tag/Discount/operation/PostDiscounts) endpoint:
@@ -135,6 +139,8 @@ This request accepts [many request-body parameters](/api/admin/#tag/Discount/ope
This request returns the full `discount` object.
---
## Update Discount
You can update any of the discounts information, configurations, and conditions by sending a request to the [Update Discount](/api/admin/#tag/Discount/operation/PostDiscountsDiscount) endpoint.
@@ -197,6 +203,8 @@ You can check the [API reference](/api/admin/#tag/Discount/operation/PostDiscoun
This updates the discounts information and returns the full updated `discount` object in the response.
---
## Manage Conditions
### Create a Condition
@@ -441,6 +449,8 @@ This request accepts as a path parameter the discount ID and the condition ID.
It returns the `discount` object in the response.
---
## Delete Discount
You can delete a discount by sending a request to the [Delete Discount](/api/admin/#tag/Discount/operation/DeleteDiscountsDiscount) endpoint:
@@ -488,7 +498,9 @@ It returns in the response the following fields:
- `object`: A string indicating the type of object deleted. By default, its value is `discount`.
- `deleted`: A boolean value indicating whether the discount was deleted or not.
## Whats Next
---
- Check out more [Admin Discount APIs in the API reference](/api/admin/#tag/Discount).
- Learn how you can [use Discounts on the storefront](../storefront/use-discounts-in-checkout.mdx).
## See Also
- [Discounts API reference](/api/admin/#tag/Discount)
- [Use Discounts on the storefront](../storefront/use-discounts-in-checkout.mdx)