Create / Edit products
POST {{fulfillment_client_url}}/client/product
Save the information of the products and its variants. If an id is provided, the information will edit the register with that Identifier.
The products information is saved by default when a receiving order is sended and processed, for see how to do this go to Receiving Orders section.
For save products without send a receiving order use this call.
Body definition
name | Type | Description | Required |
---|---|---|---|
id | Integer | If is provided, will edit the the information of this register instead of save a new one | false |
shopId | Integer | Identifier of the shop | false |
ecartId | Integer | Identifier of the ecart account | false |
sku | String | Identifier of the product inside the shop, for reference of the client | false |
name | String | Name of the product | true |
description | String | Description of the product | false |
currency | String | Currency that use the shop | true |
productType | String | type of the product | false |
price | Decimal | price of the product | true |
length | Decimal | length of the product | true |
width | Decimal | with of the product | true |
height | Decimal | height of the product | true |
weight | Decimal | weight of the product | true |
unitForSize | String | cm by default | false |
unitForWeight | String | kg by default | false |
imageUrl | String | image of the product | true |
variants | Array | The variants of this products that differ by single characteristics | true |
- Each variant is an object that includes the same fields of the main product, except for the shopId.
Request Body
{"0"=>{"shopId"=>1, "ecartId"=>"12345698", "sku"=>"abc123", "name"=>"product1", "description"=>"The Chicest Punk Piece Ever 🧷🧷 Our Favorite Earring.", "currency"=>"MXN", "productType"=>"clothes", "price"=>100, "length"=>10, "width"=>12, "height"=>12, "weight"=>10, "unitForSize"=>"cm", "unitForWeight"=>"kg", "imageUrl"=>"https://cdn.shopify.com/s/files/1/0251/8322/3882/products/CA3_0af03892-6911-4289-b19a-21df2b1da1c0.jpg?v=1571939435", "variants"=>[{"ecartId"=>"12345698", "sku"=>"abc123-1", "name"=>"product 1 red", "description"=>"The Chicest Punk Piece Ever 🧷🧷 Our Favorite Earring.r", "currency"=>"MXN", "price"=>120, "length"=>10, "width"=>12, "height"=>12, "weight"=>10, "unitForSize"=>"cm", "unitForWeight"=>"kg", "imageUrl"=>"https://cdn.shopify.com/s/files/1/0251/8322/3882/products/CA3_0af03892-6911-4289-b19a-21df2b1da1c0.jpg?v=1571939435"}, {"ecartId"=>"12345798", "sku"=>"abc123-2", "name"=>"product 1 blue", "description"=>"product 1 in blue color", "currency"=>"MXN", "price"=>100, "length"=>10, "width"=>12, "height"=>12, "weight"=>10, "unitForSize"=>"cm", "unitForWeight"=>"kg", "imageUrl"=>"https://cdn.shopify.com/s/files/1/0251/8322/3882/products/CA3_0af03892-6911-4289-b19a-21df2b1da1c0.jpg?v=1571939435"}]}}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string |