docs: generate API reference for 2.12.0 (#14185)
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
import Medusa from "@medusajs/js-sdk"
|
||||
|
||||
export const sdk = new Medusa({
|
||||
baseUrl: import.meta.env.VITE_BACKEND_URL || "/",
|
||||
debug: import.meta.env.DEV,
|
||||
auth: {
|
||||
type: "session",
|
||||
},
|
||||
})
|
||||
|
||||
sdk.admin.order.updateOrderChange(
|
||||
"ordch_123",
|
||||
{
|
||||
carry_over_promotions: true
|
||||
}
|
||||
)
|
||||
.then(({ order_change }) => {
|
||||
console.log(order_change)
|
||||
})
|
||||
@@ -1,2 +1,6 @@
|
||||
curl -X POST '{backend_url}/admin/draft-orders/{id}' \
|
||||
-H 'Authorization: Bearer {jwt_token}'
|
||||
-H 'Authorization: Bearer {jwt_token}' \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"email": "test@test.com"
|
||||
}'
|
||||
@@ -0,0 +1,6 @@
|
||||
curl -X POST '{backend_url}/admin/order-changes/{id}' \
|
||||
-H 'Authorization: Bearer {access_token}' \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"carry_over_promotions": true
|
||||
}'
|
||||
Reference in New Issue
Block a user