curl -X POST "https://ecommerce.jelou.ai/api/v2/apps/{app_id}/batch/products/upsert_by_sku" \
-H "Authorization: Bearer <API_KEY>" \
-H "Content-Type: application/json" \
-d '{
"resources": [
{
"sku": "TSHIRT-BLU",
"name": "Basic Blue T-Shirt",
"description": "100% premium cotton t-shirt, regular fit",
"price": 29.99,
"has_tax": true,
"status": true,
"stock_type": "limited",
"stock": 150,
"product_url": "https://my-store.com/basic-blue-tshirt",
"discount_type": "percentage",
"discount": 10,
"branch": "BRANCH-DOWNTOWN",
"categories": ["Clothing", "T-Shirts"],
"images": [
"https://my-store.com/images/blue-tshirt-front.jpg",
"https://my-store.com/images/blue-tshirt-back.jpg"
],
"variations": [
{
"sku": "TSHIRT-BLU-S",
"price": 29.99,
"attributes": [
{ "name": "Size", "value": "S" },
{ "name": "Color", "value": "Blue" }
]
},
{
"sku": "TSHIRT-BLU-M",
"price": 29.99,
"attributes": [
{ "name": "Size", "value": "M" },
{ "name": "Color", "value": "Blue" }
]
},
{
"sku": "TSHIRT-BLU-L",
"price": 31.99,
"attributes": [
{ "name": "Size", "value": "L" },
{ "name": "Color", "value": "Blue" }
],
"images": [
"https://my-store.com/images/blue-tshirt-L.jpg"
]
}
]
},
{
"sku": "PANTS-BLK-M",
"name": "Black Pants",
"price": 49.99,
"branch": "BRANCH-NORTH",
"categories": ["Clothing", "Pants"]
},
{
"sku": "PIZZA-FAMILY",
"name": "Family Pepperoni Pizza",
"description": "Family-size pepperoni pizza with artisan crust",
"price": 18.99,
"stock_type": "unlimited",
"branch": "BRANCH-NORTH",
"categories": ["Pizzas", "Promotions"],
"images": ["https://example.com/pepperoni-pizza.jpg"],
"modifier_groups": [
{
"code": "drinks",
"name": "Choose your Drink",
"min_quantity": 1,
"max_quantity": 1,
"is_required": true,
"options": [
{ "code": "coca-1l", "name": "Coca Cola 1L", "price": 0 },
{ "code": "sprite-1l", "name": "Sprite 1L", "price": 0 },
{ "code": "fanta-1l", "name": "Fanta 1L", "price": 0.50 }
]
},
{
"code": "extras",
"name": "Extra Toppings",
"min_quantity": 0,
"max_quantity": 5,
"max_per_option": 2,
"is_required": false,
"options": [
{ "code": "extra-cheese", "name": "Extra Cheese", "price": 1.50 },
{ "code": "ham", "name": "Ham", "price": 2.00 },
{ "code": "olives", "name": "Olives", "price": 1.00 }
]
}
]
}
]
}'
{
"message": "Batch upsert process initiated successfully",
"count": 3,
"jobs": 3
}
Create and update products with support for branches, variations, and modifiers.
curl -X POST "https://ecommerce.jelou.ai/api/v2/apps/{app_id}/batch/products/upsert_by_sku" \
-H "Authorization: Bearer <API_KEY>" \
-H "Content-Type: application/json" \
-d '{
"resources": [
{
"sku": "TSHIRT-BLU",
"name": "Basic Blue T-Shirt",
"description": "100% premium cotton t-shirt, regular fit",
"price": 29.99,
"has_tax": true,
"status": true,
"stock_type": "limited",
"stock": 150,
"product_url": "https://my-store.com/basic-blue-tshirt",
"discount_type": "percentage",
"discount": 10,
"branch": "BRANCH-DOWNTOWN",
"categories": ["Clothing", "T-Shirts"],
"images": [
"https://my-store.com/images/blue-tshirt-front.jpg",
"https://my-store.com/images/blue-tshirt-back.jpg"
],
"variations": [
{
"sku": "TSHIRT-BLU-S",
"price": 29.99,
"attributes": [
{ "name": "Size", "value": "S" },
{ "name": "Color", "value": "Blue" }
]
},
{
"sku": "TSHIRT-BLU-M",
"price": 29.99,
"attributes": [
{ "name": "Size", "value": "M" },
{ "name": "Color", "value": "Blue" }
]
},
{
"sku": "TSHIRT-BLU-L",
"price": 31.99,
"attributes": [
{ "name": "Size", "value": "L" },
{ "name": "Color", "value": "Blue" }
],
"images": [
"https://my-store.com/images/blue-tshirt-L.jpg"
]
}
]
},
{
"sku": "PANTS-BLK-M",
"name": "Black Pants",
"price": 49.99,
"branch": "BRANCH-NORTH",
"categories": ["Clothing", "Pants"]
},
{
"sku": "PIZZA-FAMILY",
"name": "Family Pepperoni Pizza",
"description": "Family-size pepperoni pizza with artisan crust",
"price": 18.99,
"stock_type": "unlimited",
"branch": "BRANCH-NORTH",
"categories": ["Pizzas", "Promotions"],
"images": ["https://example.com/pepperoni-pizza.jpg"],
"modifier_groups": [
{
"code": "drinks",
"name": "Choose your Drink",
"min_quantity": 1,
"max_quantity": 1,
"is_required": true,
"options": [
{ "code": "coca-1l", "name": "Coca Cola 1L", "price": 0 },
{ "code": "sprite-1l", "name": "Sprite 1L", "price": 0 },
{ "code": "fanta-1l", "name": "Fanta 1L", "price": 0.50 }
]
},
{
"code": "extras",
"name": "Extra Toppings",
"min_quantity": 0,
"max_quantity": 5,
"max_per_option": 2,
"is_required": false,
"options": [
{ "code": "extra-cheese", "name": "Extra Cheese", "price": 1.50 },
{ "code": "ham", "name": "Ham", "price": 2.00 },
{ "code": "olives", "name": "Olives", "price": 1.00 }
]
}
]
}
]
}'
{
"message": "Batch upsert process initiated successfully",
"count": 3,
"jobs": 3
}
resources accepts the following fields:
limited or unlimited.stock_type is limited.value (fixed amount) or percentage.Show Variation fields
[], all modifiers are deleted. If it has data, modifiers are completely replaced.Show Modifier group fields
Show Option fields
linked_product_id (UUID). If the SKU is not found, stored as null.curl -X POST "https://ecommerce.jelou.ai/api/v2/apps/{app_id}/batch/products/upsert_by_sku" \
-H "Authorization: Bearer <API_KEY>" \
-H "Content-Type: application/json" \
-d '{
"resources": [
{
"sku": "TSHIRT-BLU",
"name": "Basic Blue T-Shirt",
"description": "100% premium cotton t-shirt, regular fit",
"price": 29.99,
"has_tax": true,
"status": true,
"stock_type": "limited",
"stock": 150,
"product_url": "https://my-store.com/basic-blue-tshirt",
"discount_type": "percentage",
"discount": 10,
"branch": "BRANCH-DOWNTOWN",
"categories": ["Clothing", "T-Shirts"],
"images": [
"https://my-store.com/images/blue-tshirt-front.jpg",
"https://my-store.com/images/blue-tshirt-back.jpg"
],
"variations": [
{
"sku": "TSHIRT-BLU-S",
"price": 29.99,
"attributes": [
{ "name": "Size", "value": "S" },
{ "name": "Color", "value": "Blue" }
]
},
{
"sku": "TSHIRT-BLU-M",
"price": 29.99,
"attributes": [
{ "name": "Size", "value": "M" },
{ "name": "Color", "value": "Blue" }
]
},
{
"sku": "TSHIRT-BLU-L",
"price": 31.99,
"attributes": [
{ "name": "Size", "value": "L" },
{ "name": "Color", "value": "Blue" }
],
"images": [
"https://my-store.com/images/blue-tshirt-L.jpg"
]
}
]
},
{
"sku": "PANTS-BLK-M",
"name": "Black Pants",
"price": 49.99,
"branch": "BRANCH-NORTH",
"categories": ["Clothing", "Pants"]
},
{
"sku": "PIZZA-FAMILY",
"name": "Family Pepperoni Pizza",
"description": "Family-size pepperoni pizza with artisan crust",
"price": 18.99,
"stock_type": "unlimited",
"branch": "BRANCH-NORTH",
"categories": ["Pizzas", "Promotions"],
"images": ["https://example.com/pepperoni-pizza.jpg"],
"modifier_groups": [
{
"code": "drinks",
"name": "Choose your Drink",
"min_quantity": 1,
"max_quantity": 1,
"is_required": true,
"options": [
{ "code": "coca-1l", "name": "Coca Cola 1L", "price": 0 },
{ "code": "sprite-1l", "name": "Sprite 1L", "price": 0 },
{ "code": "fanta-1l", "name": "Fanta 1L", "price": 0.50 }
]
},
{
"code": "extras",
"name": "Extra Toppings",
"min_quantity": 0,
"max_quantity": 5,
"max_per_option": 2,
"is_required": false,
"options": [
{ "code": "extra-cheese", "name": "Extra Cheese", "price": 1.50 },
{ "code": "ham", "name": "Ham", "price": 2.00 },
{ "code": "olives", "name": "Olives", "price": 1.00 }
]
}
]
}
]
}'
{
"message": "Batch upsert process initiated successfully",
"count": 3,
"jobs": 3
}
{app_id} with your store ID and <API_KEY> with the token provided by Jelou.Asynchronous processing
202 Accepted immediately. Products are processed in the background.Non-existent branch
Automatic categories
Asynchronous images
Variations by SKU
Modifiers
modifier_groups is absent in the payload, existing modifiers are preserved. If it is an empty array [], all modifiers are deleted. If it has data, modifiers are completely replaced.422 and details the fields with errors.
{
"message": "The resources field is required.",
"errors": {
"resources": ["The resources field is required."]
}
}
Common error messages
| Field | Message |
|---|---|
resources | At least one product is required. |
resources | Cannot process more than 500 products at once. |
resources.*.sku | Each product must have a SKU. |
resources.*.name | Each product must have a name. |
resources.*.price | Each product must have a price. / Price cannot be negative. |
resources.*.stock_type | Stock type must be either limited or unlimited. |
resources.*.images.* | Each image must be a valid URL. |
resources.*.modifier_groups.*.code | Each modifier group must have a code. |
resources.*.modifier_groups.*.name | Each modifier group must have a name. |
resources.*.modifier_groups.*.options | Each modifier group must have at least one option. |
resources.*.modifier_groups.*.options.*.code | Each modifier option must have a code. |
resources.*.modifier_groups.*.options.*.name | Each modifier option must have a name. |
Was this page helpful?