docs: add missing shipping_profile_id in create product snippets (#11443)

* initial

* add link
This commit is contained in:
Shahed Nasser
2025-02-13 15:30:40 +02:00
committed by GitHub
parent 4e6372bfdf
commit b864cb4e28
5 changed files with 12 additions and 2 deletions
@@ -176,6 +176,7 @@ export const createMultiPartProductsWorkflow = createWorkflow(
values: ["Default Variant"],
},
],
shipping_profile_id: "sp_123",
},
],
},
@@ -229,6 +230,7 @@ export const createBundledProducts = createWorkflow(
products: [
{
title: "Shirt",
shipping_profile_id: "sp_123",
variants: [
{
title: "Shirt",
@@ -253,6 +255,7 @@ export const createBundledProducts = createWorkflow(
},
{
title: "Pants",
shipping_profile_id: "sp_123",
variants: [
{
title: "Pants",
@@ -277,6 +280,7 @@ export const createBundledProducts = createWorkflow(
},
{
title: "Shoes",
shipping_profile_id: "sp_123",
variants: [
{
title: "Shoes",
@@ -381,6 +385,7 @@ export const createBundledProducts = createWorkflow(
products: [
{
title: "Bundled Clothes",
shipping_profile_id: "sp_123",
variants: [
{
title: "Bundle",
@@ -319,6 +319,7 @@ curl -X POST 'localhost:9000/admin/products' \
"values": ["Default option value"]
}
],
"shipping_profile_id": "{shipping_profile_id}",
"additional_data": {
"custom_name": "test"
}
@@ -327,6 +328,8 @@ curl -X POST 'localhost:9000/admin/products' \
Make sure to replace `{token}` with an admin user's JWT token. Learn how to retrieve it in the [API reference](!api!/admin#1-bearer-authorization-with-jwt-tokens).
Also, make sure to replace `{shipping_profile_id}` with an existing shipping profile's ID. You can retrieve one either from the Medusa Admin dashboard or using the [List Shipping Profiles API Route](!api!/admin#shipping-profiles_getshippingprofiles).
The request will return the product's details. You'll learn how to retreive the `custom_name` property with the product's details in the next section.
---