Products
Create a product
POST/api/v1/products
Adds a product to one of your stores. It goes on sale at once unless you create it as a draft.
Authorization
Bearer sk_test_… or sk_live_…Headers#
Idempotency-KeystringRequiredClient-generated key that makes the request safe to retry. Replaying the key with an identical payload returns the original response; replaying it with a different payload is rejected. Up to 255 characters.
Body parameters#
namestringRequiredUp to 120 characters.
price_minorintegerRequiredAt least 1.
storefront_iduuidRequiredThe store to add it to.
category_iduuidOptionaldelivery_notestringOptionalUp to 1000 characters.
descriptionstringOptionalUp to 2000 characters.
fulfillmentstringOptionalOne of
shipping,pickup,shipping_or_pickup.kindstringOptionalPhysical when left out. One of
physical,digital.sale_price_minorintegerOptionalAt least 1.
shipping_notestringOptionalUp to 300 characters.
statusstringOptionalActive when left out. One of
active,draft,archived.stockintegerOptionalLeave out to not track stock. At least 0.
tagsarray of stringOptional
Responses#
- 201Product created
- 401The secret key is missing, invalid or revoked.
- 403The key is not allowed to do this, or the request came from an address that is not on its allowlist.
- 404Nothing was found for this business and mode.
- 409The request clashes with the current state, such as a reference reused with different details.
- 422A field is missing or not valid.