@mercurjs/docs 2.2.0-canary.40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +24 -0
- package/content/blocks.mdx +209 -0
- package/content/learn/architecture.mdx +215 -0
- package/content/learn/attributes.mdx +89 -0
- package/content/learn/blocks.mdx +99 -0
- package/content/learn/commissions.mdx +175 -0
- package/content/learn/concepts.mdx +84 -0
- package/content/learn/installation.mdx +117 -0
- package/content/learn/introduction.mdx +71 -0
- package/content/learn/offers.mdx +78 -0
- package/content/learn/order-groups.mdx +114 -0
- package/content/learn/payouts.mdx +175 -0
- package/content/learn/product-requests.mdx +82 -0
- package/content/learn/products.mdx +79 -0
- package/content/learn/registry.mdx +155 -0
- package/content/learn/seller-members.mdx +62 -0
- package/content/learn/sellers.mdx +118 -0
- package/content/migration/from-1-x-to-2-0.mdx +152 -0
- package/content/migration/from-2-0-to-2-1.mdx +105 -0
- package/content/migration/overview.mdx +58 -0
- package/content/references/api/admin/commission-rates/batch-commission-rules.mdx +70 -0
- package/content/references/api/admin/commission-rates/create-commission-rate.mdx +95 -0
- package/content/references/api/admin/commission-rates/delete-commission-rate.mdx +40 -0
- package/content/references/api/admin/commission-rates/list-commission-rates.mdx +92 -0
- package/content/references/api/admin/commission-rates/retrieve-commission-rate.mdx +70 -0
- package/content/references/api/admin/commission-rates/update-commission-rate.mdx +84 -0
- package/content/references/api/admin/members/list-members.mdx +61 -0
- package/content/references/api/admin/offers/batch-create-offers.mdx +130 -0
- package/content/references/api/admin/offers/delete-offer.mdx +40 -0
- package/content/references/api/admin/offers/list-offers.mdx +106 -0
- package/content/references/api/admin/offers/retrieve-offer.mdx +82 -0
- package/content/references/api/admin/order-groups/list-order-groups.mdx +77 -0
- package/content/references/api/admin/order-groups/retrieve-order-group.mdx +56 -0
- package/content/references/api/admin/orders/get-order-commission-lines.mdx +65 -0
- package/content/references/api/admin/orders/get-order-order-group.mdx +56 -0
- package/content/references/api/admin/orders/list-orders.mdx +79 -0
- package/content/references/api/admin/payouts/list-payouts.mdx +75 -0
- package/content/references/api/admin/payouts/retrieve-payout.mdx +62 -0
- package/content/references/api/admin/product-attributes/create-attribute-value.mdx +76 -0
- package/content/references/api/admin/product-attributes/create-product-attribute.mdx +99 -0
- package/content/references/api/admin/product-attributes/delete-attribute-value.mdx +52 -0
- package/content/references/api/admin/product-attributes/delete-product-attribute.mdx +40 -0
- package/content/references/api/admin/product-attributes/list-product-attributes.mdx +91 -0
- package/content/references/api/admin/product-attributes/retrieve-product-attribute.mdx +81 -0
- package/content/references/api/admin/product-attributes/update-attribute-value.mdx +66 -0
- package/content/references/api/admin/product-attributes/update-product-attribute.mdx +76 -0
- package/content/references/api/admin/product-changes/cancel-product-change.mdx +68 -0
- package/content/references/api/admin/product-changes/confirm-product-change.mdx +47 -0
- package/content/references/api/admin/products/batch-product-attributes.mdx +96 -0
- package/content/references/api/admin/products/confirm-product.mdx +59 -0
- package/content/references/api/admin/products/create-product-variant.mdx +78 -0
- package/content/references/api/admin/products/create-product.mdx +169 -0
- package/content/references/api/admin/products/delete-product-variant.mdx +48 -0
- package/content/references/api/admin/products/delete-product.mdx +40 -0
- package/content/references/api/admin/products/list-product-variants.mdx +91 -0
- package/content/references/api/admin/products/list-products.mdx +109 -0
- package/content/references/api/admin/products/preview-product.mdx +78 -0
- package/content/references/api/admin/products/reject-product.mdx +59 -0
- package/content/references/api/admin/products/request-product-changes.mdx +59 -0
- package/content/references/api/admin/products/retrieve-product-variant.mdx +73 -0
- package/content/references/api/admin/products/retrieve-product.mdx +96 -0
- package/content/references/api/admin/products/set-product-sellers.mdx +47 -0
- package/content/references/api/admin/products/update-product-variant.mdx +89 -0
- package/content/references/api/admin/products/update-product.mdx +133 -0
- package/content/references/api/admin/sellers/add-seller-member.mdx +63 -0
- package/content/references/api/admin/sellers/approve-seller.mdx +54 -0
- package/content/references/api/admin/sellers/create-seller.mdx +100 -0
- package/content/references/api/admin/sellers/delete-member-invite.mdx +42 -0
- package/content/references/api/admin/sellers/delete-professional-details.mdx +52 -0
- package/content/references/api/admin/sellers/invite-seller-member.mdx +63 -0
- package/content/references/api/admin/sellers/list-member-invites.mdx +71 -0
- package/content/references/api/admin/sellers/list-seller-members.mdx +71 -0
- package/content/references/api/admin/sellers/list-seller-products.mdx +85 -0
- package/content/references/api/admin/sellers/list-sellers.mdx +96 -0
- package/content/references/api/admin/sellers/remove-seller-member.mdx +42 -0
- package/content/references/api/admin/sellers/resend-member-invite.mdx +55 -0
- package/content/references/api/admin/sellers/retrieve-seller.mdx +81 -0
- package/content/references/api/admin/sellers/suspend-seller.mdx +60 -0
- package/content/references/api/admin/sellers/terminate-seller.mdx +60 -0
- package/content/references/api/admin/sellers/unsuspend-seller.mdx +52 -0
- package/content/references/api/admin/sellers/unterminate-seller.mdx +52 -0
- package/content/references/api/admin/sellers/update-seller.mdx +83 -0
- package/content/references/api/admin/sellers/upsert-payment-details.mdx +88 -0
- package/content/references/api/admin/sellers/upsert-professional-details.mdx +78 -0
- package/content/references/api/admin/sellers/upsert-seller-address.mdx +91 -0
- package/content/references/api/admin.mdx +134 -0
- package/content/references/api/conventions.mdx +109 -0
- package/content/references/api/store/carts/add-line-item.mdx +115 -0
- package/content/references/api/store/carts/add-shipping-methods.mdx +84 -0
- package/content/references/api/store/carts/apply-promotions.mdx +83 -0
- package/content/references/api/store/carts/complete-cart.mdx +98 -0
- package/content/references/api/store/offers/list-offers.mdx +161 -0
- package/content/references/api/store/offers/retrieve-offer.mdx +112 -0
- package/content/references/api/store/order-groups/list-order-groups.mdx +105 -0
- package/content/references/api/store/order-groups/retrieve-order-group.mdx +78 -0
- package/content/references/api/store/product-attributes/list-product-attributes.mdx +134 -0
- package/content/references/api/store/product-attributes/retrieve-product-attribute.mdx +78 -0
- package/content/references/api/store/product-categories/list-product-categories.mdx +126 -0
- package/content/references/api/store/product-categories/retrieve-product-category.mdx +79 -0
- package/content/references/api/store/products/list-products.mdx +184 -0
- package/content/references/api/store/products/retrieve-product.mdx +107 -0
- package/content/references/api/store/search/search.mdx +136 -0
- package/content/references/api/store/sellers/list-sellers.mdx +105 -0
- package/content/references/api/store/sellers/retrieve-seller.mdx +62 -0
- package/content/references/api/store/shipping-options/list-shipping-options.mdx +74 -0
- package/content/references/api/store.mdx +67 -0
- package/content/references/api/vendor/members/accept-member-invite.mdx +65 -0
- package/content/references/api/vendor/members/retrieve-current-member.mdx +51 -0
- package/content/references/api/vendor/members/update-current-member.mdx +70 -0
- package/content/references/api/vendor/offers/batch-create-offers.mdx +123 -0
- package/content/references/api/vendor/offers/batch-offer-inventory-items.mdx +103 -0
- package/content/references/api/vendor/offers/create-offer.mdx +141 -0
- package/content/references/api/vendor/offers/delete-offer.mdx +51 -0
- package/content/references/api/vendor/offers/list-offers.mdx +125 -0
- package/content/references/api/vendor/offers/retrieve-offer.mdx +74 -0
- package/content/references/api/vendor/offers/update-offer.mdx +82 -0
- package/content/references/api/vendor/orders/cancel-fulfillment.mdx +63 -0
- package/content/references/api/vendor/orders/cancel-order.mdx +56 -0
- package/content/references/api/vendor/orders/complete-order.mdx +55 -0
- package/content/references/api/vendor/orders/create-fulfillment.mdx +76 -0
- package/content/references/api/vendor/orders/create-shipment.mdx +99 -0
- package/content/references/api/vendor/orders/get-order-commission-lines.mdx +66 -0
- package/content/references/api/vendor/orders/list-order-changes.mdx +75 -0
- package/content/references/api/vendor/orders/list-orders.mdx +103 -0
- package/content/references/api/vendor/orders/mark-fulfillment-delivered.mdx +62 -0
- package/content/references/api/vendor/orders/preview-order.mdx +65 -0
- package/content/references/api/vendor/orders/retrieve-order.mdx +84 -0
- package/content/references/api/vendor/payout-accounts/create-onboarding.mdx +68 -0
- package/content/references/api/vendor/payout-accounts/create-payout-account.mdx +59 -0
- package/content/references/api/vendor/payout-accounts/retrieve-payout-account-by-id.mdx +60 -0
- package/content/references/api/vendor/payout-accounts/retrieve-payout-account.mdx +77 -0
- package/content/references/api/vendor/payouts/list-payouts.mdx +90 -0
- package/content/references/api/vendor/payouts/retrieve-payout.mdx +63 -0
- package/content/references/api/vendor/product-attributes/list-product-attributes.mdx +135 -0
- package/content/references/api/vendor/product-attributes/retrieve-product-attribute.mdx +71 -0
- package/content/references/api/vendor/product-variants/list-variants.mdx +136 -0
- package/content/references/api/vendor/products/batch-product-attributes.mdx +104 -0
- package/content/references/api/vendor/products/cancel-product-change.mdx +62 -0
- package/content/references/api/vendor/products/create-product-variant.mdx +92 -0
- package/content/references/api/vendor/products/create-product.mdx +197 -0
- package/content/references/api/vendor/products/delete-product-variant.mdx +68 -0
- package/content/references/api/vendor/products/delete-product.mdx +62 -0
- package/content/references/api/vendor/products/list-product-variants.mdx +114 -0
- package/content/references/api/vendor/products/list-products.mdx +163 -0
- package/content/references/api/vendor/products/preview-product.mdx +61 -0
- package/content/references/api/vendor/products/retrieve-product-variant.mdx +76 -0
- package/content/references/api/vendor/products/retrieve-product.mdx +69 -0
- package/content/references/api/vendor/products/update-product-variant.mdx +104 -0
- package/content/references/api/vendor/products/update-product.mdx +148 -0
- package/content/references/api/vendor/sellers/create-seller.mdx +150 -0
- package/content/references/api/vendor/sellers/delete-professional-details.mdx +54 -0
- package/content/references/api/vendor/sellers/invite-seller-member.mdx +67 -0
- package/content/references/api/vendor/sellers/list-member-invites.mdx +82 -0
- package/content/references/api/vendor/sellers/list-seller-members.mdx +80 -0
- package/content/references/api/vendor/sellers/list-sellers.mdx +71 -0
- package/content/references/api/vendor/sellers/remove-seller-member.mdx +48 -0
- package/content/references/api/vendor/sellers/retrieve-current-seller-member.mdx +59 -0
- package/content/references/api/vendor/sellers/retrieve-current-seller.mdx +69 -0
- package/content/references/api/vendor/sellers/select-seller.mdx +44 -0
- package/content/references/api/vendor/sellers/update-current-seller.mdx +108 -0
- package/content/references/api/vendor/sellers/update-member-role.mdx +51 -0
- package/content/references/api/vendor/sellers/upsert-payment-details.mdx +74 -0
- package/content/references/api/vendor/sellers/upsert-professional-details.mdx +70 -0
- package/content/references/api/vendor/sellers/upsert-seller-address.mdx +81 -0
- package/content/references/api/vendor.mdx +150 -0
- package/content/references/configuration.mdx +155 -0
- package/content/references/modules/commission.mdx +106 -0
- package/content/references/modules/custom-fields.mdx +45 -0
- package/content/references/modules/media.mdx +55 -0
- package/content/references/modules/offer.mdx +64 -0
- package/content/references/modules/payout.mdx +121 -0
- package/content/references/modules/product-attribute.mdx +111 -0
- package/content/references/modules/product-edit.mdx +80 -0
- package/content/references/modules/search.mdx +112 -0
- package/content/references/modules/seller.mdx +175 -0
- package/content/references/overview.mdx +70 -0
- package/content/references/workflows/cart/add-seller-shipping-method-to-cart.mdx +44 -0
- package/content/references/workflows/cart/complete-cart-with-split-orders.mdx +36 -0
- package/content/references/workflows/cart/list-seller-shipping-options-for-cart.mdx +39 -0
- package/content/references/workflows/cart/update-cart-seller-promotions.mdx +42 -0
- package/content/references/workflows/commission/batch-commission-rules.mdx +45 -0
- package/content/references/workflows/commission/create-commission-rates.mdx +41 -0
- package/content/references/workflows/commission/delete-commission-rates.mdx +34 -0
- package/content/references/workflows/commission/refresh-order-commission-lines.mdx +30 -0
- package/content/references/workflows/commission/update-commission-rates.mdx +35 -0
- package/content/references/workflows/media/set-category-images.mdx +41 -0
- package/content/references/workflows/media/set-collection-images.mdx +41 -0
- package/content/references/workflows/member/accept-member-invite.mdx +33 -0
- package/content/references/workflows/member/add-seller-member.mdx +30 -0
- package/content/references/workflows/member/create-member-invites.mdx +34 -0
- package/content/references/workflows/member/delete-member-invite.mdx +24 -0
- package/content/references/workflows/member/remove-seller-member.mdx +28 -0
- package/content/references/workflows/member/resend-member-invite.mdx +28 -0
- package/content/references/workflows/member/update-member-role.mdx +28 -0
- package/content/references/workflows/member/update-member.mdx +35 -0
- package/content/references/workflows/offer/batch-offer-inventory-items.mdx +58 -0
- package/content/references/workflows/offer/create-offers.mdx +63 -0
- package/content/references/workflows/offer/delete-offers.mdx +35 -0
- package/content/references/workflows/offer/update-offers.mdx +51 -0
- package/content/references/workflows/order/cancel-order-fulfillment.mdx +34 -0
- package/content/references/workflows/order/confirm-claim-request.mdx +25 -0
- package/content/references/workflows/order/confirm-exchange-request.mdx +25 -0
- package/content/references/workflows/order/confirm-order-edit-request.mdx +25 -0
- package/content/references/workflows/order/confirm-return-receive.mdx +25 -0
- package/content/references/workflows/order/create-order-fulfillment.mdx +45 -0
- package/content/references/workflows/order-group/get-order-group-detail.mdx +29 -0
- package/content/references/workflows/order-group/get-order-groups-list.mdx +36 -0
- package/content/references/workflows/overview.mdx +72 -0
- package/content/references/workflows/payout/create-onboarding.mdx +36 -0
- package/content/references/workflows/payout/create-payout-account.mdx +33 -0
- package/content/references/workflows/payout/create-payout.mdx +30 -0
- package/content/references/workflows/payout/process-payout-for-webhook.mdx +32 -0
- package/content/references/workflows/product/confirm-products.mdx +46 -0
- package/content/references/workflows/product/create-products.mdx +63 -0
- package/content/references/workflows/product/link-sellers-to-product-category.mdx +40 -0
- package/content/references/workflows/product/link-sellers-to-product.mdx +40 -0
- package/content/references/workflows/product/reject-product.mdx +46 -0
- package/content/references/workflows/product/request-product-change.mdx +46 -0
- package/content/references/workflows/product-attribute/add-product-attributes-to-product.mdx +49 -0
- package/content/references/workflows/product-attribute/create-and-link-product-attributes-to-product.mdx +46 -0
- package/content/references/workflows/product-attribute/create-product-attribute-values.mdx +43 -0
- package/content/references/workflows/product-attribute/create-product-attributes.mdx +56 -0
- package/content/references/workflows/product-attribute/delete-product-attribute-values.mdx +30 -0
- package/content/references/workflows/product-attribute/delete-product-attributes.mdx +30 -0
- package/content/references/workflows/product-attribute/remove-product-attributes-from-product.mdx +29 -0
- package/content/references/workflows/product-attribute/update-product-attribute-values.mdx +44 -0
- package/content/references/workflows/product-attribute/update-product-attributes-on-product.mdx +41 -0
- package/content/references/workflows/product-attribute/update-product-attributes.mdx +48 -0
- package/content/references/workflows/product-attribute/upsert-product-attribute-values.mdx +43 -0
- package/content/references/workflows/product-edit/auto-confirm-product-change.mdx +39 -0
- package/content/references/workflows/product-edit/cancel-product-change.mdx +49 -0
- package/content/references/workflows/product-edit/confirm-product-change.mdx +57 -0
- package/content/references/workflows/product-edit/create-product-change.mdx +72 -0
- package/content/references/workflows/product-edit/reject-product-change.mdx +54 -0
- package/content/references/workflows/product-edit/stage-product-change.mdx +75 -0
- package/content/references/workflows/seller/approve-seller.mdx +34 -0
- package/content/references/workflows/seller/create-seller-account.mdx +59 -0
- package/content/references/workflows/seller/create-seller-defaults.mdx +22 -0
- package/content/references/workflows/seller/create-sellers.mdx +65 -0
- package/content/references/workflows/seller/delete-seller-professional-details.mdx +37 -0
- package/content/references/workflows/seller/delete-sellers.mdx +24 -0
- package/content/references/workflows/seller/invite-seller.mdx +28 -0
- package/content/references/workflows/seller/suspend-seller.mdx +35 -0
- package/content/references/workflows/seller/terminate-seller.mdx +35 -0
- package/content/references/workflows/seller/unsuspend-seller.mdx +34 -0
- package/content/references/workflows/seller/unterminate-seller.mdx +34 -0
- package/content/references/workflows/seller/update-seller-address.mdx +55 -0
- package/content/references/workflows/seller/update-seller-payment-details.mdx +52 -0
- package/content/references/workflows/seller/update-seller-professional-details.mdx +48 -0
- package/content/references/workflows/seller/update-sellers.mdx +57 -0
- package/content/resources/ai/llms.mdx +74 -0
- package/content/resources/ai/mcp.mdx +152 -0
- package/content/resources/ai/overview.mdx +97 -0
- package/content/resources/customization/custom-fields.mdx +182 -0
- package/content/resources/customization/extend-a-workflow.mdx +39 -0
- package/content/resources/customization/extending-panels.mdx +309 -0
- package/content/resources/deployment/medusa-cloud.mdx +167 -0
- package/content/resources/integrations/notifications.mdx +39 -0
- package/content/resources/integrations/search.mdx +122 -0
- package/content/resources/integrations/stripe-connect.mdx +395 -0
- package/content/resources/tutorials/add-a-block.mdx +74 -0
- package/content/resources/tutorials/attributes-and-variant-axes.mdx +111 -0
- package/content/resources/tutorials/build-a-block.mdx +134 -0
- package/content/resources/tutorials/configure-commissions.mdx +127 -0
- package/content/resources/tutorials/custom-api-route.mdx +142 -0
- package/content/resources/tutorials/custom-panel-page.mdx +78 -0
- package/content/resources/tutorials/first-marketplace.mdx +45 -0
- package/content/resources/tutorials/handle-product-requests.mdx +80 -0
- package/content/resources/tutorials/import-export-products.mdx +96 -0
- package/content/resources/tutorials/master-products-and-offers.mdx +89 -0
- package/content/resources/tutorials/recompose-a-page.mdx +129 -0
- package/content/resources/tutorials/replace-panel-components.mdx +116 -0
- package/content/resources/tutorials/seller-payouts-stripe.mdx +89 -0
- package/content/telemetry.mdx +67 -0
- package/content/tools/api-client.mdx +155 -0
- package/content/tools/cli.mdx +196 -0
- package/content/tools/dashboard-sdk.mdx +35 -0
- package/content/user-guide/admin/overview.mdx +23 -0
- package/content/user-guide/admin/stores.mdx +193 -0
- package/content/user-guide/vendor/overview.mdx +23 -0
- package/content/user-guide/vendor/stores.mdx +209 -0
- package/llms.txt +307 -0
- package/package.json +33 -0
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Retrieve Commission Rate"
|
|
3
|
+
api: "GET /admin/commission-rates/{id}"
|
|
4
|
+
description: "Retrieve a commission rate by ID."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Returns a single commission rate with its rules and per-currency values.
|
|
8
|
+
|
|
9
|
+
## Path parameters
|
|
10
|
+
|
|
11
|
+
<ParamField path="id" type="string" required>The commission rate's ID.</ParamField>
|
|
12
|
+
|
|
13
|
+
## Query parameters
|
|
14
|
+
|
|
15
|
+
<ParamField query="fields" type="string">Comma-separated fields to include in the response.</ParamField>
|
|
16
|
+
|
|
17
|
+
## Response
|
|
18
|
+
|
|
19
|
+
<ResponseField name="commission_rate" type="object">
|
|
20
|
+
<Expandable title="properties">
|
|
21
|
+
<ResponseField name="id" type="string">The commission rate's ID.</ResponseField>
|
|
22
|
+
<ResponseField name="name" type="string">The rate's display name.</ResponseField>
|
|
23
|
+
<ResponseField name="code" type="string">The rate's unique code.</ResponseField>
|
|
24
|
+
<ResponseField name="type" type="string">The rate type: `fixed` or `percentage`.</ResponseField>
|
|
25
|
+
<ResponseField name="value" type="number">The commission value.</ResponseField>
|
|
26
|
+
<ResponseField name="currency_code" type="string | null">Currency of a fixed rate's value.</ResponseField>
|
|
27
|
+
<ResponseField name="include_tax" type="boolean">Whether commission is calculated on tax-inclusive amounts.</ResponseField>
|
|
28
|
+
<ResponseField name="include_shipping" type="boolean">Whether shipping is included in the commission base.</ResponseField>
|
|
29
|
+
<ResponseField name="is_enabled" type="boolean">Whether the rate is active.</ResponseField>
|
|
30
|
+
<ResponseField name="is_default" type="boolean">Whether this is the marketplace default rate.</ResponseField>
|
|
31
|
+
<ResponseField name="rules" type="object[]">Rules scoping the rate, each with `id`, `reference`, and `reference_id`.</ResponseField>
|
|
32
|
+
<ResponseField name="values" type="object[]">Per-currency fixed amounts, each with `id`, `currency_code`, and `amount`.</ResponseField>
|
|
33
|
+
<ResponseField name="created_at" type="string">Creation timestamp.</ResponseField>
|
|
34
|
+
<ResponseField name="updated_at" type="string">Last update timestamp.</ResponseField>
|
|
35
|
+
</Expandable>
|
|
36
|
+
</ResponseField>
|
|
37
|
+
|
|
38
|
+
<RequestExample>
|
|
39
|
+
```bash cURL
|
|
40
|
+
curl 'http://localhost:9000/admin/commission-rates/comrate_01HXYZ8Q2M4N6P8R0T2V4W6X8Y' \
|
|
41
|
+
-H 'Authorization: Bearer <token>'
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
```ts JS Client
|
|
45
|
+
const { commission_rate } = await client.admin.commissionRates.$id.query({
|
|
46
|
+
$id: "comrate_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
47
|
+
})
|
|
48
|
+
```
|
|
49
|
+
</RequestExample>
|
|
50
|
+
|
|
51
|
+
<ResponseExample>
|
|
52
|
+
```json 200
|
|
53
|
+
{
|
|
54
|
+
"commission_rate": {
|
|
55
|
+
"id": "comrate_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
56
|
+
"name": "Default",
|
|
57
|
+
"code": "default",
|
|
58
|
+
"type": "percentage",
|
|
59
|
+
"value": 10,
|
|
60
|
+
"currency_code": null,
|
|
61
|
+
"include_tax": false,
|
|
62
|
+
"include_shipping": false,
|
|
63
|
+
"is_enabled": true,
|
|
64
|
+
"is_default": true,
|
|
65
|
+
"rules": [],
|
|
66
|
+
"values": []
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
```
|
|
70
|
+
</ResponseExample>
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Update Commission Rate"
|
|
3
|
+
api: "POST /admin/commission-rates/{id}"
|
|
4
|
+
description: "Update a commission rate."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Updates a commission rate's properties.
|
|
8
|
+
|
|
9
|
+
<Note>
|
|
10
|
+
Rules are managed separately through the
|
|
11
|
+
[batch rules endpoint](/rc/references/api/admin/commission-rates/batch-commission-rules).
|
|
12
|
+
</Note>
|
|
13
|
+
|
|
14
|
+
## Path parameters
|
|
15
|
+
|
|
16
|
+
<ParamField path="id" type="string" required>The commission rate's ID.</ParamField>
|
|
17
|
+
|
|
18
|
+
## Body parameters
|
|
19
|
+
|
|
20
|
+
<ParamField body="name" type="string">The rate's display name.</ParamField>
|
|
21
|
+
<ParamField body="code" type="string">Unique code identifying the rate.</ParamField>
|
|
22
|
+
<ParamField body="type" type="string">The rate type: `fixed` or `percentage`.</ParamField>
|
|
23
|
+
<ParamField body="value" type="number">The commission value — a percentage or a fixed amount.</ParamField>
|
|
24
|
+
<ParamField body="currency_code" type="string">Currency of a fixed rate's value.</ParamField>
|
|
25
|
+
<ParamField body="include_tax" type="boolean">Whether commission is calculated on tax-inclusive amounts.</ParamField>
|
|
26
|
+
<ParamField body="include_shipping" type="boolean">Whether shipping is included in the commission base.</ParamField>
|
|
27
|
+
<ParamField body="is_enabled" type="boolean">Whether the rate is active.</ParamField>
|
|
28
|
+
<ParamField body="values" type="object[]">
|
|
29
|
+
Per-currency fixed amounts.
|
|
30
|
+
<Expandable title="properties">
|
|
31
|
+
<ParamField body="currency_code" type="string" required>The value's currency code.</ParamField>
|
|
32
|
+
<ParamField body="amount" type="number" required>The fixed commission amount for that currency.</ParamField>
|
|
33
|
+
</Expandable>
|
|
34
|
+
</ParamField>
|
|
35
|
+
|
|
36
|
+
## Response
|
|
37
|
+
|
|
38
|
+
<ResponseField name="commission_rate" type="object">
|
|
39
|
+
<Expandable title="properties">
|
|
40
|
+
<ResponseField name="id" type="string">The commission rate's ID.</ResponseField>
|
|
41
|
+
<ResponseField name="name" type="string">The rate's display name.</ResponseField>
|
|
42
|
+
<ResponseField name="code" type="string">The rate's unique code.</ResponseField>
|
|
43
|
+
<ResponseField name="type" type="string">The rate type: `fixed` or `percentage`.</ResponseField>
|
|
44
|
+
<ResponseField name="value" type="number">The commission value.</ResponseField>
|
|
45
|
+
<ResponseField name="is_enabled" type="boolean">Whether the rate is active.</ResponseField>
|
|
46
|
+
<ResponseField name="rules" type="object[]">Rules scoping the rate.</ResponseField>
|
|
47
|
+
<ResponseField name="values" type="object[]">Per-currency fixed amounts.</ResponseField>
|
|
48
|
+
</Expandable>
|
|
49
|
+
</ResponseField>
|
|
50
|
+
|
|
51
|
+
<RequestExample>
|
|
52
|
+
```bash cURL
|
|
53
|
+
curl -X POST 'http://localhost:9000/admin/commission-rates/comrate_01HXYZ8Q2M4N6P8R0T2V4W6X8Y' \
|
|
54
|
+
-H 'Authorization: Bearer <token>' \
|
|
55
|
+
-H 'Content-Type: application/json' \
|
|
56
|
+
-d '{"value": 15, "is_enabled": true}'
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
```ts JS Client
|
|
60
|
+
const { commission_rate } = await client.admin.commissionRates.$id.mutate({
|
|
61
|
+
$id: "comrate_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
62
|
+
value: 15,
|
|
63
|
+
is_enabled: true,
|
|
64
|
+
})
|
|
65
|
+
```
|
|
66
|
+
</RequestExample>
|
|
67
|
+
|
|
68
|
+
<ResponseExample>
|
|
69
|
+
```json 200
|
|
70
|
+
{
|
|
71
|
+
"commission_rate": {
|
|
72
|
+
"id": "comrate_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
73
|
+
"name": "Default",
|
|
74
|
+
"code": "default",
|
|
75
|
+
"type": "percentage",
|
|
76
|
+
"value": 15,
|
|
77
|
+
"is_enabled": true,
|
|
78
|
+
"is_default": true,
|
|
79
|
+
"rules": [],
|
|
80
|
+
"values": []
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
```
|
|
84
|
+
</ResponseExample>
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "List Members"
|
|
3
|
+
api: "GET /admin/members"
|
|
4
|
+
description: "Retrieve a paginated list of members across all sellers."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Returns member records platform-wide, useful for finding a member to add to a seller's team.
|
|
8
|
+
|
|
9
|
+
## Query parameters
|
|
10
|
+
|
|
11
|
+
<ParamField query="limit" type="number" default="10">Maximum number of records to return.</ParamField>
|
|
12
|
+
<ParamField query="offset" type="number" default="0">Number of records to skip.</ParamField>
|
|
13
|
+
<ParamField query="order" type="string">Field to sort by, prefix with `-` for descending order.</ParamField>
|
|
14
|
+
<ParamField query="fields" type="string">Comma-separated list of fields to include, prefix with `+`/`-` to add or remove from defaults.</ParamField>
|
|
15
|
+
<ParamField query="q" type="string">Search term matched against member fields.</ParamField>
|
|
16
|
+
<ParamField query="email" type="string">Filter by member email.</ParamField>
|
|
17
|
+
|
|
18
|
+
## Response
|
|
19
|
+
|
|
20
|
+
<ResponseField name="members" type="object[]">
|
|
21
|
+
<Expandable title="properties">
|
|
22
|
+
<ResponseField name="id" type="string">The member's ID.</ResponseField>
|
|
23
|
+
<ResponseField name="email" type="string">The member's email address.</ResponseField>
|
|
24
|
+
<ResponseField name="is_active" type="boolean">Whether the member's account is active.</ResponseField>
|
|
25
|
+
<ResponseField name="created_at" type="string">Creation timestamp.</ResponseField>
|
|
26
|
+
</Expandable>
|
|
27
|
+
</ResponseField>
|
|
28
|
+
<ResponseField name="count" type="number">Total number of matching members.</ResponseField>
|
|
29
|
+
<ResponseField name="offset" type="number">Number of records skipped.</ResponseField>
|
|
30
|
+
<ResponseField name="limit" type="number">Number of records returned.</ResponseField>
|
|
31
|
+
|
|
32
|
+
<RequestExample>
|
|
33
|
+
```bash cURL
|
|
34
|
+
curl 'http://localhost:9000/admin/members?email=owner@acme.co' \
|
|
35
|
+
-H 'Authorization: Bearer <token>'
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
```ts JS Client
|
|
39
|
+
const { members, count } = await client.admin.members.query({
|
|
40
|
+
email: "owner@acme.co",
|
|
41
|
+
})
|
|
42
|
+
```
|
|
43
|
+
</RequestExample>
|
|
44
|
+
|
|
45
|
+
<ResponseExample>
|
|
46
|
+
```json 200
|
|
47
|
+
{
|
|
48
|
+
"members": [
|
|
49
|
+
{
|
|
50
|
+
"id": "mem_01HXYZMEMAA",
|
|
51
|
+
"email": "owner@acme.co",
|
|
52
|
+
"is_active": true,
|
|
53
|
+
"created_at": "2026-06-01T10:00:00.000Z"
|
|
54
|
+
}
|
|
55
|
+
],
|
|
56
|
+
"count": 1,
|
|
57
|
+
"offset": 0,
|
|
58
|
+
"limit": 10
|
|
59
|
+
}
|
|
60
|
+
```
|
|
61
|
+
</ResponseExample>
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Batch Create Offers"
|
|
3
|
+
api: "POST /admin/offers/batch"
|
|
4
|
+
description: "Create up to 100 offers for a seller in one request."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Creates multiple offers on behalf of a seller. The authenticated admin user is recorded as the creator.
|
|
8
|
+
|
|
9
|
+
## Body parameters
|
|
10
|
+
|
|
11
|
+
<ParamField body="seller_id" type="string" required>ID of the seller the offers belong to.</ParamField>
|
|
12
|
+
<ParamField body="offers" type="object[]" required>
|
|
13
|
+
The offers to create — between 1 and 100.
|
|
14
|
+
<Expandable title="properties">
|
|
15
|
+
<ParamField body="sku" type="string" required>The offer's SKU.</ParamField>
|
|
16
|
+
<ParamField body="variant_id" type="string" required>ID of the product variant to offer.</ParamField>
|
|
17
|
+
<ParamField body="shipping_profile_id" type="string" required>ID of the seller's shipping profile.</ParamField>
|
|
18
|
+
<ParamField body="prices" type="object[]" required>
|
|
19
|
+
Offer prices — at least one.
|
|
20
|
+
<Expandable title="properties">
|
|
21
|
+
<ParamField body="amount" type="number" required>The price amount.</ParamField>
|
|
22
|
+
<ParamField body="currency_code" type="string" required>The price currency.</ParamField>
|
|
23
|
+
<ParamField body="min_quantity" type="number">Minimum quantity the price applies to.</ParamField>
|
|
24
|
+
<ParamField body="max_quantity" type="number">Maximum quantity the price applies to.</ParamField>
|
|
25
|
+
<ParamField body="rules" type="object">Price rules as attribute-value pairs.</ParamField>
|
|
26
|
+
</Expandable>
|
|
27
|
+
</ParamField>
|
|
28
|
+
<ParamField body="inventory_items" type="object[]" required>
|
|
29
|
+
Inventory items backing the offer — at least one.
|
|
30
|
+
<Expandable title="properties">
|
|
31
|
+
<ParamField body="title" type="string">The inventory item's title.</ParamField>
|
|
32
|
+
<ParamField body="sku" type="string">The inventory item's SKU.</ParamField>
|
|
33
|
+
<ParamField body="required_quantity" type="number" default="1">Quantity required per unit sold.</ParamField>
|
|
34
|
+
<ParamField body="stock_levels" type="object[]">
|
|
35
|
+
Initial stock levels.
|
|
36
|
+
<Expandable title="properties">
|
|
37
|
+
<ParamField body="location_id" type="string" required>The stock location's ID.</ParamField>
|
|
38
|
+
<ParamField body="stocked_quantity" type="number" required>Quantity in stock at the location.</ParamField>
|
|
39
|
+
</Expandable>
|
|
40
|
+
</ParamField>
|
|
41
|
+
</Expandable>
|
|
42
|
+
</ParamField>
|
|
43
|
+
<ParamField body="ean" type="string">The offer's EAN.</ParamField>
|
|
44
|
+
<ParamField body="upc" type="string">The offer's UPC.</ParamField>
|
|
45
|
+
<ParamField body="metadata" type="object">Custom key-value data.</ParamField>
|
|
46
|
+
</Expandable>
|
|
47
|
+
</ParamField>
|
|
48
|
+
|
|
49
|
+
## Response
|
|
50
|
+
|
|
51
|
+
<ResponseField name="offers" type="object[]">
|
|
52
|
+
<Expandable title="properties">
|
|
53
|
+
<ResponseField name="id" type="string">The offer's ID.</ResponseField>
|
|
54
|
+
<ResponseField name="seller_id" type="string">ID of the seller who owns the offer.</ResponseField>
|
|
55
|
+
<ResponseField name="variant_id" type="string">ID of the offered product variant.</ResponseField>
|
|
56
|
+
<ResponseField name="shipping_profile_id" type="string">ID of the offer's shipping profile.</ResponseField>
|
|
57
|
+
<ResponseField name="sku" type="string">The offer's SKU.</ResponseField>
|
|
58
|
+
<ResponseField name="prices" type="object[]">The offer's prices.</ResponseField>
|
|
59
|
+
<ResponseField name="inventory_items" type="object[]">The offer's linked inventory items.</ResponseField>
|
|
60
|
+
</Expandable>
|
|
61
|
+
</ResponseField>
|
|
62
|
+
|
|
63
|
+
<RequestExample>
|
|
64
|
+
```bash cURL
|
|
65
|
+
curl -X POST 'http://localhost:9000/admin/offers/batch' \
|
|
66
|
+
-H 'Authorization: Bearer <token>' \
|
|
67
|
+
-H 'Content-Type: application/json' \
|
|
68
|
+
-d '{
|
|
69
|
+
"seller_id": "sel_01HXYZ",
|
|
70
|
+
"offers": [
|
|
71
|
+
{
|
|
72
|
+
"sku": "SHIRT-M-BLUE",
|
|
73
|
+
"variant_id": "variant_01HXYZ",
|
|
74
|
+
"shipping_profile_id": "sp_01HXYZ",
|
|
75
|
+
"prices": [{ "amount": 2500, "currency_code": "usd" }],
|
|
76
|
+
"inventory_items": [
|
|
77
|
+
{
|
|
78
|
+
"sku": "SHIRT-M-BLUE",
|
|
79
|
+
"required_quantity": 1,
|
|
80
|
+
"stock_levels": [{ "location_id": "sloc_01HXYZ", "stocked_quantity": 100 }]
|
|
81
|
+
}
|
|
82
|
+
]
|
|
83
|
+
}
|
|
84
|
+
]
|
|
85
|
+
}'
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
```ts JS Client
|
|
89
|
+
const { offers } = await client.admin.offers.batch.mutate({
|
|
90
|
+
seller_id: "sel_01HXYZ",
|
|
91
|
+
offers: [
|
|
92
|
+
{
|
|
93
|
+
sku: "SHIRT-M-BLUE",
|
|
94
|
+
variant_id: "variant_01HXYZ",
|
|
95
|
+
shipping_profile_id: "sp_01HXYZ",
|
|
96
|
+
prices: [{ amount: 2500, currency_code: "usd" }],
|
|
97
|
+
inventory_items: [
|
|
98
|
+
{
|
|
99
|
+
sku: "SHIRT-M-BLUE",
|
|
100
|
+
required_quantity: 1,
|
|
101
|
+
stock_levels: [{ location_id: "sloc_01HXYZ", stocked_quantity: 100 }],
|
|
102
|
+
},
|
|
103
|
+
],
|
|
104
|
+
},
|
|
105
|
+
],
|
|
106
|
+
})
|
|
107
|
+
```
|
|
108
|
+
</RequestExample>
|
|
109
|
+
|
|
110
|
+
<ResponseExample>
|
|
111
|
+
```json 201
|
|
112
|
+
{
|
|
113
|
+
"offers": [
|
|
114
|
+
{
|
|
115
|
+
"id": "offer_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
116
|
+
"seller_id": "sel_01HXYZ",
|
|
117
|
+
"variant_id": "variant_01HXYZ",
|
|
118
|
+
"shipping_profile_id": "sp_01HXYZ",
|
|
119
|
+
"sku": "SHIRT-M-BLUE",
|
|
120
|
+
"prices": [
|
|
121
|
+
{ "id": "price_01HXYZ", "amount": 2500, "currency_code": "usd" }
|
|
122
|
+
],
|
|
123
|
+
"inventory_items": [
|
|
124
|
+
{ "id": "iitem_01HXYZ", "inventory_item_id": "iitem_01HXYZ", "required_quantity": 1, "sku": "SHIRT-M-BLUE" }
|
|
125
|
+
]
|
|
126
|
+
}
|
|
127
|
+
]
|
|
128
|
+
}
|
|
129
|
+
```
|
|
130
|
+
</ResponseExample>
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Delete Offer"
|
|
3
|
+
api: "DELETE /admin/offers/{id}"
|
|
4
|
+
description: "Delete an offer."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Deletes an offer by ID.
|
|
8
|
+
|
|
9
|
+
## Path parameters
|
|
10
|
+
|
|
11
|
+
<ParamField path="id" type="string" required>The offer's ID.</ParamField>
|
|
12
|
+
|
|
13
|
+
## Response
|
|
14
|
+
|
|
15
|
+
<ResponseField name="id" type="string">The deleted offer's ID.</ResponseField>
|
|
16
|
+
<ResponseField name="object" type="string">The object type: `offer`.</ResponseField>
|
|
17
|
+
<ResponseField name="deleted" type="boolean">Whether the offer was deleted.</ResponseField>
|
|
18
|
+
|
|
19
|
+
<RequestExample>
|
|
20
|
+
```bash cURL
|
|
21
|
+
curl -X DELETE 'http://localhost:9000/admin/offers/offer_01HXYZ8Q2M4N6P8R0T2V4W6X8Y' \
|
|
22
|
+
-H 'Authorization: Bearer <token>'
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
```ts JS Client
|
|
26
|
+
const result = await client.admin.offers.$id.delete({
|
|
27
|
+
$id: "offer_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
28
|
+
})
|
|
29
|
+
```
|
|
30
|
+
</RequestExample>
|
|
31
|
+
|
|
32
|
+
<ResponseExample>
|
|
33
|
+
```json 200
|
|
34
|
+
{
|
|
35
|
+
"id": "offer_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
36
|
+
"object": "offer",
|
|
37
|
+
"deleted": true
|
|
38
|
+
}
|
|
39
|
+
```
|
|
40
|
+
</ResponseExample>
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "List Offers"
|
|
3
|
+
api: "GET /admin/offers"
|
|
4
|
+
description: "Retrieve a paginated list of offers across all sellers."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Returns offers with their seller, variant, shipping profile, prices, and inventory items.
|
|
8
|
+
|
|
9
|
+
## Query parameters
|
|
10
|
+
|
|
11
|
+
<ParamField query="limit" type="number" default="50">Maximum number of records to return.</ParamField>
|
|
12
|
+
<ParamField query="offset" type="number" default="0">Number of records to skip.</ParamField>
|
|
13
|
+
<ParamField query="order" type="string">Field to sort by, prefix with `-` for descending order.</ParamField>
|
|
14
|
+
<ParamField query="fields" type="string">Comma-separated fields to include in the response.</ParamField>
|
|
15
|
+
<ParamField query="q" type="string">Search term matched against offers.</ParamField>
|
|
16
|
+
<ParamField query="id" type="string | string[]">Filter by offer ID(s).</ParamField>
|
|
17
|
+
<ParamField query="seller_id" type="string | string[]">Filter by seller ID(s).</ParamField>
|
|
18
|
+
<ParamField query="variant_id" type="string | string[]">Filter by product variant ID(s).</ParamField>
|
|
19
|
+
<ParamField query="shipping_profile_id" type="string | string[]">Filter by shipping profile ID(s).</ParamField>
|
|
20
|
+
<ParamField query="sku" type="string | string[]">Filter by SKU(s).</ParamField>
|
|
21
|
+
<ParamField query="ean" type="string | string[]">Filter by EAN(s).</ParamField>
|
|
22
|
+
<ParamField query="upc" type="string | string[]">Filter by UPC(s).</ParamField>
|
|
23
|
+
<ParamField query="group_by_seller" type="boolean">Group results by seller.</ParamField>
|
|
24
|
+
<ParamField query="status" type="string | string[]">Filter by the offered product's status.</ParamField>
|
|
25
|
+
<ParamField query="category_id" type="string | string[]">Filter by product category ID(s).</ParamField>
|
|
26
|
+
<ParamField query="collection_id" type="string | string[]">Filter by product collection ID(s).</ParamField>
|
|
27
|
+
<ParamField query="type_id" type="string | string[]">Filter by product type ID(s).</ParamField>
|
|
28
|
+
<ParamField query="tag_id" type="string | string[]">Filter by product tag ID(s).</ParamField>
|
|
29
|
+
<ParamField query="created_at" type="object">Filter by creation date using operators like `$gte` and `$lte`.</ParamField>
|
|
30
|
+
<ParamField query="updated_at" type="object">Filter by update date using operators like `$gte` and `$lte`.</ParamField>
|
|
31
|
+
|
|
32
|
+
## Response
|
|
33
|
+
|
|
34
|
+
<ResponseField name="offers" type="object[]">
|
|
35
|
+
<Expandable title="properties">
|
|
36
|
+
<ResponseField name="id" type="string">The offer's ID.</ResponseField>
|
|
37
|
+
<ResponseField name="seller_id" type="string">ID of the seller who owns the offer.</ResponseField>
|
|
38
|
+
<ResponseField name="variant_id" type="string">ID of the offered product variant.</ResponseField>
|
|
39
|
+
<ResponseField name="product_id" type="string">ID of the offered product.</ResponseField>
|
|
40
|
+
<ResponseField name="shipping_profile_id" type="string">ID of the offer's shipping profile.</ResponseField>
|
|
41
|
+
<ResponseField name="sku" type="string">The offer's SKU.</ResponseField>
|
|
42
|
+
<ResponseField name="ean" type="string | null">The offer's EAN.</ResponseField>
|
|
43
|
+
<ResponseField name="upc" type="string | null">The offer's UPC.</ResponseField>
|
|
44
|
+
<ResponseField name="created_by" type="string">ID of the actor who created the offer.</ResponseField>
|
|
45
|
+
<ResponseField name="variant_count" type="number">Number of variants on the offered product.</ResponseField>
|
|
46
|
+
<ResponseField name="metadata" type="object | null">Custom key-value data.</ResponseField>
|
|
47
|
+
<ResponseField name="seller" type="object">The seller, with `id`, `name`, and `handle`.</ResponseField>
|
|
48
|
+
<ResponseField name="product_variant" type="object">The variant, with `id`, `title`, and `sku`.</ResponseField>
|
|
49
|
+
<ResponseField name="shipping_profile" type="object">The shipping profile, with `id` and `name`.</ResponseField>
|
|
50
|
+
<ResponseField name="prices" type="object[]">Offer prices, each with `id`, `amount`, `currency_code`, `min_quantity`, `max_quantity`, and `price_rules`.</ResponseField>
|
|
51
|
+
<ResponseField name="inventory_items" type="object[]">Linked inventory items, each with `id`, `inventory_item_id`, `required_quantity`, and `sku`.</ResponseField>
|
|
52
|
+
<ResponseField name="created_at" type="string">Creation timestamp.</ResponseField>
|
|
53
|
+
<ResponseField name="updated_at" type="string">Last update timestamp.</ResponseField>
|
|
54
|
+
</Expandable>
|
|
55
|
+
</ResponseField>
|
|
56
|
+
<ResponseField name="count" type="number">Total number of matching offers.</ResponseField>
|
|
57
|
+
<ResponseField name="offset" type="number">Number of records skipped.</ResponseField>
|
|
58
|
+
<ResponseField name="limit" type="number">Maximum number of records returned.</ResponseField>
|
|
59
|
+
|
|
60
|
+
<RequestExample>
|
|
61
|
+
```bash cURL
|
|
62
|
+
curl 'http://localhost:9000/admin/offers?seller_id=sel_01HXYZ&limit=20' \
|
|
63
|
+
-H 'Authorization: Bearer <token>'
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
```ts JS Client
|
|
67
|
+
const { offers, count } = await client.admin.offers.query({
|
|
68
|
+
seller_id: "sel_01HXYZ",
|
|
69
|
+
limit: 20,
|
|
70
|
+
})
|
|
71
|
+
```
|
|
72
|
+
</RequestExample>
|
|
73
|
+
|
|
74
|
+
<ResponseExample>
|
|
75
|
+
```json 200
|
|
76
|
+
{
|
|
77
|
+
"offers": [
|
|
78
|
+
{
|
|
79
|
+
"id": "offer_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
80
|
+
"seller_id": "sel_01HXYZ",
|
|
81
|
+
"variant_id": "variant_01HXYZ",
|
|
82
|
+
"product_id": "prod_01HXYZ",
|
|
83
|
+
"shipping_profile_id": "sp_01HXYZ",
|
|
84
|
+
"sku": "SHIRT-M-BLUE",
|
|
85
|
+
"ean": null,
|
|
86
|
+
"upc": null,
|
|
87
|
+
"created_by": "user_01HXYZ",
|
|
88
|
+
"variant_count": 3,
|
|
89
|
+
"metadata": null,
|
|
90
|
+
"seller": { "id": "sel_01HXYZ", "name": "Acme Store", "handle": "acme-store" },
|
|
91
|
+
"product_variant": { "id": "variant_01HXYZ", "title": "M / Blue", "sku": "SHIRT-M-BLUE" },
|
|
92
|
+
"shipping_profile": { "id": "sp_01HXYZ", "name": "Default" },
|
|
93
|
+
"prices": [
|
|
94
|
+
{ "id": "price_01HXYZ", "amount": 2500, "currency_code": "usd", "min_quantity": null, "max_quantity": null }
|
|
95
|
+
],
|
|
96
|
+
"inventory_items": [
|
|
97
|
+
{ "id": "iitem_01HXYZ", "inventory_item_id": "iitem_01HXYZ", "required_quantity": 1, "sku": "SHIRT-M-BLUE" }
|
|
98
|
+
]
|
|
99
|
+
}
|
|
100
|
+
],
|
|
101
|
+
"count": 1,
|
|
102
|
+
"offset": 0,
|
|
103
|
+
"limit": 20
|
|
104
|
+
}
|
|
105
|
+
```
|
|
106
|
+
</ResponseExample>
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "Retrieve Offer"
|
|
3
|
+
api: "GET /admin/offers/{id}"
|
|
4
|
+
description: "Retrieve an offer by ID."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Returns a single offer with its seller, variant, shipping profile, prices, and inventory items.
|
|
8
|
+
|
|
9
|
+
## Path parameters
|
|
10
|
+
|
|
11
|
+
<ParamField path="id" type="string" required>The offer's ID.</ParamField>
|
|
12
|
+
|
|
13
|
+
## Query parameters
|
|
14
|
+
|
|
15
|
+
<ParamField query="fields" type="string">Comma-separated fields to include in the response.</ParamField>
|
|
16
|
+
|
|
17
|
+
## Response
|
|
18
|
+
|
|
19
|
+
<ResponseField name="offer" type="object">
|
|
20
|
+
<Expandable title="properties">
|
|
21
|
+
<ResponseField name="id" type="string">The offer's ID.</ResponseField>
|
|
22
|
+
<ResponseField name="seller_id" type="string">ID of the seller who owns the offer.</ResponseField>
|
|
23
|
+
<ResponseField name="variant_id" type="string">ID of the offered product variant.</ResponseField>
|
|
24
|
+
<ResponseField name="product_id" type="string">ID of the offered product.</ResponseField>
|
|
25
|
+
<ResponseField name="shipping_profile_id" type="string">ID of the offer's shipping profile.</ResponseField>
|
|
26
|
+
<ResponseField name="sku" type="string">The offer's SKU.</ResponseField>
|
|
27
|
+
<ResponseField name="ean" type="string | null">The offer's EAN.</ResponseField>
|
|
28
|
+
<ResponseField name="upc" type="string | null">The offer's UPC.</ResponseField>
|
|
29
|
+
<ResponseField name="created_by" type="string">ID of the actor who created the offer.</ResponseField>
|
|
30
|
+
<ResponseField name="variant_count" type="number">Number of variants on the offered product.</ResponseField>
|
|
31
|
+
<ResponseField name="metadata" type="object | null">Custom key-value data.</ResponseField>
|
|
32
|
+
<ResponseField name="seller" type="object">The seller, with `id`, `name`, and `handle`.</ResponseField>
|
|
33
|
+
<ResponseField name="product_variant" type="object">The variant, with `id`, `title`, and `sku`.</ResponseField>
|
|
34
|
+
<ResponseField name="shipping_profile" type="object">The shipping profile, with `id` and `name`.</ResponseField>
|
|
35
|
+
<ResponseField name="prices" type="object[]">Offer prices, each with `id`, `amount`, `currency_code`, `min_quantity`, `max_quantity`, and `price_rules`.</ResponseField>
|
|
36
|
+
<ResponseField name="inventory_items" type="object[]">Linked inventory items, each with `id`, `inventory_item_id`, `required_quantity`, and `sku`.</ResponseField>
|
|
37
|
+
<ResponseField name="created_at" type="string">Creation timestamp.</ResponseField>
|
|
38
|
+
<ResponseField name="updated_at" type="string">Last update timestamp.</ResponseField>
|
|
39
|
+
</Expandable>
|
|
40
|
+
</ResponseField>
|
|
41
|
+
|
|
42
|
+
<RequestExample>
|
|
43
|
+
```bash cURL
|
|
44
|
+
curl 'http://localhost:9000/admin/offers/offer_01HXYZ8Q2M4N6P8R0T2V4W6X8Y' \
|
|
45
|
+
-H 'Authorization: Bearer <token>'
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
```ts JS Client
|
|
49
|
+
const { offer } = await client.admin.offers.$id.query({
|
|
50
|
+
$id: "offer_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
51
|
+
})
|
|
52
|
+
```
|
|
53
|
+
</RequestExample>
|
|
54
|
+
|
|
55
|
+
<ResponseExample>
|
|
56
|
+
```json 200
|
|
57
|
+
{
|
|
58
|
+
"offer": {
|
|
59
|
+
"id": "offer_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
60
|
+
"seller_id": "sel_01HXYZ",
|
|
61
|
+
"variant_id": "variant_01HXYZ",
|
|
62
|
+
"product_id": "prod_01HXYZ",
|
|
63
|
+
"shipping_profile_id": "sp_01HXYZ",
|
|
64
|
+
"sku": "SHIRT-M-BLUE",
|
|
65
|
+
"ean": null,
|
|
66
|
+
"upc": null,
|
|
67
|
+
"created_by": "user_01HXYZ",
|
|
68
|
+
"variant_count": 3,
|
|
69
|
+
"metadata": null,
|
|
70
|
+
"seller": { "id": "sel_01HXYZ", "name": "Acme Store", "handle": "acme-store" },
|
|
71
|
+
"product_variant": { "id": "variant_01HXYZ", "title": "M / Blue", "sku": "SHIRT-M-BLUE" },
|
|
72
|
+
"shipping_profile": { "id": "sp_01HXYZ", "name": "Default" },
|
|
73
|
+
"prices": [
|
|
74
|
+
{ "id": "price_01HXYZ", "amount": 2500, "currency_code": "usd", "min_quantity": null, "max_quantity": null }
|
|
75
|
+
],
|
|
76
|
+
"inventory_items": [
|
|
77
|
+
{ "id": "iitem_01HXYZ", "inventory_item_id": "iitem_01HXYZ", "required_quantity": 1, "sku": "SHIRT-M-BLUE" }
|
|
78
|
+
]
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
```
|
|
82
|
+
</ResponseExample>
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: "List Order Groups"
|
|
3
|
+
api: "GET /admin/order-groups"
|
|
4
|
+
description: "Retrieve a paginated list of order groups."
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Returns order groups — the customer-facing wrappers around per-seller orders created from a multi-seller cart.
|
|
8
|
+
|
|
9
|
+
<Note>
|
|
10
|
+
Filtering by `seller_id` narrows results to order groups that contain at
|
|
11
|
+
least one order belonging to that seller.
|
|
12
|
+
</Note>
|
|
13
|
+
|
|
14
|
+
## Query parameters
|
|
15
|
+
|
|
16
|
+
<ParamField query="limit" type="number" default="50">Maximum number of records to return.</ParamField>
|
|
17
|
+
<ParamField query="offset" type="number" default="0">Number of records to skip.</ParamField>
|
|
18
|
+
<ParamField query="order" type="string">Field to sort by, prefix with `-` for descending order.</ParamField>
|
|
19
|
+
<ParamField query="fields" type="string">Comma-separated fields to include in the response.</ParamField>
|
|
20
|
+
<ParamField query="q" type="string">Search term matched against order groups.</ParamField>
|
|
21
|
+
<ParamField query="id" type="string | string[]">Filter by order group ID(s).</ParamField>
|
|
22
|
+
<ParamField query="customer_id" type="string | string[]">Filter by customer ID(s).</ParamField>
|
|
23
|
+
<ParamField query="seller_id" type="string | string[]">Filter to groups containing orders from the given seller(s).</ParamField>
|
|
24
|
+
<ParamField query="status" type="string | string[]">Filter by order group status.</ParamField>
|
|
25
|
+
<ParamField query="sales_channel_id" type="string | string[]">Filter by sales channel ID(s).</ParamField>
|
|
26
|
+
<ParamField query="created_at" type="object">Filter by creation date using operators like `$gte` and `$lte`.</ParamField>
|
|
27
|
+
<ParamField query="updated_at" type="object">Filter by update date using operators like `$gte` and `$lte`.</ParamField>
|
|
28
|
+
|
|
29
|
+
## Response
|
|
30
|
+
|
|
31
|
+
<ResponseField name="order_groups" type="object[]">
|
|
32
|
+
<Expandable title="properties">
|
|
33
|
+
<ResponseField name="id" type="string">The order group's ID.</ResponseField>
|
|
34
|
+
<ResponseField name="customer_id" type="string">ID of the customer who placed the order.</ResponseField>
|
|
35
|
+
<ResponseField name="seller_count" type="number">Number of sellers in the group.</ResponseField>
|
|
36
|
+
<ResponseField name="total" type="number">The group's total amount.</ResponseField>
|
|
37
|
+
<ResponseField name="created_at" type="string">Creation timestamp.</ResponseField>
|
|
38
|
+
<ResponseField name="updated_at" type="string">Last update timestamp.</ResponseField>
|
|
39
|
+
</Expandable>
|
|
40
|
+
</ResponseField>
|
|
41
|
+
<ResponseField name="count" type="number">Total number of matching order groups.</ResponseField>
|
|
42
|
+
<ResponseField name="offset" type="number">Number of records skipped.</ResponseField>
|
|
43
|
+
<ResponseField name="limit" type="number">Maximum number of records returned.</ResponseField>
|
|
44
|
+
|
|
45
|
+
<RequestExample>
|
|
46
|
+
```bash cURL
|
|
47
|
+
curl 'http://localhost:9000/admin/order-groups?customer_id=cus_01HXYZ&limit=20' \
|
|
48
|
+
-H 'Authorization: Bearer <token>'
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
```ts JS Client
|
|
52
|
+
const { order_groups, count } = await client.admin.orderGroups.query({
|
|
53
|
+
customer_id: "cus_01HXYZ",
|
|
54
|
+
limit: 20,
|
|
55
|
+
})
|
|
56
|
+
```
|
|
57
|
+
</RequestExample>
|
|
58
|
+
|
|
59
|
+
<ResponseExample>
|
|
60
|
+
```json 200
|
|
61
|
+
{
|
|
62
|
+
"order_groups": [
|
|
63
|
+
{
|
|
64
|
+
"id": "og_01HXYZ8Q2M4N6P8R0T2V4W6X8Y",
|
|
65
|
+
"customer_id": "cus_01HXYZ",
|
|
66
|
+
"seller_count": 2,
|
|
67
|
+
"total": 7400,
|
|
68
|
+
"created_at": "2026-06-01T10:00:00.000Z",
|
|
69
|
+
"updated_at": "2026-06-01T10:00:00.000Z"
|
|
70
|
+
}
|
|
71
|
+
],
|
|
72
|
+
"count": 1,
|
|
73
|
+
"offset": 0,
|
|
74
|
+
"limit": 20
|
|
75
|
+
}
|
|
76
|
+
```
|
|
77
|
+
</ResponseExample>
|