Skip to content
Permalink
master
Switch branches/tags
Go to file
 
 
Cannot retrieve contributors at this time
{"swagger":"2.0","info":{"title":"Akeneo PIM REST API","version":"1.0.0"},"host":"demo.akeneo.com","schemes":["http"],"produces":["application/json"],"paths":{"/api/rest/v1/products":{"get":{"summary":"Get list of products","operationId":"get_products","tags":["Product"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to get a list of products. Products are paginated and they can be filtered. In the Enterprise Edition, since the 2.0, permissions based on your user groups are applied to the set of products you request.","parameters":[{"name":"search","in":"query","description":"Filter products, for more details see the <a href=\"/documentation/filter.html\">Filters</a> section","required":false,"type":"string"},{"name":"scope","in":"query","type":"string","description":"Filter product values to return scopable attributes for the given channel as well as the non localizable/non scopable attributes, for more details see the <a href=\"/documentation/filter.html#via-channel\">Filter product values via channel</a> section","required":false},{"name":"locales","in":"query","type":"string","description":"Filter product values to return localizable attributes for the given locales as well as the non localizable/non scopable attributes, for more details see the <a href=\"/documentation/filter.html#via-locale\">Filter product values via locale</a> section","required":false},{"name":"attributes","in":"query","type":"string","description":"Filter product values to only return those concerning the given attributes, for more details see the <a href=\"/documentation/filter.html#filter-product-values\">Filter on product values</a> section","required":false},{"name":"pagination_type","in":"query","description":"Pagination method type, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"page","x-validation-rules":"One of the following values","enum":["page","search_after"]},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"search_after","in":"query","description":"Cursor when using the `search_after` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"cursor to the first page"},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false},{"name":"with_attribute_options","in":"query","description":"Return labels of attribute options in the response. (Only available since the 5.0 version)","default":false,"type":"boolean","required":false},{"name":"with_quality_scores","in":"query","description":"Return product quality scores in the response. (Only available since the 5.0 version)","default":false,"type":"boolean","required":false},{"name":"with_completenesses","in":"query","description":"Return product completenesses in the response. (Only available on SaaS platforms)","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return products paginated","schema":{"title":"Products","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["identifier"],"properties":{"identifier":{"type":"string","description":"Product identifier, i.e. the value of the only `pim_catalog_identifier` attribute"},"enabled":{"type":"boolean","description":"Whether the product is enabled","default":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements","x-validation-rules":"It is equal to an existing family code. In the case of variant product, the given family should be the same as the product model family.","default":"null only in the case of a non variant product"},"categories":{"type":"array","description":"Codes of the categories in which the product is classified","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"groups":{"type":"array","description":"Codes of the groups to which the product belong","x-validation-rules":"Each string of the array is equal to an existing group code","items":{"type":"string"},"default":[]},"parent":{"type":"string","description":"Code of the parent product model when the product is a variant (only available since the 2.0). This parent can be modified since the 2.3.","x-validation-rules":"It is equal to an existing product model code only if the product is variant otherwise it's equal to null","default":"null"},"values":{"type":"object","description":"Product attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"},"linked_data":{"type":"object","x-read-only":true,"description":"Object containing labels of attribute options (only available since the 5.0 and when query parameter \"with_attribute_options\" is set to \"true\"). See <a href='/concepts/products.html#the-linked_data-format'>the `linked_data` format</a> section for more details.","properties":{"attribute":{"type":"string"},"code":{"type":"string"},"labels":{"type":"object"}}}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product models and/or other products, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product (only available since the v2.0 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product regarding the user permissions (only available since the v2.0 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}},"quality_scores":{"type":"object","description":"Product quality scores for each channel/locale combination (only available since the 5.0 and when the \"with_quality_scores\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true},"completenesses":{"type":"object","description":"Product completenesses for each channel/locale combination (only available on SaaS platforms, and when the \"with_completenesses\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true}},"example":{"identifier":"top","enabled":true,"family":"tshirt","categories":["summer_collection"],"groups":[],"parent":null,"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black","linked_data":{"attribute":"color","code":"black","labels":{"en_US":"Black","fr_FR":"Noir"}}}],"size":[{"locale":null,"scope":null,"data":"m","linked_data":{"attribute":"size","code":"m","labels":{"en_US":"M","fr_FR":"M"}}}],"collection":[{"locale":null,"scope":null,"data":["winter_2016"],"linked_data":{"winter_2016":{"attribute":"collection","code":"winter_2016","labels":{"en_US":"Winter 2016","fr_FR":"Hiver 2016"}}}}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2},{"identifier":"shoes","quantity":1}],"product_models":[{"identifier":"model-biker-jacket-leather","quantity":2}]}},"quality_scores":[{"scope":"ecommerce","locale":"en_US","data":"A"},{"scope":"ecommerce","locale":"fr_FR","data":"B"},{"scope":"tablet","locale":"en_US","data":"D"},{"scope":"tablet","locale":"fr_FR","data":"E"}],"completenesses":[{"scope":"ecommerce","locale":"en_US","data":10},{"scope":"ecommerce","locale":"fr_FR","data":20},{"scope":"tablet","locale":"en_US","data":30},{"scope":"tablet","locale":"fr_FR","data":40}]}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/products?page=3&limit=3&with_quality_scores=true&with_completenesses=true&with_attribute_options=true"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/products?page=1&limit=3&with_quality_scores=true&with_completenesses=true&with_attribute_options=true"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/products?page=2&limit=3&with_quality_scores=true&with_completenesses=true&with_attribute_options=true"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/products?page=4&limit=3&with_quality_scores=true&with_completenesses=true&with_attribute_options=true"}},"current_page":3,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/product/top"}},"identifier":"top","family":"tshirt","groups":[],"parent":null,"categories":["summer_collection"],"enabled":true,"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black","linked_data":{"attribute":"color","code":"black","labels":{"en_US":"Black","fr_FR":"Noir"}}}],"size":[{"locale":null,"scope":null,"data":"m","linked_data":{"attribute":"size","code":"m","labels":{"en_US":"M","fr_FR":"M"}}}],"collection":[{"locale":null,"scope":null,"data":["winter_2016"],"linked_data":{"winter_2016":{"attribute":"collection","code":"winter_2016","labels":{"en_US":"Winter 2016","fr_FR":"Hiver 2016"}}}}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglasses"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2},{"identifier":"shoes","quantity":1}],"product_models":[{"identifier":"model-biker-jacket-leather","quantity":2}]}},"quality_scores":[{"scope":"ecommerce","locale":"en_US","data":"A"},{"scope":"ecommerce","locale":"fr_FR","data":"B"},{"scope":"tablet","locale":"en_US","data":"D"},{"scope":"tablet","locale":"fr_FR","data":"E"}],"completenesses":[{"scope":"ecommerce","locale":"en_US","data":20},{"scope":"ecommerce","locale":"fr_FR","data":30},{"scope":"tablet","locale":"en_US","data":55},{"scope":"tablet","locale":"fr_FR","data":70}]},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/product/cap"}},"identifier":"cap","family":"caps","groups":[],"parent":null,"categories":["summer_collection"],"enabled":true,"values":{"name":[{"data":"Cap","locale":"en_US","scope":null},{"data":"Casquette","locale":"fr_FR","scope":null}],"description":[{"data":"Cap unisex","locale":"en_US","scope":"ecommerce"},{"data":"Cap unisex","locale":"en_US","scope":"tablet"},{"data":"Casquette unisexe","locale":"fr_FR","scope":"ecommerce"},{"data":"Casquette unisexe","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"20","currency":"EUR"},{"amount":"20","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black","linked_data":{"attribute":"color","code":"black","labels":{"en_US":"Black","fr_FR":"Noir"}}}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglasses"],"product_models":[],"groups":[]}},"quantified_associations":{},"quality_scores":[{"scope":"ecommerce","locale":"en_US","data":"A"},{"scope":"ecommerce","locale":"fr_FR","data":"B"},{"scope":"tablet","locale":"en_US","data":"D"},{"scope":"tablet","locale":"fr_FR","data":"E"}],"completenesses":[{"scope":"ecommerce","locale":"en_US","data":20},{"scope":"ecommerce","locale":"fr_FR","data":30},{"scope":"tablet","locale":"en_US","data":55},{"scope":"tablet","locale":"fr_FR","data":70}]},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/product/sweat"}},"identifier":"sweat","family":null,"groups":[],"parent":null,"categories":["winter_collection"],"enabled":true,"values":{},"created":"2016-06-23T11:24:44+02:00","updated":"2016-06-23T11:24:44+02:00","associations":{},"quantified_associations":{},"quality_scores":{},"completenesses":{}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"post":{"summary":"Create a new product","operationId":"post_products","tags":["Product"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to create a new product. In the Enterprise Edition, since the v2.0, permissions based on your user groups are applied to the product you try to create.","parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["identifier"],"properties":{"identifier":{"type":"string","description":"Product identifier, i.e. the value of the only `pim_catalog_identifier` attribute"},"enabled":{"type":"boolean","description":"Whether the product is enabled","default":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements","x-validation-rules":"It is equal to an existing family code. In the case of variant product, the given family should be the same as the product model family.","default":"null only in the case of a non variant product"},"categories":{"type":"array","description":"Codes of the categories in which the product is classified","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"groups":{"type":"array","description":"Codes of the groups to which the product belong","x-validation-rules":"Each string of the array is equal to an existing group code","items":{"type":"string"},"default":[]},"parent":{"type":"string","description":"Code of the parent product model when the product is a variant (only available since the 2.0). This parent can be modified since the 2.3.","x-validation-rules":"It is equal to an existing product model code only if the product is variant otherwise it's equal to null","default":"null"},"values":{"type":"object","description":"Product attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"},"linked_data":{"type":"object","x-read-only":true,"description":"Object containing labels of attribute options (only available since the 5.0 and when query parameter \"with_attribute_options\" is set to \"true\"). See <a href='/concepts/products.html#the-linked_data-format'>the `linked_data` format</a> section for more details.","properties":{"attribute":{"type":"string"},"code":{"type":"string"},"labels":{"type":"object"}}}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product models and/or other products, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product (only available since the v2.0 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product regarding the user permissions (only available since the v2.0 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}},"quality_scores":{"type":"object","description":"Product quality scores for each channel/locale combination (only available since the 5.0 and when the \"with_quality_scores\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true},"completenesses":{"type":"object","description":"Product completenesses for each channel/locale combination (only available on SaaS platforms, and when the \"with_completenesses\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true}},"example":{"identifier":"top","enabled":true,"family":"tshirt","categories":["summer_collection"],"groups":[],"parent":null,"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black","linked_data":{"attribute":"color","code":"black","labels":{"en_US":"Black","fr_FR":"Noir"}}}],"size":[{"locale":null,"scope":null,"data":"m","linked_data":{"attribute":"size","code":"m","labels":{"en_US":"M","fr_FR":"M"}}}],"collection":[{"locale":null,"scope":null,"data":["winter_2016"],"linked_data":{"winter_2016":{"attribute":"collection","code":"winter_2016","labels":{"en_US":"Winter 2016","fr_FR":"Hiver 2016"}}}}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2},{"identifier":"shoes","quantity":1}],"product_models":[{"identifier":"model-biker-jacket-leather","quantity":2}]}},"quality_scores":[{"scope":"ecommerce","locale":"en_US","data":"A"},{"scope":"ecommerce","locale":"fr_FR","data":"B"},{"scope":"tablet","locale":"en_US","data":"D"},{"scope":"tablet","locale":"fr_FR","data":"E"}],"completenesses":[{"scope":"ecommerce","locale":"en_US","data":10},{"scope":"ecommerce","locale":"fr_FR","data":20},{"scope":"tablet","locale":"en_US","data":30},{"scope":"tablet","locale":"fr_FR","data":40}]}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several products","operationId":"patch_products","tags":["Product"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update and/or create several products at once. Learn more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no product exists for the given identifier, it creates it. In the Enterprise Edition, since the v2.0, permissions based on your user groups are applied to the products you try to update. It may result in the creation of drafts if you only have edit rights through the product's categories.","x-body-by-line":"Contains several lines, each line is a product in JSON standard format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"identifier\":\"cap\",\"values\":{\"description\":[{\"scope\":\"ecommerce\",\"locale\":\"en_US\",\"data\":\"My amazing cap\"}]}}","x-example-2":"{\"identifier\":\"mug\",\"group\":[\"promotion\"]}","x-example-3":"{\"identifier\":\"tshirt\",\"family\":\"clothes\"}"},"type":"object","required":["identifier"],"properties":{"identifier":{"type":"string","description":"Product identifier, i.e. the value of the only `pim_catalog_identifier` attribute"},"enabled":{"type":"boolean","description":"Whether the product is enabled","default":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements","x-validation-rules":"It is equal to an existing family code. In the case of variant product, the given family should be the same as the product model family.","default":"null only in the case of a non variant product"},"categories":{"type":"array","description":"Codes of the categories in which the product is classified","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"groups":{"type":"array","description":"Codes of the groups to which the product belong","x-validation-rules":"Each string of the array is equal to an existing group code","items":{"type":"string"},"default":[]},"parent":{"type":"string","description":"Code of the parent product model when the product is a variant (only available since the 2.0). This parent can be modified since the 2.3.","x-validation-rules":"It is equal to an existing product model code only if the product is variant otherwise it's equal to null","default":"null"},"values":{"type":"object","description":"Product attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"},"linked_data":{"type":"object","x-read-only":true,"description":"Object containing labels of attribute options (only available since the 5.0 and when query parameter \"with_attribute_options\" is set to \"true\"). See <a href='/concepts/products.html#the-linked_data-format'>the `linked_data` format</a> section for more details.","properties":{"attribute":{"type":"string"},"code":{"type":"string"},"labels":{"type":"object"}}}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product models and/or other products, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product (only available since the v2.0 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product regarding the user permissions (only available since the v2.0 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}},"quality_scores":{"type":"object","description":"Product quality scores for each channel/locale combination (only available since the 5.0 and when the \"with_quality_scores\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true},"completenesses":{"type":"object","description":"Product completenesses for each channel/locale combination (only available on SaaS platforms, and when the \"with_completenesses\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true}},"example":{"identifier":"top","enabled":true,"family":"tshirt","categories":["summer_collection"],"groups":[],"parent":null,"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black","linked_data":{"attribute":"color","code":"black","labels":{"en_US":"Black","fr_FR":"Noir"}}}],"size":[{"locale":null,"scope":null,"data":"m","linked_data":{"attribute":"size","code":"m","labels":{"en_US":"M","fr_FR":"M"}}}],"collection":[{"locale":null,"scope":null,"data":["winter_2016"],"linked_data":{"winter_2016":{"attribute":"collection","code":"winter_2016","labels":{"en_US":"Winter 2016","fr_FR":"Hiver 2016"}}}}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2},{"identifier":"shoes","quantity":1}],"product_models":[{"identifier":"model-biker-jacket-leather","quantity":2}]}},"quality_scores":[{"scope":"ecommerce","locale":"en_US","data":"A"},{"scope":"ecommerce","locale":"fr_FR","data":"B"},{"scope":"tablet","locale":"en_US","data":"D"},{"scope":"tablet","locale":"fr_FR","data":"E"}],"completenesses":[{"scope":"ecommerce","locale":"en_US","data":10},{"scope":"ecommerce","locale":"fr_FR","data":20},{"scope":"tablet","locale":"en_US","data":30},{"scope":"tablet","locale":"fr_FR","data":40}]}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"identifier\":\"cap\",\"status_code\":204}","x-example-2":"{\"line\":2,\"identifier\":\"mug\",\"status_code\":422,\"message\":\"Property \"group\" does not exist.\"}","x-example-3":"{\"line\":3,\"identifier\":\"tshirt\",\"status_code\":201}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/products/{code}":{"get":{"summary":"Get a product","operationId":"get_products__code_","tags":["Product"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to get the information about a given product. In the Entreprise Edition, since the v2.0, permissions based on your user groups are applied to the product you request.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"with_attribute_options","in":"query","description":"Return labels of attribute options in the response. (Only available since the 5.0 version)","default":false,"type":"boolean","required":false},{"name":"with_quality_scores","in":"query","description":"Return product quality scores in the response. (Only available since the 5.0 version)","default":false,"type":"boolean","required":false},{"name":"with_completenesses","in":"query","description":"Return product completenesses in the response. (Only available on SaaS platforms)","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the product in JSON standard format","schema":{"type":"object","required":["identifier"],"properties":{"identifier":{"type":"string","description":"Product identifier, i.e. the value of the only `pim_catalog_identifier` attribute"},"enabled":{"type":"boolean","description":"Whether the product is enabled","default":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements","x-validation-rules":"It is equal to an existing family code. In the case of variant product, the given family should be the same as the product model family.","default":"null only in the case of a non variant product"},"categories":{"type":"array","description":"Codes of the categories in which the product is classified","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"groups":{"type":"array","description":"Codes of the groups to which the product belong","x-validation-rules":"Each string of the array is equal to an existing group code","items":{"type":"string"},"default":[]},"parent":{"type":"string","description":"Code of the parent product model when the product is a variant (only available since the 2.0). This parent can be modified since the 2.3.","x-validation-rules":"It is equal to an existing product model code only if the product is variant otherwise it's equal to null","default":"null"},"values":{"type":"object","description":"Product attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"},"linked_data":{"type":"object","x-read-only":true,"description":"Object containing labels of attribute options (only available since the 5.0 and when query parameter \"with_attribute_options\" is set to \"true\"). See <a href='/concepts/products.html#the-linked_data-format'>the `linked_data` format</a> section for more details.","properties":{"attribute":{"type":"string"},"code":{"type":"string"},"labels":{"type":"object"}}}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product models and/or other products, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product (only available since the v2.0 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product regarding the user permissions (only available since the v2.0 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}},"quality_scores":{"type":"object","description":"Product quality scores for each channel/locale combination (only available since the 5.0 and when the \"with_quality_scores\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true},"completenesses":{"type":"object","description":"Product completenesses for each channel/locale combination (only available on SaaS platforms, and when the \"with_completenesses\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true}},"example":{"identifier":"top","enabled":true,"family":"tshirt","categories":["summer_collection"],"groups":[],"parent":null,"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black","linked_data":{"attribute":"color","code":"black","labels":{"en_US":"Black","fr_FR":"Noir"}}}],"size":[{"locale":null,"scope":null,"data":"m","linked_data":{"attribute":"size","code":"m","labels":{"en_US":"M","fr_FR":"M"}}}],"collection":[{"locale":null,"scope":null,"data":["winter_2016"],"linked_data":{"winter_2016":{"attribute":"collection","code":"winter_2016","labels":{"en_US":"Winter 2016","fr_FR":"Hiver 2016"}}}}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2},{"identifier":"shoes","quantity":1}],"product_models":[{"identifier":"model-biker-jacket-leather","quantity":2}]}},"quality_scores":[{"scope":"ecommerce","locale":"en_US","data":"A"},{"scope":"ecommerce","locale":"fr_FR","data":"B"},{"scope":"tablet","locale":"en_US","data":"D"},{"scope":"tablet","locale":"fr_FR","data":"E"}],"completenesses":[{"scope":"ecommerce","locale":"en_US","data":10},{"scope":"ecommerce","locale":"fr_FR","data":20},{"scope":"tablet","locale":"en_US","data":30},{"scope":"tablet","locale":"fr_FR","data":40}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a product","operationId":"patch_products__code_","tags":["Product"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given product. Learn more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no product exists for the given identifier, it creates it. In the Entreprise Edition, since the v2.0, permissions based on your user groups are applied to the product you try to update. It may result in the creation of a draft if you only have edit rights through the product's categories.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["identifier"],"properties":{"identifier":{"type":"string","description":"Product identifier, i.e. the value of the only `pim_catalog_identifier` attribute"},"enabled":{"type":"boolean","description":"Whether the product is enabled","default":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements","x-validation-rules":"It is equal to an existing family code. In the case of variant product, the given family should be the same as the product model family.","default":"null only in the case of a non variant product"},"categories":{"type":"array","description":"Codes of the categories in which the product is classified","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"groups":{"type":"array","description":"Codes of the groups to which the product belong","x-validation-rules":"Each string of the array is equal to an existing group code","items":{"type":"string"},"default":[]},"parent":{"type":"string","description":"Code of the parent product model when the product is a variant (only available since the 2.0). This parent can be modified since the 2.3.","x-validation-rules":"It is equal to an existing product model code only if the product is variant otherwise it's equal to null","default":"null"},"values":{"type":"object","description":"Product attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"},"linked_data":{"type":"object","x-read-only":true,"description":"Object containing labels of attribute options (only available since the 5.0 and when query parameter \"with_attribute_options\" is set to \"true\"). See <a href='/concepts/products.html#the-linked_data-format'>the `linked_data` format</a> section for more details.","properties":{"attribute":{"type":"string"},"code":{"type":"string"},"labels":{"type":"object"}}}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product models and/or other products, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product (only available since the v2.0 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product regarding the user permissions (only available since the v2.0 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}},"quality_scores":{"type":"object","description":"Product quality scores for each channel/locale combination (only available since the 5.0 and when the \"with_quality_scores\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true},"completenesses":{"type":"object","description":"Product completenesses for each channel/locale combination (only available on SaaS platforms, and when the \"with_completenesses\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true}},"example":{"identifier":"top","enabled":true,"family":"tshirt","categories":["summer_collection"],"groups":[],"parent":null,"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black","linked_data":{"attribute":"color","code":"black","labels":{"en_US":"Black","fr_FR":"Noir"}}}],"size":[{"locale":null,"scope":null,"data":"m","linked_data":{"attribute":"size","code":"m","labels":{"en_US":"M","fr_FR":"M"}}}],"collection":[{"locale":null,"scope":null,"data":["winter_2016"],"linked_data":{"winter_2016":{"attribute":"collection","code":"winter_2016","labels":{"en_US":"Winter 2016","fr_FR":"Hiver 2016"}}}}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2},{"identifier":"shoes","quantity":1}],"product_models":[{"identifier":"model-biker-jacket-leather","quantity":2}]}},"quality_scores":[{"scope":"ecommerce","locale":"en_US","data":"A"},{"scope":"ecommerce","locale":"fr_FR","data":"B"},{"scope":"tablet","locale":"en_US","data":"D"},{"scope":"tablet","locale":"fr_FR","data":"E"}],"completenesses":[{"scope":"ecommerce","locale":"en_US","data":10},{"scope":"ecommerce","locale":"fr_FR","data":20},{"scope":"tablet","locale":"en_US","data":30},{"scope":"tablet","locale":"fr_FR","data":40}]}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"delete":{"summary":"Delete a product","operationId":"delete_products__code_","tags":["Product"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to delete a given product. In the Enterprise Edition, since the 2.0, permissions based on your user groups are applied to the product you try to delete.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"204":{"description":"No content to return","x-details":"Means that the deletion was successful"},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}}}}},"/api/rest/v1/products/{code}/proposal":{"post":{"summary":"Submit a draft for approval","operationId":"post_proposal","tags":["Product"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to submit a draft for approval.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"201":{"description":"Submitted","x-details":"Means that the draft submission was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/products/{code}/draft":{"get":{"summary":"Get a draft","operationId":"get_draft__code_","tags":["Product"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given draft.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the draft in JSON standard format","schema":{"type":"object","required":["identifier"],"properties":{"identifier":{"type":"string","description":"Product identifier, i.e. the value of the only `pim_catalog_identifier` attribute"},"enabled":{"type":"boolean","description":"Whether the product is enabled","default":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements","x-validation-rules":"It is equal to an existing family code. In the case of variant product, the given family should be the same as the product model family.","default":"null only in the case of a non variant product"},"categories":{"type":"array","description":"Codes of the categories in which the product is classified","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"groups":{"type":"array","description":"Codes of the groups to which the product belong","x-validation-rules":"Each string of the array is equal to an existing group code","items":{"type":"string"},"default":[]},"parent":{"type":"string","description":"Code of the parent product model when the product is a variant (only available since the 2.0). This parent can be modified since the 2.3.","x-validation-rules":"It is equal to an existing product model code only if the product is variant otherwise it's equal to null","default":"null"},"values":{"type":"object","description":"Product attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"},"linked_data":{"type":"object","x-read-only":true,"description":"Object containing labels of attribute options (only available since the 5.0 and when query parameter \"with_attribute_options\" is set to \"true\"). See <a href='/concepts/products.html#the-linked_data-format'>the `linked_data` format</a> section for more details.","properties":{"attribute":{"type":"string"},"code":{"type":"string"},"labels":{"type":"object"}}}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product models and/or other products, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product (only available since the v2.0 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product regarding the user permissions (only available since the v2.0 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}},"quality_scores":{"type":"object","description":"Product quality scores for each channel/locale combination (only available since the 5.0 and when the \"with_quality_scores\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true},"completenesses":{"type":"object","description":"Product completenesses for each channel/locale combination (only available on SaaS platforms, and when the \"with_completenesses\" query parameter is set to \"true\")","x-immutable":true,"x-read-only":true}},"example":{"identifier":"top","enabled":true,"family":"tshirt","categories":["summer_collection"],"groups":[],"parent":null,"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black","linked_data":{"attribute":"color","code":"black","labels":{"en_US":"Black","fr_FR":"Noir"}}}],"size":[{"locale":null,"scope":null,"data":"m","linked_data":{"attribute":"size","code":"m","labels":{"en_US":"M","fr_FR":"M"}}}],"collection":[{"locale":null,"scope":null,"data":["winter_2016"],"linked_data":{"winter_2016":{"attribute":"collection","code":"winter_2016","labels":{"en_US":"Winter 2016","fr_FR":"Hiver 2016"}}}}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2},{"identifier":"shoes","quantity":1}],"product_models":[{"identifier":"model-biker-jacket-leather","quantity":2}]}},"quality_scores":[{"scope":"ecommerce","locale":"en_US","data":"A"},{"scope":"ecommerce","locale":"fr_FR","data":"B"},{"scope":"tablet","locale":"en_US","data":"D"},{"scope":"tablet","locale":"fr_FR","data":"E"}],"completenesses":[{"scope":"ecommerce","locale":"en_US","data":10},{"scope":"ecommerce","locale":"fr_FR","data":20},{"scope":"tablet","locale":"en_US","data":30},{"scope":"tablet","locale":"fr_FR","data":40}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/product-models":{"get":{"summary":"Get list of product models","operationId":"get_product_models","tags":["Product model"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to get a list of product models. Product models are paginated. In the Enterprise Edition, since the 2.0, permissions based on your user groups are applied to the set of products you request.","parameters":[{"name":"search","in":"query","description":"Filter product models, for more details see the <a href=\"/documentation/filter.html\">Filters</a> section","required":false,"type":"string"},{"name":"scope","in":"query","type":"string","description":"Filter product values to return scopable attributes for the given channel as well as the non localizable/non scopable attributes, for more details see the <a href=\"/documentation/filter.html#via-channel\">Filter product values via channel</a> section","required":false},{"name":"locales","in":"query","type":"string","description":"Filter product values to return localizable attributes for the given locales as well as the non localizable/non scopable attributes, for more details see the <a href=\"/documentation/filter.html#via-locale\">Filter product values via locale</a> section","required":false},{"name":"attributes","in":"query","type":"string","description":"Filter product values to only return those concerning the given attributes, for more details see the <a href=\"/documentation/filter.html#filter-product-values\">Filter on product values</a> section and the <a href=\"/documentation/filter.html#filter-on-product-model-properties\">Filter on product model properties</a> section","required":false},{"name":"pagination_type","in":"query","description":"Pagination method type, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"page","x-validation-rules":"One of the following values","enum":["page","search_after"]},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"search_after","in":"query","description":"Cursor when using the `search_after` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"cursor to the first page"},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return product models paginated","schema":{"title":"Product Models","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code","family_variant"],"properties":{"code":{"type":"string","description":"Product model code","x-immutable":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements (since the 3.2)","x-validation-rules":"It is equal to an existing family code","x-immutable":true},"family_variant":{"type":"string","description":"Family variant code from which the product model inherits its attributes and variant attributes","x-validation-rules":"It is equal to an existing family variant code that belong to the family given in the `family` field","x-immutable":true},"parent":{"type":"string","description":"Code of the parent product model. This parent can be modified since the 2.3.","x-validation-rules":"&bull; It is equal to an existing product model code&#10;&bull; This product model has the same family variant as the one given in the `family_variant field`","default":"null"},"categories":{"type":"array","description":"Codes of the categories in which the product model is categorized","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"values":{"type":"object","description":"Product model attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product and/or other product models, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it. &#10;&bull; Each object in the array of the property `product_models` contains the code of an existing product model and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product model is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product model is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product model (only available since the v2.3 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product model regarding the user permissions (only available since the v2.3 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}}},"example":{"code":"model-biker-jacket-leather","family":"clothing","family_variant":"clothing_material_size","parent":"model-biker-jacket","categories":["summer_collection"],"values":{"color":[{"locale":null,"scope":null,"data":"antique_white"}],"material":[{"locale":null,"scope":null,"data":"leather"}],"variation_name":[{"locale":"en_US","scope":null,"data":"Biker jacket leather"}],"name":[{"locale":"en_US","scope":null,"data":"Biker jacket"}],"collection":[{"locale":null,"scope":null,"data":["summer_2017"]}],"description":[{"locale":"en_US","scope":"ecommerce","data":"Biker jacket"}]},"associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"top","quantity":2},{"identifier":"cap","quantity":1}],"product_models":[{"code":"model-biker-jacket-leather","quantity":2}]}},"created":"2017-10-02T15:03:55+02:00","updated":"2017-10-02T15:03:55+02:00"}}]}}}}}}]},"examples":{"_links":{"self":{"href":"http://demo.akeneo.com/api/rest/v1/product-models?pagination_type=search_after&limit=3&search_after=qg%3D%3D"},"first":{"href":"http://demo.akeneo.com/api/rest/v1/product-models?pagination_type=search_after&limit=3"},"next":{"href":"http://demo.akeneo.com/api/rest/v1/product-models?pagination_type=search_after&limit=3&search_after=rw%3D%3D"}},"_embedded":{"items":[{"_links":{"self":{"href":"http://demo.akeneo.com/api/rest/v1/product-models/amarisshoe"}},"code":"amarisshoe","family":"shoes","family_variant":"shoes_VariantA1","parent":null,"categories":["clothing","shoes"],"values":{"price":[{"locale":null,"scope":null,"data":[{"amount":"50.00","currency":"EUR"}]}],"description":[{"locale":"en_US","scope":"ecommerce","data":"I like shoes!"}]},"associations":{"PACK":{"products":["sunglasses"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2},{"identifier":"shoes","quantity":1}],"product_models":[{"identifier":"model-biker-jacket-leather","quantity":2}]}},"created":"2017-10-04T18:04:10+02:00","updated":"2017-10-04T18:04:10+02:00"},{"_links":{"self":{"href":"http://demo.akeneo.com/api/rest/v1/product-models/Abiloitshirt"}},"code":"Abiloitshirt","family":"clothing","family_variant":"clothing_VariantA1","parent":null,"categories":["clothing","tshirt"],"values":{"price":[{"locale":null,"scope":null,"data":[{"amount":"50.00","currency":"EUR"}]}],"description":[{"locale":"en_US","scope":"ecommerce","data":"I like tshirt!"}]},"associations":{"PACK":{"products":["sunglasses"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"cap","quantity":2}],"product_models":[]}},"created":"2017-10-04T18:04:10+02:00","updated":"2017-10-04T18:04:10+02:00"},{"_links":{"self":{"href":"http://demo.akeneo.com/api/rest/v1/product-models/Astertrousers"}},"code":"Astertrousers","family":"clothing","family_variant":"clothing_VariantA1","parent":null,"categories":["clothing","trousers"],"values":{"price":[{"locale":null,"scope":null,"data":[{"amount":"50.00","currency":"EUR"}]}],"associations":{"PACK":{"products":["sunglasses"],"product_models":[],"groups":[]}},"quantified_associations":{},"description":[{"locale":"en_US","scope":"ecommerce","data":"I like trousers!"}]},"created":"2017-10-04T18:04:10+02:00","updated":"2017-10-04T18:04:10+02:00"}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"post":{"summary":"Create a new product model","operationId":"post_product_models","tags":["Product model"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to create a new product model. In the Enterprise Edition, since the v2.3, permissions based on your user groups are applied to the product model you try to create.","parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["code","family_variant"],"properties":{"code":{"type":"string","description":"Product model code","x-immutable":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements (since the 3.2)","x-validation-rules":"It is equal to an existing family code","x-immutable":true},"family_variant":{"type":"string","description":"Family variant code from which the product model inherits its attributes and variant attributes","x-validation-rules":"It is equal to an existing family variant code that belong to the family given in the `family` field","x-immutable":true},"parent":{"type":"string","description":"Code of the parent product model. This parent can be modified since the 2.3.","x-validation-rules":"&bull; It is equal to an existing product model code&#10;&bull; This product model has the same family variant as the one given in the `family_variant field`","default":"null"},"categories":{"type":"array","description":"Codes of the categories in which the product model is categorized","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"values":{"type":"object","description":"Product model attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product and/or other product models, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it. &#10;&bull; Each object in the array of the property `product_models` contains the code of an existing product model and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product model is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product model is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product model (only available since the v2.3 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product model regarding the user permissions (only available since the v2.3 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}}},"example":{"code":"model-biker-jacket-leather","family":"clothing","family_variant":"clothing_material_size","parent":"model-biker-jacket","categories":["summer_collection"],"values":{"color":[{"locale":null,"scope":null,"data":"antique_white"}],"material":[{"locale":null,"scope":null,"data":"leather"}],"variation_name":[{"locale":"en_US","scope":null,"data":"Biker jacket leather"}],"name":[{"locale":"en_US","scope":null,"data":"Biker jacket"}],"collection":[{"locale":null,"scope":null,"data":["summer_2017"]}],"description":[{"locale":"en_US","scope":"ecommerce","data":"Biker jacket"}]},"associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"top","quantity":2},{"identifier":"cap","quantity":1}],"product_models":[{"code":"model-biker-jacket-leather","quantity":2}]}},"created":"2017-10-02T15:03:55+02:00","updated":"2017-10-02T15:03:55+02:00"}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several product models","operationId":"patch_product_models","tags":["Product model"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update and/or create several product models at once. Learn more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no product models exists for the given code, it creates it. In the Enterprise Edition, since the v2.3, permissions based on your user groups are applied to the product models you try to update. It may result in the creation of drafts if you only have edit rights through the product model's categories.","x-body-by-line":"Contains several lines, each line is a product model in JSON standard format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\": \"sub_sweat_option_a\", \"parent\": \"sweat\", \"values\": {\"a_simple_select\": [{\"locale\": null, \"scope\": null, \"data\": \"optionA\"}]}}","x-example-2":"{\"code\": \"sub_sweat_option_b\", \"parent\": \"sweat\", \"values\": {\"a_simple_select\": [{\"locale\": null, \"scope\": null, \"data\": \"optionA\"}]}}","x-example-3":"{\"code\":\"tshirt\", \"parent\": \"root_tshirt\", \"family_variant\":\"clothesvariant\",\"values\":{\"description\":[{\"scope\":\"ecommerce\",\"locale\":\"en_US\",\"data\":\"My amazing tshirt\"}]}}"},"type":"object","required":["code","family_variant"],"properties":{"code":{"type":"string","description":"Product model code","x-immutable":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements (since the 3.2)","x-validation-rules":"It is equal to an existing family code","x-immutable":true},"family_variant":{"type":"string","description":"Family variant code from which the product model inherits its attributes and variant attributes","x-validation-rules":"It is equal to an existing family variant code that belong to the family given in the `family` field","x-immutable":true},"parent":{"type":"string","description":"Code of the parent product model. This parent can be modified since the 2.3.","x-validation-rules":"&bull; It is equal to an existing product model code&#10;&bull; This product model has the same family variant as the one given in the `family_variant field`","default":"null"},"categories":{"type":"array","description":"Codes of the categories in which the product model is categorized","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"values":{"type":"object","description":"Product model attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product and/or other product models, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it. &#10;&bull; Each object in the array of the property `product_models` contains the code of an existing product model and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product model is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product model is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product model (only available since the v2.3 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product model regarding the user permissions (only available since the v2.3 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}}},"example":{"code":"model-biker-jacket-leather","family":"clothing","family_variant":"clothing_material_size","parent":"model-biker-jacket","categories":["summer_collection"],"values":{"color":[{"locale":null,"scope":null,"data":"antique_white"}],"material":[{"locale":null,"scope":null,"data":"leather"}],"variation_name":[{"locale":"en_US","scope":null,"data":"Biker jacket leather"}],"name":[{"locale":"en_US","scope":null,"data":"Biker jacket"}],"collection":[{"locale":null,"scope":null,"data":["summer_2017"]}],"description":[{"locale":"en_US","scope":"ecommerce","data":"Biker jacket"}]},"associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"top","quantity":2},{"identifier":"cap","quantity":1}],"product_models":[{"code":"model-biker-jacket-leather","quantity":2}]}},"created":"2017-10-02T15:03:55+02:00","updated":"2017-10-02T15:03:55+02:00"}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"sub_sweat_option_a\",\"status_code\":204}","x-example-2":"{\"line\":2,\"code\":\"sub_sweat_option_b\",\"status_code\":422,\"message\":\"Validation failed.\",\"errors\":[{\"property\":\"attribute\",\"message\":\"Cannot set value \\\"Option A\\\" for the attribute axis \\\"a_simple_select\\\", as another sibling entity already has this value\"}]}","x-example-3":"{\"line\":3,\"code\":\"tshirt\",\"status_code\":201}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/product-models/{code}":{"get":{"summary":"Get a product model","operationId":"get_product_models__code_","tags":["Product model"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to get the information about a given product model. In the Entreprise Edition, since the v2.0, permissions based on your user groups are applied to the product model you request.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the product model in JSON standard format.","schema":{"type":"object","required":["code","family_variant"],"properties":{"code":{"type":"string","description":"Product model code","x-immutable":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements (since the 3.2)","x-validation-rules":"It is equal to an existing family code","x-immutable":true},"family_variant":{"type":"string","description":"Family variant code from which the product model inherits its attributes and variant attributes","x-validation-rules":"It is equal to an existing family variant code that belong to the family given in the `family` field","x-immutable":true},"parent":{"type":"string","description":"Code of the parent product model. This parent can be modified since the 2.3.","x-validation-rules":"&bull; It is equal to an existing product model code&#10;&bull; This product model has the same family variant as the one given in the `family_variant field`","default":"null"},"categories":{"type":"array","description":"Codes of the categories in which the product model is categorized","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"values":{"type":"object","description":"Product model attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product and/or other product models, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it. &#10;&bull; Each object in the array of the property `product_models` contains the code of an existing product model and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product model is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product model is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product model (only available since the v2.3 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product model regarding the user permissions (only available since the v2.3 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}}},"example":{"code":"model-biker-jacket-leather","family":"clothing","family_variant":"clothing_material_size","parent":"model-biker-jacket","categories":["summer_collection"],"values":{"color":[{"locale":null,"scope":null,"data":"antique_white"}],"material":[{"locale":null,"scope":null,"data":"leather"}],"variation_name":[{"locale":"en_US","scope":null,"data":"Biker jacket leather"}],"name":[{"locale":"en_US","scope":null,"data":"Biker jacket"}],"collection":[{"locale":null,"scope":null,"data":["summer_2017"]}],"description":[{"locale":"en_US","scope":"ecommerce","data":"Biker jacket"}]},"associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"top","quantity":2},{"identifier":"cap","quantity":1}],"product_models":[{"code":"model-biker-jacket-leather","quantity":2}]}},"created":"2017-10-02T15:03:55+02:00","updated":"2017-10-02T15:03:55+02:00"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a product model","operationId":"patch_product_models__code_","tags":["Product model"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given product model. Learn more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no product model exists for the given code, it creates it. In the Enterprise Edition PIM since the 2.3, permissions based on your user groups are applied to the product model you try to update. It may result in the creation of a draft if you only have edit rights through the product model's categories.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code","family_variant"],"properties":{"code":{"type":"string","description":"Product model code","x-immutable":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements (since the 3.2)","x-validation-rules":"It is equal to an existing family code","x-immutable":true},"family_variant":{"type":"string","description":"Family variant code from which the product model inherits its attributes and variant attributes","x-validation-rules":"It is equal to an existing family variant code that belong to the family given in the `family` field","x-immutable":true},"parent":{"type":"string","description":"Code of the parent product model. This parent can be modified since the 2.3.","x-validation-rules":"&bull; It is equal to an existing product model code&#10;&bull; This product model has the same family variant as the one given in the `family_variant field`","default":"null"},"categories":{"type":"array","description":"Codes of the categories in which the product model is categorized","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"values":{"type":"object","description":"Product model attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product and/or other product models, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it. &#10;&bull; Each object in the array of the property `product_models` contains the code of an existing product model and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product model is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product model is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product model (only available since the v2.3 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product model regarding the user permissions (only available since the v2.3 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}}},"example":{"code":"model-biker-jacket-leather","family":"clothing","family_variant":"clothing_material_size","parent":"model-biker-jacket","categories":["summer_collection"],"values":{"color":[{"locale":null,"scope":null,"data":"antique_white"}],"material":[{"locale":null,"scope":null,"data":"leather"}],"variation_name":[{"locale":"en_US","scope":null,"data":"Biker jacket leather"}],"name":[{"locale":"en_US","scope":null,"data":"Biker jacket"}],"collection":[{"locale":null,"scope":null,"data":["summer_2017"]}],"description":[{"locale":"en_US","scope":"ecommerce","data":"Biker jacket"}]},"associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"top","quantity":2},{"identifier":"cap","quantity":1}],"product_models":[{"code":"model-biker-jacket-leather","quantity":2}]}},"created":"2017-10-02T15:03:55+02:00","updated":"2017-10-02T15:03:55+02:00"}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/product-models/{code}/proposal":{"post":{"summary":"Submit a draft for approval","operationId":"post_product_model_proposal","tags":["Product model"],"x-versions":["2.3","3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to submit a product model draft for approval.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"201":{"description":"Submitted","x-details":"Means that the draft submission was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/product-models/{code}/draft":{"get":{"summary":"Get a draft","operationId":"get_product_model_draft__code_","tags":["Product model"],"x-versions":["2.3","3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given product model draft.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the draft in JSON standard format","schema":{"type":"object","required":["code","family_variant"],"properties":{"code":{"type":"string","description":"Product model code","x-immutable":true},"family":{"type":"string","description":"Family code from which the product inherits its attributes and attributes requirements (since the 3.2)","x-validation-rules":"It is equal to an existing family code","x-immutable":true},"family_variant":{"type":"string","description":"Family variant code from which the product model inherits its attributes and variant attributes","x-validation-rules":"It is equal to an existing family variant code that belong to the family given in the `family` field","x-immutable":true},"parent":{"type":"string","description":"Code of the parent product model. This parent can be modified since the 2.3.","x-validation-rules":"&bull; It is equal to an existing product model code&#10;&bull; This product model has the same family variant as the one given in the `family_variant field`","default":"null"},"categories":{"type":"array","description":"Codes of the categories in which the product model is categorized","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"values":{"type":"object","description":"Product model attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"}}}}}},"associations":{"type":"object","description":"Several associations related to groups, product and/or other product models, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Each string in the array of the property `product_models` is the code of an existing product model.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of product identifiers with which the product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Several quantified associations related to products and/or product models, grouped by quantified association types (only available since the 5.0)","x-validation-rules":"&bull; The `quantifiedAssociationTypeCode` is the code of an existing association type which provides quantity information. &#10;&bull; Each object in the array of the property `products` contains the identifier of an existing product and the quantity of it. &#10;&bull; Each object in the array of the property `product_models` contains the code of an existing product model and the quantity of it.","properties":{"quantifiedAssociationTypeCode":{"type":"object","properties":{"products":{"type":"array","description":"Array of objects containing product identifiers and quantities with which the product model is in relation","items":{"type":"object","properties":{"identifier":{"type":"string"},"quantity":{"type":"integer"}}}},"product_models":{"type":"array","description":"Array of objects containing product model codes and quantities with which the product model is in relation","items":{"type":"object","properties":{"code":{"type":"string"},"quantity":{"type":"integer"}}}}}}}},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"metadata":{"type":"object","description":"More information around the product model (only available since the v2.3 in the Enterprise Edition)","x-immutable":true,"x-read-only":true,"properties":{"workflow_status":{"description":"Status of the product model regarding the user permissions (only available since the v2.3 in the Enterprise Edition)","type":"string","enum":["read_only","draft_in_progress","proposal_waiting_for_approval","working_copy"]}}}},"example":{"code":"model-biker-jacket-leather","family":"clothing","family_variant":"clothing_material_size","parent":"model-biker-jacket","categories":["summer_collection"],"values":{"color":[{"locale":null,"scope":null,"data":"antique_white"}],"material":[{"locale":null,"scope":null,"data":"leather"}],"variation_name":[{"locale":"en_US","scope":null,"data":"Biker jacket leather"}],"name":[{"locale":"en_US","scope":null,"data":"Biker jacket"}],"collection":[{"locale":null,"scope":null,"data":["summer_2017"]}],"description":[{"locale":"en_US","scope":"ecommerce","data":"Biker jacket"}]},"associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}},"quantified_associations":{"PRODUCT_SET":{"products":[{"identifier":"top","quantity":2},{"identifier":"cap","quantity":1}],"product_models":[{"code":"model-biker-jacket-leather","quantity":2}]}},"created":"2017-10-02T15:03:55+02:00","updated":"2017-10-02T15:03:55+02:00"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/published-products":{"get":{"summary":"Get list of published products","operationId":"get_published_products","description":"This endpoint allows you to get a list of published products. Published products are paginated and they can be filtered.","tags":["Published product"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"search","in":"query","description":"Filter published products, for more details see the <a href=\"/documentation/filter.html\">Filters</a> section","required":false,"type":"string"},{"name":"scope","in":"query","type":"string","description":"Filter published product values to return scopable attributes for the given channel as well as the non localizable/non scopable attributes, for more details see the <a href=\"/documentation/filter.html#filter-product-values\">Filter on published product values</a> section","required":false},{"name":"locales","in":"query","type":"string","description":"Filter published product values to return localizable attributes for the given locales as well as the non localizable/non scopable attributes, for more details see the <a href=\"/documentation/filter.html#filter-product-values\">Filter on published product values</a> section","required":false},{"name":"attributes","in":"query","type":"string","description":"Filter published product values to only return those concerning the given attributes, for more details see the <a href=\"/documentation/filter.html#filter-product-values\">Filter on product values</a> section","required":false},{"name":"pagination_type","in":"query","description":"Pagination method type, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"page","x-validation-rules":"One of the following values","enum":["page","search_after"]},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"search_after","in":"query","description":"Cursor when using the `search_after` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"cursor to the first page"},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return published products paginated","schema":{"title":"Products","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["identifier"],"properties":{"identifier":{"type":"string","description":"Published product identifier, i.e. the value of the only `pim_catalog_identifier` attribute"},"enabled":{"type":"boolean","description":"Whether the published product is enable","default":true},"family":{"type":"string","description":"Family code from which the published product inherits its attributes and attributes requirements","x-validation-rules":"It is equal to an existing family code","default":"null"},"categories":{"type":"array","description":"Codes of the categories in which the published product is classified","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"groups":{"type":"array","description":"Codes of the groups to which the published product belong","x-validation-rules":"Each string of the array is equal to an existing group code","items":{"type":"string"},"default":[]},"values":{"type":"object","description":"Published product attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"}}}}}},"associations":{"type":"object","description":"Several associations related to groups and/or other published products, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Identifiers used in the array of the property `products` cannot be equal to the published product identifier.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the published product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of published product identifiers with which the published product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Warning: associations with quantities are not compatible with the published products. The response will always be empty."},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true}},"example":{"identifier":"top","enabled":true,"family":"tshirt","categories":["summer_collection"],"groups":[],"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black"}],"size":[{"locale":null,"scope":null,"data":"m"}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/published-products?page=3&limit=3"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/published-products?page=1&limit=3"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/published-products?page=2&limit=3"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/published-products?page=4&limit=3"}},"current_page":3,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/published-products/top"}},"identifier":"top","family":"tshirt","groups":[],"categories":["summer_collection"],"enabled":true,"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black"}],"size":[{"locale":null,"scope":null,"data":"m"}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglasses"],"product_models":[],"groups":[]}}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/published-products/cap"}},"identifier":"cap","family":"caps","groups":[],"categories":["summer_collection"],"enabled":true,"values":{"name":[{"data":"Cap","locale":"en_US","scope":null},{"data":"Casquette","locale":"fr_FR","scope":null}],"description":[{"data":"Cap unisex","locale":"en_US","scope":"ecommerce"},{"data":"Cap unisex","locale":"en_US","scope":"tablet"},{"data":"Casquette unisexe","locale":"fr_FR","scope":"ecommerce"},{"data":"Casquette unisexe","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"20","currency":"EUR"},{"amount":"20","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black"}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglasses"],"product_models":[],"groups":[]}}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/published-products/sweat"}},"identifier":"sweat","family":null,"groups":[],"categories":["winter_collection"],"enabled":true,"values":{},"created":"2016-06-23T11:24:44+02:00","updated":"2016-06-23T11:24:44+02:00","associations":{}}]}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/published-products/{code}":{"get":{"summary":"Get a published product","operationId":"get_published_products__code_","tags":["Published product"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given published product.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the published product in JSON standard format","schema":{"type":"object","required":["identifier"],"properties":{"identifier":{"type":"string","description":"Published product identifier, i.e. the value of the only `pim_catalog_identifier` attribute"},"enabled":{"type":"boolean","description":"Whether the published product is enable","default":true},"family":{"type":"string","description":"Family code from which the published product inherits its attributes and attributes requirements","x-validation-rules":"It is equal to an existing family code","default":"null"},"categories":{"type":"array","description":"Codes of the categories in which the published product is classified","x-validation-rules":"Each string of the array is equal to an existing category code","items":{"type":"string"},"default":[]},"groups":{"type":"array","description":"Codes of the groups to which the published product belong","x-validation-rules":"Each string of the array is equal to an existing group code","items":{"type":"string"},"default":[]},"values":{"type":"object","description":"Published product attributes values, see <a href='/concepts/products.html#focus-on-the-products-values'>Product values</a> section for more details","x-validation-rules":"Validation rules detailed in Product values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"scope":{"type":"string","description":"Channel code of the product value"},"locale":{"type":"string","description":"Locale code of the product value"},"data":{"type":"object","description":"Product value"}}}}}},"associations":{"type":"object","description":"Several associations related to groups and/or other published products, grouped by association types","x-validation-rules":"&bull; The `associationTypeCode` is the code of an existing association type. &#10;&bull; Each string in the array of the property `groups` is the code of an existing group. &#10;&bull; Each string in the array of the property `products` is the identifier of an existing product. &#10;&bull; Identifiers used in the array of the property `products` cannot be equal to the published product identifier.","properties":{"associationTypeCode":{"type":"object","properties":{"groups":{"type":"array","description":"Array of groups codes with which the published product is in relation","items":{"type":"string"}},"products":{"type":"array","description":"Array of published product identifiers with which the published product is in relation","items":{"type":"string"}},"product_models":{"type":"array","description":"Array of product model codes with which the product is in relation (only available since the v2.1)","items":{"type":"string"}}}}}},"quantified_associations":{"type":"object","description":"Warning: associations with quantities are not compatible with the published products. The response will always be empty."},"created":{"type":"string","description":"Date of creation","format":"dateTime","x-immutable":true,"x-read-only":true},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true}},"example":{"identifier":"top","enabled":true,"family":"tshirt","categories":["summer_collection"],"groups":[],"values":{"name":[{"data":"Top","locale":"en_US","scope":null},{"data":"Débardeur","locale":"fr_FR","scope":null}],"description":[{"data":"Summer top","locale":"en_US","scope":"ecommerce"},{"data":"Top","locale":"en_US","scope":"tablet"},{"data":"Débardeur pour l'été","locale":"fr_FR","scope":"ecommerce"},{"data":"Débardeur","locale":"fr_FR","scope":"tablet"}],"price":[{"locale":null,"scope":null,"data":[{"amount":"15.5","currency":"EUR"},{"amount":"15","currency":"USD"}]}],"color":[{"locale":null,"scope":null,"data":"black"}],"size":[{"locale":null,"scope":null,"data":"m"}]},"created":"2016-06-23T18:24:44+02:00","updated":"2016-06-25T17:56:12+02:00","associations":{"PACK":{"products":["sunglass"],"product_models":[],"groups":[]}}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/media-files":{"get":{"summary":"Get a list of product media files","operationId":"get_media_files","description":"This endpoint allows you to get a list of media files that are used as attribute values in products or product models.","tags":["Product media file"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return media files paginated","schema":{"title":"MediaFiles","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI to get the metadata of the media file"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the binaries of the media file"}}}}}}},{"type":"object","properties":{"code":{"type":"string","description":"Media file code","x-immutable":true},"original_filename":{"type":"string","description":"Original filename of the media file"},"mime_type":{"type":"string","description":"Mime type of the media file","x-read-only":true},"size":{"type":"integer","description":"Size of the media file","x-read-only":true},"extension":{"type":"string","description":"Extension of the media file","x-read-only":true}},"example":{"code":"7/5/8/e/758e39d48ea7b42a55091434fd3d8b6cf3189b7f_10806799_1356.jpg","original_filename":"10806799-1356.jpg","mime_type":"image/jpeg","size":16070,"extension":"jpg"}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/media-files?page=2&limit=4"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/media-files?page=1&limit=4"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/media-files?page=1&limit=4"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/media-files?page=2&limit=4"}},"current_page":2,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/7/5/8/e/758e39d48ea7b42a55091434fd3d8b6cf3189b7f_10806799_1356.jpg"},"download":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/7/5/8/e/758e39d48ea7b42a55091434fd3d8b6cf3189b7f_10806799_1356.jpg/download"}},"code":"7/5/8/e/758e39d48ea7b42a55091434fd3d8b6cf3189b7f_10806799_1356.jpg","original_filename":"10806799-1356.jpg","mime_type":"image/jpeg","size":16070,"extension":"jpg"},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/d/0/3/2/d032a92d994df3ef67ee6746b7b7a795c2964e7c_10734346_1480.jpg"},"download":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/d/0/3/2/d032a92d994df3ef67ee6746b7b7a795c2964e7c_10734346_1480.jpg/download"}},"code":"d/0/3/2/d032a92d994df3ef67ee6746b7b7a795c2964e7c_10734346_1480.jpg","original_filename":"10734346-1480.jpg","mime_type":"image/jpeg","size":16454,"extension":"jpg"},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/5/1/d/8/51d81dc778ba1501a8f998f3ab5797569f3b9e25_12431976_8797.jpg"},"download":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/5/1/d/8/51d81dc778ba1501a8f998f3ab5797569f3b9e25_12431976_8797.jpg/download"}},"code":"5/1/d/8/51d81dc778ba1501a8f998f3ab5797569f3b9e25_12431976_8797.jpg","original_filename":"12431976-8797.jpg","mime_type":"image/jpeg","size":19725,"extension":"jpg"},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/0/c/b/0/0cb0c0e115dedba676f8d1ad8343e6207ab54c7b_107406_9841.jpg"},"download":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/0/c/b/0/0cb0c0e115dedba676f8d1ad8343e6207ab54c7b_107406_9841.jpg/download"}},"code":"0/c/b/0/0cb0c0e115dedba676f8d1ad8343e6207ab54c7b_107406_9841.jpg","original_filename":"107406-9841.jpg","mime_type":"image/jpeg","size":17639,"extension":"jpg"}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new product media file","operationId":"post_media_files","description":"This endpoint allows you to create a new media file and associate it to an attribute value of a given product or product model.","tags":["Product media file"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"Content-type","in":"header","type":"string","description":"Equal to 'multipart/form-data', no other value allowed","required":true},{"name":"body","in":"body","x-form-data":true,"schema":{"required":["file"],"properties":{"product":{"type":"string","description":"The product to which the media file will be associated. It is a JSON string that follows this format '{\"identifier\":\"product_identifier\", \"attribute\":\"attribute_code\", \"scope\":\"channel_code\",\"locale\":\"locale_code\"}'. You have to either use this field or the `product_model` field, but not both at the same time."},"product_model":{"type":"string","description":"The product model to which the media file will be associated. It is a JSON string that follows this format '{\"code\":\"product_model_code\", \"attribute\":\"attribute_code\", \"scope\":\"channel_code\",\"locale\":\"locale_code\"}'. You have to either use this field or the `product` field, but not both at the same time."},"file":{"type":"string","description":"The binaries of the file","format":"binary"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `multipart/form-data`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘multipart/form-data’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/media-files/{code}":{"get":{"summary":"Get a product media file","operationId":"get_media_files__code_","description":"This endpoint allows you to get the information about a given media file that is used as an attribute value of a product or a product model.","tags":["Product media file"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the media file in JSON standard format","schema":{"allOf":[{"type":"object","properties":{"_links":{"type":"object","x-read-only":true,"properties":{"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the binaries of the media file"}}}}}}},{"type":"object","properties":{"code":{"type":"string","description":"Media file code","x-immutable":true},"original_filename":{"type":"string","description":"Original filename of the media file"},"mime_type":{"type":"string","description":"Mime type of the media file","x-read-only":true},"size":{"type":"integer","description":"Size of the media file","x-read-only":true},"extension":{"type":"string","description":"Extension of the media file","x-read-only":true}},"example":{"code":"7/5/8/e/758e39d48ea7b42a55091434fd3d8b6cf3189b7f_10806799_1356.jpg","original_filename":"10806799-1356.jpg","mime_type":"image/jpeg","size":16070,"extension":"jpg"}}],"example":{"_links":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/media-files/7/5/8/e/758e39d48ea7b42a55091434fd3d8b6cf3189b7f_10806799_1356.jpg/download"}},"code":"7/5/8/e/758e39d48ea7b42a55091434fd3d8b6cf3189b7f_10806799_1356.jpg","original_filename":"10806799-1356.jpg","mime_type":"image/jpeg","size":16070,"extension":"jpg"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/media-files/{code}/download":{"get":{"summary":"Download a product media file","operationId":"get_media_files__code__download","description":"This endpoint allows you to download a given media file that is used as an attribute value of a product or a product model.","x-content-type":"Mime-type of the media file","tags":["Product media file"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the binary of the media file","x-content-type":"Mime-type of the media file"},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}}}}},"/api/rest/v1/families":{"get":{"summary":"Get list of families","operationId":"get_families","description":"This endpoint allows you to get a list of families. Families are paginated and sorted by code.","tags":["Family"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"search","in":"query","description":"Filter families, for more details see the <a href=\"/documentation/filter.html#filter-families\">Filters</a> section.","required":false,"type":"string"},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return families paginated","schema":{"title":"Families","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code","attribute_as_label"],"properties":{"code":{"type":"string","description":"Family code","x-immutable":true},"attribute_as_label":{"type":"string","description":"Attribute code used as label","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is either `pim_catalog_identifier` or `pim_catalog_text`"},"attribute_as_image":{"type":"string","description":"Attribute code used as the main picture in the user interface (only since v2.0)","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is `pim_catalog_image`. Since v2.1, you can also use a `pim_assets_collection` attribute type","default":"null"},"attributes":{"type":"array","description":"Attributes codes that compose the family","x-validation-rules":"Each string of the array is an existing attribute code","items":{"type":"string"},"default":[]},"attribute_requirements":{"type":"object","description":"Attributes codes of the family that are required for the completeness calculation for each channel","x-validation-rules":"&bull; Each string of these arrays is an existing attribute code &#10;&bull; These attribute codes are in the array of the property `attributes` &#10;&bull; The `channelCode` is the code of an existing and activated channel","properties":{"channelCode":{"type":"array","items":{"type":"string","description":"Attributes codes of the family that are required for the completeness calculation for the channel `channelCode`"}}}},"labels":{"type":"object","description":"Family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family label for the locale `localeCode`"}}}},"example":{"code":"caps","attributes":["sku","name","description","price","color","picture"],"attribute_as_label":"name","attribute_as_image":"picture","attribute_requirements":{"ecommerce":["sku","name","description","price","color"],"tablet":["sku","name","description","price"]},"labels":{"en_US":"Caps","fr_FR":"Casquettes"}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/families?page=2&limit=2"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/families?page=1&limit=2"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/families?page=1&limit=2"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/families?page=3&limit=2"}},"current_page":2,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/families/tshirt"}},"code":"tshirt","attributes":["sku","name","description","price","size","color","picture"],"attribute_as_label":"name","attribute_as_image":"picture","attribute_requirements":{"ecommerce":["sku","name","description","price","size","color"],"tablet":["sku","name","description","price"]},"labels":{"en_US":"Tshirt","fr_FR":"Tshirt"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/families/caps"}},"code":"caps","attributes":["sku","name","description","price","color","picture"],"attribute_as_label":"name","attribute_as_image":"picture","attribute_requirements":{"ecommerce":["sku","name","description","price","color"],"tablet":["sku","name","description","price"]},"labels":{"en_US":"Caps","fr_FR":"Casquettes"}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new family","operationId":"post_families","description":"This endpoint allows you to create a new family.","tags":["Family"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["code","attribute_as_label"],"properties":{"code":{"type":"string","description":"Family code","x-immutable":true},"attribute_as_label":{"type":"string","description":"Attribute code used as label","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is either `pim_catalog_identifier` or `pim_catalog_text`"},"attribute_as_image":{"type":"string","description":"Attribute code used as the main picture in the user interface (only since v2.0)","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is `pim_catalog_image`. Since v2.1, you can also use a `pim_assets_collection` attribute type","default":"null"},"attributes":{"type":"array","description":"Attributes codes that compose the family","x-validation-rules":"Each string of the array is an existing attribute code","items":{"type":"string"},"default":[]},"attribute_requirements":{"type":"object","description":"Attributes codes of the family that are required for the completeness calculation for each channel","x-validation-rules":"&bull; Each string of these arrays is an existing attribute code &#10;&bull; These attribute codes are in the array of the property `attributes` &#10;&bull; The `channelCode` is the code of an existing and activated channel","properties":{"channelCode":{"type":"array","items":{"type":"string","description":"Attributes codes of the family that are required for the completeness calculation for the channel `channelCode`"}}}},"labels":{"type":"object","description":"Family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family label for the locale `localeCode`"}}}},"example":{"code":"caps","attributes":["sku","name","description","price","color","picture"],"attribute_as_label":"name","attribute_as_image":"picture","attribute_requirements":{"ecommerce":["sku","name","description","price","color"],"tablet":["sku","name","description","price"]},"labels":{"en_US":"Caps","fr_FR":"Casquettes"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several families","operationId":"patch_families","tags":["Family"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update and/or create several families at once.","x-body-by-line":"Contains several lines, each line is a family in JSON standard format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\":\"tshirt\",\"attributes\":[\"description\",\"size\"]}","x-example-2":"{\"code\":\"cap\",\"attribute_as_label\":\"descripion\"}","x-example-3":"{\"code\":\"mug\",\"attributes\":[\"description\",\"short_description\"]}"},"type":"object","required":["code","attribute_as_label"],"properties":{"code":{"type":"string","description":"Family code","x-immutable":true},"attribute_as_label":{"type":"string","description":"Attribute code used as label","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is either `pim_catalog_identifier` or `pim_catalog_text`"},"attribute_as_image":{"type":"string","description":"Attribute code used as the main picture in the user interface (only since v2.0)","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is `pim_catalog_image`. Since v2.1, you can also use a `pim_assets_collection` attribute type","default":"null"},"attributes":{"type":"array","description":"Attributes codes that compose the family","x-validation-rules":"Each string of the array is an existing attribute code","items":{"type":"string"},"default":[]},"attribute_requirements":{"type":"object","description":"Attributes codes of the family that are required for the completeness calculation for each channel","x-validation-rules":"&bull; Each string of these arrays is an existing attribute code &#10;&bull; These attribute codes are in the array of the property `attributes` &#10;&bull; The `channelCode` is the code of an existing and activated channel","properties":{"channelCode":{"type":"array","items":{"type":"string","description":"Attributes codes of the family that are required for the completeness calculation for the channel `channelCode`"}}}},"labels":{"type":"object","description":"Family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family label for the locale `localeCode`"}}}},"example":{"code":"caps","attributes":["sku","name","description","price","color","picture"],"attribute_as_label":"name","attribute_as_image":"picture","attribute_requirements":{"ecommerce":["sku","name","description","price","color"],"tablet":["sku","name","description","price"]},"labels":{"en_US":"Caps","fr_FR":"Casquettes"}}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"tshirt\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"cap\",\"status_code\":422,\"message\":\"Attribute \"descripion\" does not exist.\"}","x-example-3":"{\"line\":3,\"code\":\"mug\",\"status_code\":204}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/families/{code}":{"get":{"summary":"Get a family","operationId":"get_families__code_","description":"This endpoint allows you to get the information about a given family.","tags":["Family"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the family in JSON standard format","schema":{"type":"object","required":["code","attribute_as_label"],"properties":{"code":{"type":"string","description":"Family code","x-immutable":true},"attribute_as_label":{"type":"string","description":"Attribute code used as label","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is either `pim_catalog_identifier` or `pim_catalog_text`"},"attribute_as_image":{"type":"string","description":"Attribute code used as the main picture in the user interface (only since v2.0)","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is `pim_catalog_image`. Since v2.1, you can also use a `pim_assets_collection` attribute type","default":"null"},"attributes":{"type":"array","description":"Attributes codes that compose the family","x-validation-rules":"Each string of the array is an existing attribute code","items":{"type":"string"},"default":[]},"attribute_requirements":{"type":"object","description":"Attributes codes of the family that are required for the completeness calculation for each channel","x-validation-rules":"&bull; Each string of these arrays is an existing attribute code &#10;&bull; These attribute codes are in the array of the property `attributes` &#10;&bull; The `channelCode` is the code of an existing and activated channel","properties":{"channelCode":{"type":"array","items":{"type":"string","description":"Attributes codes of the family that are required for the completeness calculation for the channel `channelCode`"}}}},"labels":{"type":"object","description":"Family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family label for the locale `localeCode`"}}}},"example":{"code":"caps","attributes":["sku","name","description","price","color","picture"],"attribute_as_label":"name","attribute_as_image":"picture","attribute_requirements":{"ecommerce":["sku","name","description","price","color"],"tablet":["sku","name","description","price"]},"labels":{"en_US":"Caps","fr_FR":"Casquettes"}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a family","operationId":"patch_families__code_","tags":["Family"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given family. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no family exists for the given code, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code","attribute_as_label"],"properties":{"code":{"type":"string","description":"Family code","x-immutable":true},"attribute_as_label":{"type":"string","description":"Attribute code used as label","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is either `pim_catalog_identifier` or `pim_catalog_text`"},"attribute_as_image":{"type":"string","description":"Attribute code used as the main picture in the user interface (only since v2.0)","x-validation-rules":"&bull; It is equal to an existing attribute code &#10;&bull; This attribute code is in the array of the property `attributes` &#10;&bull; The type of this attribute is `pim_catalog_image`. Since v2.1, you can also use a `pim_assets_collection` attribute type","default":"null"},"attributes":{"type":"array","description":"Attributes codes that compose the family","x-validation-rules":"Each string of the array is an existing attribute code","items":{"type":"string"},"default":[]},"attribute_requirements":{"type":"object","description":"Attributes codes of the family that are required for the completeness calculation for each channel","x-validation-rules":"&bull; Each string of these arrays is an existing attribute code &#10;&bull; These attribute codes are in the array of the property `attributes` &#10;&bull; The `channelCode` is the code of an existing and activated channel","properties":{"channelCode":{"type":"array","items":{"type":"string","description":"Attributes codes of the family that are required for the completeness calculation for the channel `channelCode`"}}}},"labels":{"type":"object","description":"Family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family label for the locale `localeCode`"}}}},"example":{"code":"caps","attributes":["sku","name","description","price","color","picture"],"attribute_as_label":"name","attribute_as_image":"picture","attribute_requirements":{"ecommerce":["sku","name","description","price","color"],"tablet":["sku","name","description","price"]},"labels":{"en_US":"Caps","fr_FR":"Casquettes"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/families/{family_code}/variants":{"get":{"summary":"Get list of family variants","operationId":"get_families__family_code__variants","description":"This endpoint allows you to get a list of family variants. Family variants are paginated and sorted by code.","tags":["Family variant"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"family_code","in":"path","description":"Code of the family","required":true,"type":"string"},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return family variants paginated","schema":{"title":"Family Variants","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code","variant_attribute_sets"],"properties":{"code":{"type":"string","description":"Family variant code","x-immutable":true},"variant_attribute_sets":{"type":"array","description":"Attributes distribution according to the enrichment level","items":{"type":"object","required":["level","axes"],"description":"Enrichment level","properties":{"level":{"type":"integer","description":"Enrichment level","x-immutable":true,"x-validation-rules":"&bull; Number representing the level of the attribute set. &#10;&bull; It should be equal to 1 or 2. &#10;&bull; If you specify the level 2, you have to specify the level 1 as well."},"axes":{"type":"array","description":"Codes of attributes used as variant axes","x-immutable":true,"items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of maximum 5 existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Only the following attribute types are allowed: `simple select`, `multi select`, `reference data`, `metric`, `boolean` &#10;&bull; Attributes cannot be scopable, nor localizable nor locale specific &#10;&bull; Attributes used as axes in one level cannot be used as axes or as attributes in the other level"},"attributes":{"type":"array","description":"Codes of attributes bind to this enrichment level","items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Attributes used as attribute in one level cannot be used as axes or as attributes in the other level &#10;&bull; Attributes that are `unique value` or `identifier` are automatically distributed to the lower level."}}}},"labels":{"type":"object","description":"Family variant labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family variant label for the locale `localeCode`"}}}},"example":{"code":"shoesVariant","labels":{"en_US":"Shoes variant","fr_FR":"Variante de chaussures"},"variant_attribute_sets":[{"level":1,"attributes":["color","material"],"axes":["color"]},{"level":2,"attributes":["sku","size"],"axes":["size"]}]}}]}}}}}}]},"examples":{"code":"shoesVariant","labels":{"en_US":"Shoes variant","fr_FR":"Variante de chaussures"},"variant_attribute_sets":[{"level":1,"attributes":["color","material"],"axes":["color"]},{"level":2,"attributes":["sku","size"],"axes":["size"]}]}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new family variant","operationId":"post_families__family_code__variants","tags":["Family"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to create a family variant.","parameters":[{"name":"family_code","in":"path","description":"Code of the family","required":true,"type":"string"},{"name":"body","in":"body","schema":{"type":"object","required":["code","variant_attribute_sets"],"properties":{"code":{"type":"string","description":"Family variant code","x-immutable":true},"variant_attribute_sets":{"type":"array","description":"Attributes distribution according to the enrichment level","items":{"type":"object","required":["level","axes"],"description":"Enrichment level","properties":{"level":{"type":"integer","description":"Enrichment level","x-immutable":true,"x-validation-rules":"&bull; Number representing the level of the attribute set. &#10;&bull; It should be equal to 1 or 2. &#10;&bull; If you specify the level 2, you have to specify the level 1 as well."},"axes":{"type":"array","description":"Codes of attributes used as variant axes","x-immutable":true,"items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of maximum 5 existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Only the following attribute types are allowed: `simple select`, `multi select`, `reference data`, `metric`, `boolean` &#10;&bull; Attributes cannot be scopable, nor localizable nor locale specific &#10;&bull; Attributes used as axes in one level cannot be used as axes or as attributes in the other level"},"attributes":{"type":"array","description":"Codes of attributes bind to this enrichment level","items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Attributes used as attribute in one level cannot be used as axes or as attributes in the other level &#10;&bull; Attributes that are `unique value` or `identifier` are automatically distributed to the lower level."}}}},"labels":{"type":"object","description":"Family variant labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family variant label for the locale `localeCode`"}}}},"example":{"code":"shoesVariant","labels":{"en_US":"Shoes variant","fr_FR":"Variante de chaussures"},"variant_attribute_sets":[{"level":1,"attributes":["color","material"],"axes":["color"]},{"level":2,"attributes":["sku","size"],"axes":["size"]}]}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several family variants","operationId":"patch_families__family_code__variants","tags":["Family variant"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update and/or create several family variants at once, for a given family.","x-body-by-line":"Contains several lines, each line is a family in JSON standard format","parameters":[{"name":"family_code","in":"path","description":"Code of the family","required":true,"type":"string"},{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\": \"shoes_by_size\", \"variant_attribute_sets\": [{\"level\": 1, \"axes\": [\"size\"], \"attributes\": [\"color\"]}]}","x-example-2":"{\"code\": \"shoes_by_color\",\"labels\": {\"en_US\": \"Shoes by color\"}}","x-example-3":"{\"code\": \"shoes_without_axes\", \"variant_attribute_sets\": [{\"level\": 1, \"axes\": [], \"attributes\": [\"color\"]}]}"},"type":"object","required":["code","variant_attribute_sets"],"properties":{"code":{"type":"string","description":"Family variant code","x-immutable":true},"variant_attribute_sets":{"type":"array","description":"Attributes distribution according to the enrichment level","items":{"type":"object","required":["level","axes"],"description":"Enrichment level","properties":{"level":{"type":"integer","description":"Enrichment level","x-immutable":true,"x-validation-rules":"&bull; Number representing the level of the attribute set. &#10;&bull; It should be equal to 1 or 2. &#10;&bull; If you specify the level 2, you have to specify the level 1 as well."},"axes":{"type":"array","description":"Codes of attributes used as variant axes","x-immutable":true,"items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of maximum 5 existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Only the following attribute types are allowed: `simple select`, `multi select`, `reference data`, `metric`, `boolean` &#10;&bull; Attributes cannot be scopable, nor localizable nor locale specific &#10;&bull; Attributes used as axes in one level cannot be used as axes or as attributes in the other level"},"attributes":{"type":"array","description":"Codes of attributes bind to this enrichment level","items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Attributes used as attribute in one level cannot be used as axes or as attributes in the other level &#10;&bull; Attributes that are `unique value` or `identifier` are automatically distributed to the lower level."}}}},"labels":{"type":"object","description":"Family variant labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family variant label for the locale `localeCode`"}}}},"example":{"code":"shoesVariant","labels":{"en_US":"Shoes variant","fr_FR":"Variante de chaussures"},"variant_attribute_sets":[{"level":1,"attributes":["color","material"],"axes":["color"]},{"level":2,"attributes":["sku","size"],"axes":["size"]}]}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"shoes_by_size\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"shoes_by_color\",\"status_code\":204}","x-example-3":"{\"line\":3,\"code\":\"mug\",\"status_code\":422, \"message\":\"There should be at least one attribute defined as axis for the attribute set for level \"1\"\"}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/families/{family_code}/variants/{code}":{"get":{"summary":"Get a family variant","operationId":"get_families__family_code__variants__code__","description":"This endpoint allows you to get the information about a given family variant.","tags":["Family variant"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"family_code","in":"path","description":"Code of the family","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the family variant in JSON standard format","schema":{"type":"object","required":["code","variant_attribute_sets"],"properties":{"code":{"type":"string","description":"Family variant code","x-immutable":true},"variant_attribute_sets":{"type":"array","description":"Attributes distribution according to the enrichment level","items":{"type":"object","required":["level","axes"],"description":"Enrichment level","properties":{"level":{"type":"integer","description":"Enrichment level","x-immutable":true,"x-validation-rules":"&bull; Number representing the level of the attribute set. &#10;&bull; It should be equal to 1 or 2. &#10;&bull; If you specify the level 2, you have to specify the level 1 as well."},"axes":{"type":"array","description":"Codes of attributes used as variant axes","x-immutable":true,"items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of maximum 5 existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Only the following attribute types are allowed: `simple select`, `multi select`, `reference data`, `metric`, `boolean` &#10;&bull; Attributes cannot be scopable, nor localizable nor locale specific &#10;&bull; Attributes used as axes in one level cannot be used as axes or as attributes in the other level"},"attributes":{"type":"array","description":"Codes of attributes bind to this enrichment level","items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Attributes used as attribute in one level cannot be used as axes or as attributes in the other level &#10;&bull; Attributes that are `unique value` or `identifier` are automatically distributed to the lower level."}}}},"labels":{"type":"object","description":"Family variant labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family variant label for the locale `localeCode`"}}}},"example":{"code":"shoesVariant","labels":{"en_US":"Shoes variant","fr_FR":"Variante de chaussures"},"variant_attribute_sets":[{"level":1,"attributes":["color","material"],"axes":["color"]},{"level":2,"attributes":["sku","size"],"axes":["size"]}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a family variant","operationId":"patch_families__family_code__variants__code__","tags":["Family variant"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given family variant. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no family variant exists for the given code, it creates it.","parameters":[{"name":"family_code","in":"path","description":"Code of the family","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code","variant_attribute_sets"],"properties":{"code":{"type":"string","description":"Family variant code","x-immutable":true},"variant_attribute_sets":{"type":"array","description":"Attributes distribution according to the enrichment level","items":{"type":"object","required":["level","axes"],"description":"Enrichment level","properties":{"level":{"type":"integer","description":"Enrichment level","x-immutable":true,"x-validation-rules":"&bull; Number representing the level of the attribute set. &#10;&bull; It should be equal to 1 or 2. &#10;&bull; If you specify the level 2, you have to specify the level 1 as well."},"axes":{"type":"array","description":"Codes of attributes used as variant axes","x-immutable":true,"items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of maximum 5 existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Only the following attribute types are allowed: `simple select`, `multi select`, `reference data`, `metric`, `boolean` &#10;&bull; Attributes cannot be scopable, nor localizable nor locale specific &#10;&bull; Attributes used as axes in one level cannot be used as axes or as attributes in the other level"},"attributes":{"type":"array","description":"Codes of attributes bind to this enrichment level","items":{"type":"string"},"default":[],"x-validation-rules":"&bull; Should be an array of existing attribute codes &#10;&bull; These attributes should belong to the family of the family variant &#10;&bull; Attributes used as attribute in one level cannot be used as axes or as attributes in the other level &#10;&bull; Attributes that are `unique value` or `identifier` are automatically distributed to the lower level."}}}},"labels":{"type":"object","description":"Family variant labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Family variant label for the locale `localeCode`"}}}},"example":{"code":"shoesVariant","labels":{"en_US":"Shoes variant","fr_FR":"Variante de chaussures"},"variant_attribute_sets":[{"level":1,"attributes":["color","material"],"axes":["color"]},{"level":2,"attributes":["sku","size"],"axes":["size"]}]}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/attributes":{"get":{"summary":"Get list of attributes","operationId":"get_attributes","description":"This endpoint allows you to get a list of attributes. Attributes are paginated and sorted by code.","tags":["Attribute"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"search","in":"query","description":"Filter attributes, for more details see the <a href=\"/documentation/filter.html#filter-attributes\">Filters</a> section.","required":false,"type":"string"},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return attributes paginated","schema":{"title":"Attributes","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code","type","group"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"type":{"type":"string","description":"Attribute type","x-validation-rules":"The type is one of the following values","enum":["pim_catalog_identifier","pim_catalog_metric","pim_catalog_number","pim_catalog_reference_data_multi_select","pim_catalog_reference_data_simple_select","pim_catalog_simpleselect","pim_catalog_multiselect","pim_catalog_date","pim_catalog_textarea","pim_catalog_text","pim_catalog_file","pim_catalog_image","pim_catalog_price_collection","pim_catalog_boolean","akeneo_reference_entity","akeneo_reference_entity_collection","pim_catalog_asset_collection"],"x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"group":{"type":"string","description":"Attribute group","x-validation-rules":"It is the code of an existing group"},"group_labels":{"type":"object","description":"Group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","x-read-only":true,"default":{},"properties":{"localeCode":{"type":"string","description":"Group label for the locale `localeCode`"}}},"sort_order":{"type":"integer","description":"Order of the attribute in its group","x-validation-rules":"It is a positive integer","default":0},"localizable":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"scopable":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"available_locales":{"type":"array","description":"To make the attribute locale specfic, specify here for which locales it is specific","x-validation-rules":"Each string of the array is an existing and activated locale","items":{"type":"string"}},"unique":{"type":"boolean","description":"Whether two values for the attribute cannot be the same","x-immutable":true},"useable_as_grid_filter":{"type":"boolean","description":"Whether the attribute can be used as a filter for the product grid in the PIM user interface"},"max_characters":{"type":"integer","description":"Number maximum of characters allowed for the value of the attribute when the attribute type is `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier` attribute types"},"validation_rule":{"type":"string","description":"Validation rule type used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Equal to `regexp` when the attribute type is equal to `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"validation_regexp":{"type":"string","description":"Regexp expression used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"wysiwyg_enabled":{"type":"boolean","description":"Whether the WYSIWYG interface is shown when the attribute type is `pim_catalog_textarea`","x-warning":"Only for `pim_catalog_textarea` attribute type"},"number_min":{"type":"string","description":"Minimum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"number_max":{"type":"string","description":"Maximum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"negative_allowed":{"type":"boolean","description":"Whether negative values are allowed when the attribute type is `pim_catalog_metric` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric` or `pim_catalog_number` attribute types"},"metric_family":{"type":"string","description":"Metric family when the attribute type is `pim_catalog_metric`","x-immutable":true,"x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"default_metric_unit":{"type":"string","description":"Default metric unit when the attribute type is `pim_catalog_metric`","x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"date_min":{"type":"string","description":"Minimum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"date_max":{"type":"string","description":"Maximum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types"},"reference_data_name":{"type":"string","description":"Reference entity code when the attribute type is `akeneo_reference_entity` or `akeneo_reference_entity_collection` OR Asset family code when the attribute type is `pim_catalog_asset_collection`","x-validation-rules":"Required only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types","x-warning":"Only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types"},"default_value":{"type":"boolean","description":"Default value for a Yes/No attribute, applied when creating a new product or product model (only available since the 5.0)","x-warning":"Only for `pim_catalog_boolean` attribute type"}},"example":{"code":"release_date","type":"pim_catalog_date","group":"marketing","group_labels":{"en_US":"Marketing","fr_FR":"Marketing"},"unique":false,"useable_as_grid_filter":true,"allowed_extensions":[],"metric_family":null,"default_metric_unit":null,"reference_data_name":null,"available_locales":[],"max_characters":null,"validation_rule":null,"validation_regexp":null,"wysiwyg_enabled":null,"number_min":null,"number_max":null,"decimals_allowed":null,"negative_allowed":null,"date_min":"2017-06-28T08:00:00","date_max":"2017-08-08T22:00:00","max_file_size":null,"minimum_input_length":null,"sort_order":1,"localizable":false,"scopable":false,"default_value":null,"labels":{"en_US":"Sale date","fr_FR":"Date des soldes"}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attributes?page=3&limit=2"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/attributes?page=1&limit=2"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/attributes?page=2&limit=2"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/attributes?page=4&limit=2"}},"current_page":3,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/sku"}},"code":"sku","type":"pim_catalog_identifier","group":"other","group_labels":{"en_US":"Other","fr_FR":"Autre"},"unique":true,"useable_as_grid_filter":true,"allowed_extensions":[],"metric_family":null,"default_metric_unit":null,"reference_data_name":null,"available_locales":[],"max_characters":null,"validation_rule":null,"validation_regexp":null,"wysiwyg_enabled":false,"number_min":null,"number_max":null,"decimals_allowed":false,"negative_allowed":false,"date_min":null,"date_max":null,"max_file_size":null,"minimum_input_length":null,"sort_order":1,"localizable":false,"scopable":false,"default_value":null,"labels":{"en_US":"Identifier","fr_FR":"Identifiant"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/release_date"}},"code":"release_date","type":"pim_catalog_date","group":"marketing","unique":false,"useable_as_grid_filter":true,"allowed_extensions":[],"metric_family":null,"default_metric_unit":null,"reference_data_name":null,"available_locales":[],"max_characters":null,"validation_rule":null,"validation_regexp":null,"wysiwyg_enabled":false,"number_min":null,"number_max":null,"decimals_allowed":false,"negative_allowed":false,"date_min":"2017-06-28T08:00:00","date_max":"2017-08-08T22:00:00","max_file_size":null,"minimum_input_length":null,"sort_order":1,"localizable":false,"scopable":false,"default_value":null,"labels":{"en_US":"Sale date","fr_FR":"Date des soldes"}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new attribute","operationId":"post_attributes","description":"This endpoint allows you to create a new attribute.","tags":["Attribute"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["code","type","group"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"type":{"type":"string","description":"Attribute type","x-validation-rules":"The type is one of the following values","enum":["pim_catalog_identifier","pim_catalog_metric","pim_catalog_number","pim_catalog_reference_data_multi_select","pim_catalog_reference_data_simple_select","pim_catalog_simpleselect","pim_catalog_multiselect","pim_catalog_date","pim_catalog_textarea","pim_catalog_text","pim_catalog_file","pim_catalog_image","pim_catalog_price_collection","pim_catalog_boolean","akeneo_reference_entity","akeneo_reference_entity_collection","pim_catalog_asset_collection"],"x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"group":{"type":"string","description":"Attribute group","x-validation-rules":"It is the code of an existing group"},"group_labels":{"type":"object","description":"Group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","x-read-only":true,"default":{},"properties":{"localeCode":{"type":"string","description":"Group label for the locale `localeCode`"}}},"sort_order":{"type":"integer","description":"Order of the attribute in its group","x-validation-rules":"It is a positive integer","default":0},"localizable":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"scopable":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"available_locales":{"type":"array","description":"To make the attribute locale specfic, specify here for which locales it is specific","x-validation-rules":"Each string of the array is an existing and activated locale","items":{"type":"string"}},"unique":{"type":"boolean","description":"Whether two values for the attribute cannot be the same","x-immutable":true},"useable_as_grid_filter":{"type":"boolean","description":"Whether the attribute can be used as a filter for the product grid in the PIM user interface"},"max_characters":{"type":"integer","description":"Number maximum of characters allowed for the value of the attribute when the attribute type is `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier` attribute types"},"validation_rule":{"type":"string","description":"Validation rule type used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Equal to `regexp` when the attribute type is equal to `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"validation_regexp":{"type":"string","description":"Regexp expression used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"wysiwyg_enabled":{"type":"boolean","description":"Whether the WYSIWYG interface is shown when the attribute type is `pim_catalog_textarea`","x-warning":"Only for `pim_catalog_textarea` attribute type"},"number_min":{"type":"string","description":"Minimum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"number_max":{"type":"string","description":"Maximum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"negative_allowed":{"type":"boolean","description":"Whether negative values are allowed when the attribute type is `pim_catalog_metric` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric` or `pim_catalog_number` attribute types"},"metric_family":{"type":"string","description":"Metric family when the attribute type is `pim_catalog_metric`","x-immutable":true,"x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"default_metric_unit":{"type":"string","description":"Default metric unit when the attribute type is `pim_catalog_metric`","x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"date_min":{"type":"string","description":"Minimum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"date_max":{"type":"string","description":"Maximum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types"},"reference_data_name":{"type":"string","description":"Reference entity code when the attribute type is `akeneo_reference_entity` or `akeneo_reference_entity_collection` OR Asset family code when the attribute type is `pim_catalog_asset_collection`","x-validation-rules":"Required only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types","x-warning":"Only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types"},"default_value":{"type":"boolean","description":"Default value for a Yes/No attribute, applied when creating a new product or product model (only available since the 5.0)","x-warning":"Only for `pim_catalog_boolean` attribute type"}},"example":{"code":"release_date","type":"pim_catalog_date","group":"marketing","group_labels":{"en_US":"Marketing","fr_FR":"Marketing"},"unique":false,"useable_as_grid_filter":true,"allowed_extensions":[],"metric_family":null,"default_metric_unit":null,"reference_data_name":null,"available_locales":[],"max_characters":null,"validation_rule":null,"validation_regexp":null,"wysiwyg_enabled":null,"number_min":null,"number_max":null,"decimals_allowed":null,"negative_allowed":null,"date_min":"2017-06-28T08:00:00","date_max":"2017-08-08T22:00:00","max_file_size":null,"minimum_input_length":null,"sort_order":1,"localizable":false,"scopable":false,"default_value":null,"labels":{"en_US":"Sale date","fr_FR":"Date des soldes"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several attributes","operationId":"patch_attributes","tags":["Attribute"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update and/or create several attributes at once.","x-body-by-line":"Contains several lines, each line is an attribute in JSON standard format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\":\"description\",\"useable_as_grid_filter\":true}","x-example-2":"{\"code\":\"short_description\",\"group\":\"marketig\"}","x-example-3":"{\"code\":\"release_date\",\"date_min\":\"2017-06-28T08:00:00\"}"},"type":"object","required":["code","type","group"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"type":{"type":"string","description":"Attribute type","x-validation-rules":"The type is one of the following values","enum":["pim_catalog_identifier","pim_catalog_metric","pim_catalog_number","pim_catalog_reference_data_multi_select","pim_catalog_reference_data_simple_select","pim_catalog_simpleselect","pim_catalog_multiselect","pim_catalog_date","pim_catalog_textarea","pim_catalog_text","pim_catalog_file","pim_catalog_image","pim_catalog_price_collection","pim_catalog_boolean","akeneo_reference_entity","akeneo_reference_entity_collection","pim_catalog_asset_collection"],"x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"group":{"type":"string","description":"Attribute group","x-validation-rules":"It is the code of an existing group"},"group_labels":{"type":"object","description":"Group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","x-read-only":true,"default":{},"properties":{"localeCode":{"type":"string","description":"Group label for the locale `localeCode`"}}},"sort_order":{"type":"integer","description":"Order of the attribute in its group","x-validation-rules":"It is a positive integer","default":0},"localizable":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"scopable":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"available_locales":{"type":"array","description":"To make the attribute locale specfic, specify here for which locales it is specific","x-validation-rules":"Each string of the array is an existing and activated locale","items":{"type":"string"}},"unique":{"type":"boolean","description":"Whether two values for the attribute cannot be the same","x-immutable":true},"useable_as_grid_filter":{"type":"boolean","description":"Whether the attribute can be used as a filter for the product grid in the PIM user interface"},"max_characters":{"type":"integer","description":"Number maximum of characters allowed for the value of the attribute when the attribute type is `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier` attribute types"},"validation_rule":{"type":"string","description":"Validation rule type used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Equal to `regexp` when the attribute type is equal to `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"validation_regexp":{"type":"string","description":"Regexp expression used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"wysiwyg_enabled":{"type":"boolean","description":"Whether the WYSIWYG interface is shown when the attribute type is `pim_catalog_textarea`","x-warning":"Only for `pim_catalog_textarea` attribute type"},"number_min":{"type":"string","description":"Minimum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"number_max":{"type":"string","description":"Maximum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"negative_allowed":{"type":"boolean","description":"Whether negative values are allowed when the attribute type is `pim_catalog_metric` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric` or `pim_catalog_number` attribute types"},"metric_family":{"type":"string","description":"Metric family when the attribute type is `pim_catalog_metric`","x-immutable":true,"x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"default_metric_unit":{"type":"string","description":"Default metric unit when the attribute type is `pim_catalog_metric`","x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"date_min":{"type":"string","description":"Minimum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"date_max":{"type":"string","description":"Maximum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types"},"reference_data_name":{"type":"string","description":"Reference entity code when the attribute type is `akeneo_reference_entity` or `akeneo_reference_entity_collection` OR Asset family code when the attribute type is `pim_catalog_asset_collection`","x-validation-rules":"Required only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types","x-warning":"Only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types"},"default_value":{"type":"boolean","description":"Default value for a Yes/No attribute, applied when creating a new product or product model (only available since the 5.0)","x-warning":"Only for `pim_catalog_boolean` attribute type"}},"example":{"code":"release_date","type":"pim_catalog_date","group":"marketing","group_labels":{"en_US":"Marketing","fr_FR":"Marketing"},"unique":false,"useable_as_grid_filter":true,"allowed_extensions":[],"metric_family":null,"default_metric_unit":null,"reference_data_name":null,"available_locales":[],"max_characters":null,"validation_rule":null,"validation_regexp":null,"wysiwyg_enabled":null,"number_min":null,"number_max":null,"decimals_allowed":null,"negative_allowed":null,"date_min":"2017-06-28T08:00:00","date_max":"2017-08-08T22:00:00","max_file_size":null,"minimum_input_length":null,"sort_order":1,"localizable":false,"scopable":false,"default_value":null,"labels":{"en_US":"Sale date","fr_FR":"Date des soldes"}}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"description\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"short_description\",\"status_code\":422,\"message\":\"Group \"marketig\" does not exist.\"}","x-example-3":"{\"line\":3,\"code\":\"release_date\",\"status_code\":204}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/attributes/{code}":{"get":{"summary":"Get an attribute","operationId":"get_attributes__code_","description":"This endpoint allows you to get the information about a given attribute.","tags":["Attribute"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the attribute in JSON standard format","schema":{"type":"object","required":["code","type","group"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"type":{"type":"string","description":"Attribute type","x-validation-rules":"The type is one of the following values","enum":["pim_catalog_identifier","pim_catalog_metric","pim_catalog_number","pim_catalog_reference_data_multi_select","pim_catalog_reference_data_simple_select","pim_catalog_simpleselect","pim_catalog_multiselect","pim_catalog_date","pim_catalog_textarea","pim_catalog_text","pim_catalog_file","pim_catalog_image","pim_catalog_price_collection","pim_catalog_boolean","akeneo_reference_entity","akeneo_reference_entity_collection","pim_catalog_asset_collection"],"x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"group":{"type":"string","description":"Attribute group","x-validation-rules":"It is the code of an existing group"},"group_labels":{"type":"object","description":"Group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","x-read-only":true,"default":{},"properties":{"localeCode":{"type":"string","description":"Group label for the locale `localeCode`"}}},"sort_order":{"type":"integer","description":"Order of the attribute in its group","x-validation-rules":"It is a positive integer","default":0},"localizable":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"scopable":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"available_locales":{"type":"array","description":"To make the attribute locale specfic, specify here for which locales it is specific","x-validation-rules":"Each string of the array is an existing and activated locale","items":{"type":"string"}},"unique":{"type":"boolean","description":"Whether two values for the attribute cannot be the same","x-immutable":true},"useable_as_grid_filter":{"type":"boolean","description":"Whether the attribute can be used as a filter for the product grid in the PIM user interface"},"max_characters":{"type":"integer","description":"Number maximum of characters allowed for the value of the attribute when the attribute type is `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier` attribute types"},"validation_rule":{"type":"string","description":"Validation rule type used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Equal to `regexp` when the attribute type is equal to `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"validation_regexp":{"type":"string","description":"Regexp expression used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"wysiwyg_enabled":{"type":"boolean","description":"Whether the WYSIWYG interface is shown when the attribute type is `pim_catalog_textarea`","x-warning":"Only for `pim_catalog_textarea` attribute type"},"number_min":{"type":"string","description":"Minimum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"number_max":{"type":"string","description":"Maximum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"negative_allowed":{"type":"boolean","description":"Whether negative values are allowed when the attribute type is `pim_catalog_metric` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric` or `pim_catalog_number` attribute types"},"metric_family":{"type":"string","description":"Metric family when the attribute type is `pim_catalog_metric`","x-immutable":true,"x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"default_metric_unit":{"type":"string","description":"Default metric unit when the attribute type is `pim_catalog_metric`","x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"date_min":{"type":"string","description":"Minimum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"date_max":{"type":"string","description":"Maximum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types"},"reference_data_name":{"type":"string","description":"Reference entity code when the attribute type is `akeneo_reference_entity` or `akeneo_reference_entity_collection` OR Asset family code when the attribute type is `pim_catalog_asset_collection`","x-validation-rules":"Required only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types","x-warning":"Only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types"},"default_value":{"type":"boolean","description":"Default value for a Yes/No attribute, applied when creating a new product or product model (only available since the 5.0)","x-warning":"Only for `pim_catalog_boolean` attribute type"}},"example":{"code":"release_date","type":"pim_catalog_date","group":"marketing","group_labels":{"en_US":"Marketing","fr_FR":"Marketing"},"unique":false,"useable_as_grid_filter":true,"allowed_extensions":[],"metric_family":null,"default_metric_unit":null,"reference_data_name":null,"available_locales":[],"max_characters":null,"validation_rule":null,"validation_regexp":null,"wysiwyg_enabled":null,"number_min":null,"number_max":null,"decimals_allowed":null,"negative_allowed":null,"date_min":"2017-06-28T08:00:00","date_max":"2017-08-08T22:00:00","max_file_size":null,"minimum_input_length":null,"sort_order":1,"localizable":false,"scopable":false,"default_value":null,"labels":{"en_US":"Sale date","fr_FR":"Date des soldes"}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an attribute","operationId":"patch_attributes__code_","tags":["Attribute"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given attribute. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no attribute exists for the given code, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code","type","group"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"type":{"type":"string","description":"Attribute type","x-validation-rules":"The type is one of the following values","enum":["pim_catalog_identifier","pim_catalog_metric","pim_catalog_number","pim_catalog_reference_data_multi_select","pim_catalog_reference_data_simple_select","pim_catalog_simpleselect","pim_catalog_multiselect","pim_catalog_date","pim_catalog_textarea","pim_catalog_text","pim_catalog_file","pim_catalog_image","pim_catalog_price_collection","pim_catalog_boolean","akeneo_reference_entity","akeneo_reference_entity_collection","pim_catalog_asset_collection"],"x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"group":{"type":"string","description":"Attribute group","x-validation-rules":"It is the code of an existing group"},"group_labels":{"type":"object","description":"Group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","x-read-only":true,"default":{},"properties":{"localeCode":{"type":"string","description":"Group label for the locale `localeCode`"}}},"sort_order":{"type":"integer","description":"Order of the attribute in its group","x-validation-rules":"It is a positive integer","default":0},"localizable":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"scopable":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"available_locales":{"type":"array","description":"To make the attribute locale specfic, specify here for which locales it is specific","x-validation-rules":"Each string of the array is an existing and activated locale","items":{"type":"string"}},"unique":{"type":"boolean","description":"Whether two values for the attribute cannot be the same","x-immutable":true},"useable_as_grid_filter":{"type":"boolean","description":"Whether the attribute can be used as a filter for the product grid in the PIM user interface"},"max_characters":{"type":"integer","description":"Number maximum of characters allowed for the value of the attribute when the attribute type is `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text`, `pim_catalog_textarea` or `pim_catalog_identifier` attribute types"},"validation_rule":{"type":"string","description":"Validation rule type used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Equal to `regexp` when the attribute type is equal to `pim_catalog_identifier`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"validation_regexp":{"type":"string","description":"Regexp expression used to validate any attribute value when the attribute type is `pim_catalog_text` or `pim_catalog_identifier`","x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `pim_catalog_text` or `pim_catalog_identifier` attribute types"},"wysiwyg_enabled":{"type":"boolean","description":"Whether the WYSIWYG interface is shown when the attribute type is `pim_catalog_textarea`","x-warning":"Only for `pim_catalog_textarea` attribute type"},"number_min":{"type":"string","description":"Minimum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"number_max":{"type":"string","description":"Maximum integer value allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `pim_catalog_metric`, `pim_catalog_price` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric`, `pim_catalog_price_collection` or `pim_catalog_number` attribute types"},"negative_allowed":{"type":"boolean","description":"Whether negative values are allowed when the attribute type is `pim_catalog_metric` or `pim_catalog_number`","x-warning":"Only for `pim_catalog_metric` or `pim_catalog_number` attribute types"},"metric_family":{"type":"string","description":"Metric family when the attribute type is `pim_catalog_metric`","x-immutable":true,"x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"default_metric_unit":{"type":"string","description":"Default metric unit when the attribute type is `pim_catalog_metric`","x-validation-rules":"Required for `pim_catalog_metric` attribute type","x-warning":"Only for `pim_catalog_metric` attribute type"},"date_min":{"type":"string","description":"Minimum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"date_max":{"type":"string","description":"Maximum date allowed when the attribute type is `pim_catalog_date`","x-validation-rules":"The datetime format follows the ISO-8601 norm","x-warning":"Only for `pim_catalog_date` attribute type","format":"date-time"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `pim_catalog_file` or `pim_catalog_image`","x-warning":"Only for `pim_catalog_file` or `pim_catalog_image` attribute types"},"reference_data_name":{"type":"string","description":"Reference entity code when the attribute type is `akeneo_reference_entity` or `akeneo_reference_entity_collection` OR Asset family code when the attribute type is `pim_catalog_asset_collection`","x-validation-rules":"Required only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types","x-warning":"Only for `akeneo_reference_entity` or `akeneo_reference_entity_collection` or `pim_catalog_asset_collection` attribute types"},"default_value":{"type":"boolean","description":"Default value for a Yes/No attribute, applied when creating a new product or product model (only available since the 5.0)","x-warning":"Only for `pim_catalog_boolean` attribute type"}},"example":{"code":"release_date","type":"pim_catalog_date","group":"marketing","group_labels":{"en_US":"Marketing","fr_FR":"Marketing"},"unique":false,"useable_as_grid_filter":true,"allowed_extensions":[],"metric_family":null,"default_metric_unit":null,"reference_data_name":null,"available_locales":[],"max_characters":null,"validation_rule":null,"validation_regexp":null,"wysiwyg_enabled":null,"number_min":null,"number_max":null,"decimals_allowed":null,"negative_allowed":null,"date_min":"2017-06-28T08:00:00","date_max":"2017-08-08T22:00:00","max_file_size":null,"minimum_input_length":null,"sort_order":1,"localizable":false,"scopable":false,"default_value":null,"labels":{"en_US":"Sale date","fr_FR":"Date des soldes"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/attributes/{attribute_code}/options":{"get":{"summary":"Get list of attribute options","operationId":"get_attributes__attribute_code__options","description":"This endpoint allows you to get a list of attribute options. Attribute options are paginated and sorted by code.","tags":["Attribute option"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return attribute options paginated","schema":{"title":"Attribute Options","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of option"},"attribute":{"type":"string","description":"Code of attribute related to the attribute option","x-validation-rules":"It is the same attribute code as the one given as path parameter"},"sort_order":{"type":"integer","description":"Order of attribute option","x-validation-rules":"It is a positive integer"},"labels":{"type":"object","description":"Attribute option labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute option label for the locale `localeCode`"}}}},"example":{"code":"black","attribute":"a_simple_select","sort_order":2,"labels":{"en_US":"Black","fr_FR":"Noir"}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/color/options?page=3&limit=3"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/color/options?page=1&limit=3"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/color/options?page=2&limit=3"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/color/options?page=4&limit=3"}},"current_page":3,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/color/options/red"}},"code":"red","attribute":"a_simple_select","sort_order":1,"labels":{"en_US":"Red","fr_FR":"Rouge"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/color/options/black"}},"code":"black","attribute":"a_simple_select","sort_order":2,"labels":{"en_US":"Black","fr_FR":"Noir"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attributes/color/options/purple"}},"code":"purple","attribute":"a_simple_select","sort_order":3,"labels":{"en_US":"Purple","fr_FR":"Violet"}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new attribute option","operationId":"post_attributes__attribute_code__options","description":"This endpoint allows you to create a new attribute option.","tags":["Attribute option"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"body","in":"body","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of option"},"attribute":{"type":"string","description":"Code of attribute related to the attribute option","x-validation-rules":"It is the same attribute code as the one given as path parameter"},"sort_order":{"type":"integer","description":"Order of attribute option","x-validation-rules":"It is a positive integer"},"labels":{"type":"object","description":"Attribute option labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute option label for the locale `localeCode`"}}}},"example":{"code":"black","attribute":"a_simple_select","sort_order":2,"labels":{"en_US":"Black","fr_FR":"Noir"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several attribute options","operationId":"patch_attributes__attribute_code__options","tags":["Attribute option"],"x-versions":["2.1","2.2","2.3","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update several attribute options at once.","x-body-by-line":"Contains several lines, each line is an attribute option in JSON standard format","parameters":[{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\":\"black\", \"attribute\":\"a_simple_select\", \"labels\":{\"en_US\": \"Black\",\"fr_FR\": \"Noir\"}}","x-example-2":"{\"code\":\"red\", \"label\":{\"en_US\": \"Red\",\"fr_FR\": \"Rouge\"}}","x-example-3":"{\"code\":\"yellow\", \"labels\":{\"en_US\": \"Yellow\",\"fr_FR\": \"Jaune\"}}"},"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of option"},"attribute":{"type":"string","description":"Code of attribute related to the attribute option","x-validation-rules":"It is the same attribute code as the one given as path parameter"},"sort_order":{"type":"integer","description":"Order of attribute option","x-validation-rules":"It is a positive integer"},"labels":{"type":"object","description":"Attribute option labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute option label for the locale `localeCode`"}}}},"example":{"code":"black","attribute":"a_simple_select","sort_order":2,"labels":{"en_US":"Black","fr_FR":"Noir"}}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"black\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"red\",\"status_code\":422,\"message\":\"Property \"label\" does not exist. Check the API format documentation.\"}","x-example-3":"{\"line\":3,\"code\":\"yellow\",\"status_code\":204}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/attributes/{attribute_code}/options/{code}":{"get":{"summary":"Get an attribute option","operationId":"get_attributes__attribute_code__options__code_","description":"This endpoint allows you to get the information about a given attribute option.","tags":["Attribute option"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the attribute option in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of option"},"attribute":{"type":"string","description":"Code of attribute related to the attribute option","x-validation-rules":"It is the same attribute code as the one given as path parameter"},"sort_order":{"type":"integer","description":"Order of attribute option","x-validation-rules":"It is a positive integer"},"labels":{"type":"object","description":"Attribute option labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute option label for the locale `localeCode`"}}}},"example":{"code":"black","attribute":"a_simple_select","sort_order":2,"labels":{"en_US":"Black","fr_FR":"Noir"}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an attribute option","operationId":"patch_attributes__attribute_code__options__code_","tags":["Attribute option"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given attribute option. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no attribute option exists for the given code, it creates it.","parameters":[{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of option"},"attribute":{"type":"string","description":"Code of attribute related to the attribute option","x-validation-rules":"It is the same attribute code as the one given as path parameter"},"sort_order":{"type":"integer","description":"Order of attribute option","x-validation-rules":"It is a positive integer"},"labels":{"type":"object","description":"Attribute option labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute option label for the locale `localeCode`"}}}},"example":{"code":"black","attribute":"a_simple_select","sort_order":2,"labels":{"en_US":"Black","fr_FR":"Noir"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/attribute-groups":{"get":{"summary":"Get list of attribute groups","operationId":"attribute_groups_get_list","description":"This endpoint allows you to get a list of attribute groups. Attribute groups are paginated and sorted by code.","tags":["Attribute group"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"search","in":"query","description":"Filter attribute groups, for more details see the <a href=\"/documentation/filter.html#filter-attribute-groups\">Filters</a> section.","required":false,"type":"string"},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return attribute groups paginated","schema":{"title":"Attribute groups","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute group code","x-immutable":true},"sort_order":{"type":"integer","description":"Attribute group order among other attribute groups","x-validation-rules":"It is a positive integer","default":0},"attributes":{"type":"array","description":"Attribute codes that compose the attribute group","x-validation-rules":"Each string of the array is an existing attribute code, an attribute can only be in one attribute group","items":{"type":"string"},"default":[]},"labels":{"type":"object","description":"Attribute group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute group label for the locale `localeCode`"}}}},"example":{"code":"marketing","sort_order":4,"attributes":["sku","name","description","response_time","release_date","price"],"labels":{"en_US":"Marketing","fr_FR":"Marketing"}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attribute-groups?page=3&limit=2"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/attribute-groups?page=1&limit=2"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/attribute-groups?page=2&limit=2"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/attribute-groups?page=4&limit=2"}},"current_page":3,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attribute-groups/marketing"}},"code":"marketing","sort_order":4,"attributes":["sku","name","description","response_time","release_date","price"],"labels":{"en_US":"Marketing","fr_FR":"Marketing"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/attribute-groups/technical"}},"code":"technical","sort_order":5,"attributes":["weight","maximum_scan_size","color_scanning","power_requirements","maximum_print_size","sensor_type","total_megapixels","optical_zoom","camera_type"],"labels":{"en_US":"Technical","fr_FR":"Technique"}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new attribute group","operationId":"attribute_groups_post","description":"This endpoint allows you to create a new attribute group.","tags":["Attribute group"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute group code","x-immutable":true},"sort_order":{"type":"integer","description":"Attribute group order among other attribute groups","x-validation-rules":"It is a positive integer","default":0},"attributes":{"type":"array","description":"Attribute codes that compose the attribute group","x-validation-rules":"Each string of the array is an existing attribute code, an attribute can only be in one attribute group","items":{"type":"string"},"default":[]},"labels":{"type":"object","description":"Attribute group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute group label for the locale `localeCode`"}}}},"example":{"code":"marketing","sort_order":4,"attributes":["sku","name","description","response_time","release_date","price"],"labels":{"en_US":"Marketing","fr_FR":"Marketing"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several attribute groups","operationId":"several_attribute_groups_patch","tags":["Attribute group"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update and/or create several attribute groups at once.","x-body-by-line":"Contains several lines, each line is an attribute group in JSON standard format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\":\"technical\",\"labels\":{\"en_US\": \"Technical\", \"fr_FR\": \"Technique\"}}","x-example-2":"{\"code\":\"marketing\",\"type\":\"bar\"}","x-example-3":"{\"code\":\"design\",\"sort_order\":7}"},"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute group code","x-immutable":true},"sort_order":{"type":"integer","description":"Attribute group order among other attribute groups","x-validation-rules":"It is a positive integer","default":0},"attributes":{"type":"array","description":"Attribute codes that compose the attribute group","x-validation-rules":"Each string of the array is an existing attribute code, an attribute can only be in one attribute group","items":{"type":"string"},"default":[]},"labels":{"type":"object","description":"Attribute group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute group label for the locale `localeCode`"}}}},"example":{"code":"marketing","sort_order":4,"attributes":["sku","name","description","response_time","release_date","price"],"labels":{"en_US":"Marketing","fr_FR":"Marketing"}}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"technical\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"marketing\",\"status_code\":422,\"message\":\"Property \\\"type\\\" does not exist. Check the standard format documentation.\",\"_links\":{\"documentation\":{\"href\":\"http:\\/\\/api.akeneo.com\\/api-reference.html#patch_attribute_groups__code_\"}","x-example-3":"{\"line\":3,\"code\":\"design\",\"status_code\":204}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/attribute-groups/{code}":{"get":{"summary":"Get an attribute group","operationId":"attribute_groups_get","description":"This endpoint allows you to get the information about a given attribute group.","tags":["Attribute group"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the attribute group in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute group code","x-immutable":true},"sort_order":{"type":"integer","description":"Attribute group order among other attribute groups","x-validation-rules":"It is a positive integer","default":0},"attributes":{"type":"array","description":"Attribute codes that compose the attribute group","x-validation-rules":"Each string of the array is an existing attribute code, an attribute can only be in one attribute group","items":{"type":"string"},"default":[]},"labels":{"type":"object","description":"Attribute group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute group label for the locale `localeCode`"}}}},"example":{"code":"marketing","sort_order":4,"attributes":["sku","name","description","response_time","release_date","price"],"labels":{"en_US":"Marketing","fr_FR":"Marketing"}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an attribute group","operationId":"attribute_groups_patch","tags":["Attribute group"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given attribute group. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no attribute group exists for the given code, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute group code","x-immutable":true},"sort_order":{"type":"integer","description":"Attribute group order among other attribute groups","x-validation-rules":"It is a positive integer","default":0},"attributes":{"type":"array","description":"Attribute codes that compose the attribute group","x-validation-rules":"Each string of the array is an existing attribute code, an attribute can only be in one attribute group","items":{"type":"string"},"default":[]},"labels":{"type":"object","description":"Attribute group labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute group label for the locale `localeCode`"}}}},"example":{"code":"marketing","sort_order":4,"attributes":["sku","name","description","response_time","release_date","price"],"labels":{"en_US":"Marketing","fr_FR":"Marketing"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/association-types":{"get":{"summary":"Get a list of association types","operationId":"association_types_get_list","description":"This endpoint allows you to get a list of association types. Association types are paginated and sorted by code.","tags":["Association type"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return association types paginated","schema":{"title":"Association types","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Association type code","x-immutable":true},"labels":{"type":"object","description":"Association type labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Association type label for the locale `localeCode`"}}},"is_quantified":{"type":"boolean","description":"When true, the association is a quantified association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true},"is_two_way":{"type":"boolean","description":"When true, the association is a two-way association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true}},"example":{"code":"upsell","labels":{"en_US":"Upsell","fr_FR":"Vente incitative"},"is_quantified":false,"is_two_way":false}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/association-types?page=1&limit=3"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/association-types?page=1&limit=3"}},"current_page":1,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/association-types/X_SELL"}},"code":"X_SELL","labels":{"en_US":"Cross sell","fr_FR":"Vente croisée"},"is_quantified":false,"is_two_way":false},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/association-types/UPSELL"}},"code":"UPSELL","labels":{"en_US":"Upsell","fr_FR":"Vente incitative"},"is_quantified":false,"is_two_way":false},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/association-types/SUBSTITUTION"}},"code":"SUBSTITUTION","labels":{"en_US":"Substitution","fr_FR":"Remplacement"},"is_quantified":false,"is_two_way":false}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new association type","operationId":"association_types_post","description":"This endpoint allows you to create a new association type.","tags":["Association type"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Association type code","x-immutable":true},"labels":{"type":"object","description":"Association type labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Association type label for the locale `localeCode`"}}},"is_quantified":{"type":"boolean","description":"When true, the association is a quantified association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true},"is_two_way":{"type":"boolean","description":"When true, the association is a two-way association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true}},"example":{"code":"upsell","labels":{"en_US":"Upsell","fr_FR":"Vente incitative"},"is_quantified":false,"is_two_way":false}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several association types","operationId":"several_association_types_patch","tags":["Association type"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update and/or create several association types at once.","x-body-by-line":"Contains several lines, each line is an association type in JSON standard format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\":\"new_sell\"}","x-example-2":"{\"code\":\"substitution\", \"type\":\"bar\"}","x-example-3":"{\"code\":\"x_cross_sell\", \"is_two_way\": true, \"is_quantified\": false}"},"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Association type code","x-immutable":true},"labels":{"type":"object","description":"Association type labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Association type label for the locale `localeCode`"}}},"is_quantified":{"type":"boolean","description":"When true, the association is a quantified association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true},"is_two_way":{"type":"boolean","description":"When true, the association is a two-way association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true}},"example":{"code":"upsell","labels":{"en_US":"Upsell","fr_FR":"Vente incitative"},"is_quantified":false,"is_two_way":false}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"new_sell\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"substitution\",\"status_code\":422,\"message\":\"Property \\\"type\\\" does not exist. Check the standard format documentation.\",\"_links\":{\"documentation\":{\"href\":\"http:\\/\\/api.akeneo.com\\/api-reference.html#patch_association_types__code_\"}","x-example-3":"{\"line\":3,\"code\":\"x_cross_sell\",\"status_code\":204}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/association-types/{code}":{"get":{"summary":"Get an association type","operationId":"association_types_get","description":"This endpoint allows you to get the information about a given association type.","tags":["Association type"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the association type in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Association type code","x-immutable":true},"labels":{"type":"object","description":"Association type labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Association type label for the locale `localeCode`"}}},"is_quantified":{"type":"boolean","description":"When true, the association is a quantified association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true},"is_two_way":{"type":"boolean","description":"When true, the association is a two-way association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true}},"example":{"code":"upsell","labels":{"en_US":"Upsell","fr_FR":"Vente incitative"},"is_quantified":false,"is_two_way":false}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an association type","operationId":"association_types_patch","tags":["Association type"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given association type. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no association type exists for the given code, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Association type code","x-immutable":true},"labels":{"type":"object","description":"Association type labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Association type label for the locale `localeCode`"}}},"is_quantified":{"type":"boolean","description":"When true, the association is a quantified association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true},"is_two_way":{"type":"boolean","description":"When true, the association is a two-way association (Only available in the PIM Serenity version.)","default":false,"x-immutable":true}},"example":{"code":"upsell","labels":{"en_US":"Upsell","fr_FR":"Vente incitative"},"is_quantified":false,"is_two_way":false}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/channels":{"get":{"summary":"Get a list of channels","operationId":"get_channels","description":"This endpoint allows you to get a list of channels. Channels are paginated and sorted by code.","tags":["Channel"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return channels paginated","schema":{"title":"Channels","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code","category_tree","locales","currencies"],"properties":{"code":{"type":"string","description":"Channel code","x-immutable":true},"locales":{"type":"array","description":"Codes of activated locales for the channel","x-validation-rules":"&bull; Each string of the array is an existing locale code &#10;&bull; At least one locale in the array","items":{"type":"string"}},"currencies":{"type":"array","description":"Codes of activated currencies for the channel","x-validation-rules":"&bull; Each string of the array is an existing currency code &#10;&bull; At least one currency in the array","items":{"type":"string"}},"category_tree":{"type":"string","description":"Code of the category tree linked to the channel","x-validation-rules":"It is the code of an existing category code that is a tree (a category without parent)"},"conversion_units":{"type":"object","description":"Units to which the given metric attributes should be converted when exporting products","x-validation-rules":"&bull; The `attributeCode` is the code of an existing attribute whose type is `pim_catalog_metric` &#10;&bull; The strings are existing unit codes.","properties":{"attributeCode":{"type":"string","description":"Conversion unit code used to convert the values of the attribute `attributeCode` when exporting via the channel"}}},"labels":{"type":"object","description":"Channel labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Channel label for the locale `localeCode`"}}}},"example":{"code":"ecommerce","currencies":["USD","EUR"],"locales":["de_DE","en_US","fr_FR"],"category_tree":"master","conversion_units":{"weight":"KILOGRAM"},"labels":{"en_US":"Ecommerce","de_DE":"Ecommerce","fr_FR":"Ecommerce"}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/channels?page=1&limit=3"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/channels?page=1&limit=3"}},"current_page":1,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/channels/ecommerce"}},"code":"ecommerce","currencies":["USD","EUR"],"locales":["en_US","fr_FR","de_DE"],"category_tree":"master","conversion_units":{"a_metric":"KILOWATT","a_metric_negative":"CELSIUS","a_metric_to_not_convert":null},"labels":{"en_US":"Ecommerce","fr_FR":"E-commerce","de_DE":"E-commerce"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/channels/mobile"}},"code":"mobile","currencies":["USD","EUR"],"locales":["en_US","fr_FR","de_DE"],"category_tree":"master","conversion_units":{"a_metric":"KILOWATT","a_metric_negative":"CELSIUS","a_metric_to_not_convert":null},"labels":{"en_US":"Mobile","fr_FR":"Mobile","de_DE":"Mobile"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/channels/print"}},"code":"print","currencies":["USD","EUR"],"locales":["en_US","fr_FR","de_DE"],"category_tree":"master","conversion_units":{},"labels":{"en_US":"Print","fr_FR":"Print","de_DE":"Print"}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new channel","operationId":"channels_post","description":"This endpoint allows you to create a new channel.","tags":["Channel"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["code","category_tree","locales","currencies"],"properties":{"code":{"type":"string","description":"Channel code","x-immutable":true},"locales":{"type":"array","description":"Codes of activated locales for the channel","x-validation-rules":"&bull; Each string of the array is an existing locale code &#10;&bull; At least one locale in the array","items":{"type":"string"}},"currencies":{"type":"array","description":"Codes of activated currencies for the channel","x-validation-rules":"&bull; Each string of the array is an existing currency code &#10;&bull; At least one currency in the array","items":{"type":"string"}},"category_tree":{"type":"string","description":"Code of the category tree linked to the channel","x-validation-rules":"It is the code of an existing category code that is a tree (a category without parent)"},"conversion_units":{"type":"object","description":"Units to which the given metric attributes should be converted when exporting products","x-validation-rules":"&bull; The `attributeCode` is the code of an existing attribute whose type is `pim_catalog_metric` &#10;&bull; The strings are existing unit codes.","properties":{"attributeCode":{"type":"string","description":"Conversion unit code used to convert the values of the attribute `attributeCode` when exporting via the channel"}}},"labels":{"type":"object","description":"Channel labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Channel label for the locale `localeCode`"}}}},"example":{"code":"ecommerce","currencies":["USD","EUR"],"locales":["de_DE","en_US","fr_FR"],"category_tree":"master","conversion_units":{"weight":"KILOGRAM"},"labels":{"en_US":"Ecommerce","de_DE":"Ecommerce","fr_FR":"Ecommerce"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several channels","operationId":"several_channels_patch","tags":["Channel"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update and/or create several channels at once.","x-body-by-line":"Contains several lines, each line is a channel in JSON standard format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\":\"ecommerce_fr\", \"category_tree\": \"master\", \"currencies\": [\"EUR\"], \"locales\": [\"fr_FR\"], \"labels\":{\"fr_FR\": \"Ecommerce Fr\"}}","x-example-2":"{\"code\":\"ecommerce_ch\", \"type\":\"bar\"}","x-example-3":"{\"code\":\"tablet\", \"labels\":{\"en_US\": \"Tablet\", \"fr_FR\": \"Tablette\"}}"},"type":"object","required":["code","category_tree","locales","currencies"],"properties":{"code":{"type":"string","description":"Channel code","x-immutable":true},"locales":{"type":"array","description":"Codes of activated locales for the channel","x-validation-rules":"&bull; Each string of the array is an existing locale code &#10;&bull; At least one locale in the array","items":{"type":"string"}},"currencies":{"type":"array","description":"Codes of activated currencies for the channel","x-validation-rules":"&bull; Each string of the array is an existing currency code &#10;&bull; At least one currency in the array","items":{"type":"string"}},"category_tree":{"type":"string","description":"Code of the category tree linked to the channel","x-validation-rules":"It is the code of an existing category code that is a tree (a category without parent)"},"conversion_units":{"type":"object","description":"Units to which the given metric attributes should be converted when exporting products","x-validation-rules":"&bull; The `attributeCode` is the code of an existing attribute whose type is `pim_catalog_metric` &#10;&bull; The strings are existing unit codes.","properties":{"attributeCode":{"type":"string","description":"Conversion unit code used to convert the values of the attribute `attributeCode` when exporting via the channel"}}},"labels":{"type":"object","description":"Channel labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Channel label for the locale `localeCode`"}}}},"example":{"code":"ecommerce","currencies":["USD","EUR"],"locales":["de_DE","en_US","fr_FR"],"category_tree":"master","conversion_units":{"weight":"KILOGRAM"},"labels":{"en_US":"Ecommerce","de_DE":"Ecommerce","fr_FR":"Ecommerce"}}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"ecommerce_fr\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"ecommerce_ch\",\"status_code\":422,\"message\":\"Property \\\"type\\\" does not exist. Check the standard format documentation.\",\"_links\":{\"documentation\":{\"href\":\"http:\\/\\/api.akeneo.com\\/api-reference.html#patch_channels__code_\"}","x-example-3":"{\"line\":3,\"code\":\"tablet\",\"status_code\":204}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/channels/{code}":{"get":{"summary":"Get a channel","operationId":"get_channels__code_","description":"This endpoint allows you to get the information about a given channel.","tags":["Channel"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the channel in JSON standard format","schema":{"type":"object","required":["code","category_tree","locales","currencies"],"properties":{"code":{"type":"string","description":"Channel code","x-immutable":true},"locales":{"type":"array","description":"Codes of activated locales for the channel","x-validation-rules":"&bull; Each string of the array is an existing locale code &#10;&bull; At least one locale in the array","items":{"type":"string"}},"currencies":{"type":"array","description":"Codes of activated currencies for the channel","x-validation-rules":"&bull; Each string of the array is an existing currency code &#10;&bull; At least one currency in the array","items":{"type":"string"}},"category_tree":{"type":"string","description":"Code of the category tree linked to the channel","x-validation-rules":"It is the code of an existing category code that is a tree (a category without parent)"},"conversion_units":{"type":"object","description":"Units to which the given metric attributes should be converted when exporting products","x-validation-rules":"&bull; The `attributeCode` is the code of an existing attribute whose type is `pim_catalog_metric` &#10;&bull; The strings are existing unit codes.","properties":{"attributeCode":{"type":"string","description":"Conversion unit code used to convert the values of the attribute `attributeCode` when exporting via the channel"}}},"labels":{"type":"object","description":"Channel labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Channel label for the locale `localeCode`"}}}},"example":{"code":"ecommerce","currencies":["USD","EUR"],"locales":["de_DE","en_US","fr_FR"],"category_tree":"master","conversion_units":{"weight":"KILOGRAM"},"labels":{"en_US":"Ecommerce","de_DE":"Ecommerce","fr_FR":"Ecommerce"}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a channel","operationId":"channels_patch","tags":["Channel"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given channel. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no channel exists for the given code, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code","category_tree","locales","currencies"],"properties":{"code":{"type":"string","description":"Channel code","x-immutable":true},"locales":{"type":"array","description":"Codes of activated locales for the channel","x-validation-rules":"&bull; Each string of the array is an existing locale code &#10;&bull; At least one locale in the array","items":{"type":"string"}},"currencies":{"type":"array","description":"Codes of activated currencies for the channel","x-validation-rules":"&bull; Each string of the array is an existing currency code &#10;&bull; At least one currency in the array","items":{"type":"string"}},"category_tree":{"type":"string","description":"Code of the category tree linked to the channel","x-validation-rules":"It is the code of an existing category code that is a tree (a category without parent)"},"conversion_units":{"type":"object","description":"Units to which the given metric attributes should be converted when exporting products","x-validation-rules":"&bull; The `attributeCode` is the code of an existing attribute whose type is `pim_catalog_metric` &#10;&bull; The strings are existing unit codes.","properties":{"attributeCode":{"type":"string","description":"Conversion unit code used to convert the values of the attribute `attributeCode` when exporting via the channel"}}},"labels":{"type":"object","description":"Channel labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Channel label for the locale `localeCode`"}}}},"example":{"code":"ecommerce","currencies":["USD","EUR"],"locales":["de_DE","en_US","fr_FR"],"category_tree":"master","conversion_units":{"weight":"KILOGRAM"},"labels":{"en_US":"Ecommerce","de_DE":"Ecommerce","fr_FR":"Ecommerce"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/locales":{"get":{"summary":"Get a list of locales","operationId":"get_locales","description":"This endpoint allows you to get a list of locales. Locales are paginated and sorted by code.","tags":["Locale"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return locales paginated","schema":{"title":"Locales","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Locale code","x-immutable":true},"enabled":{"type":"boolean","description":"Whether the locale is enabled","default":false}},"example":{"code":"en_US","enable":true}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/locales?page=2&limit=4"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/locales?page=1&limit=4"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/locales?page=1&limit=4"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/locales?page=2&limit=4"}},"current_page":2,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/locales/en_US"}},"code":"en_US","enabled":true},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/locales/fr_FR"}},"code":"fr_FR","enabled":true},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/locales/de_DE"}},"code":"de_DE","enabled":true},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/locales/af_ZA"}},"code":"af_ZA","enabled":false}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/locales/{code}":{"get":{"summary":"Get a locale","operationId":"get_locales__code_","description":"This endpoint allows you to get the information about a given locale.","tags":["Locale"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the locale in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Locale code","x-immutable":true},"enabled":{"type":"boolean","description":"Whether the locale is enabled","default":false}},"example":{"code":"en_US","enable":true}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/categories":{"get":{"summary":"Get list of categories","operationId":"get_categories","description":"This endpoint allows you to get a list of categories. Categories are paginated and sorted by `root/left`.","tags":["Category"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"search","in":"query","description":"Filter categories, for more details see the <a href=\"/documentation/filter.html#filter-categories\">Filters</a> section.","required":false,"type":"string"},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return categories paginated","schema":{"title":"Categories","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Category code","x-immutable":true},"parent":{"type":"string","description":"Category code of the parent's category","x-validation-rules":"&bull; It is either equal to `null` or to an existing category code. &#10;&bull; If equal to an existing category code, it cannot reference itself.","default":"null"},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"labels":{"type":"object","description":"Category labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Category label for the locale `localeCode`"}}}},"example":{"code":"winter_collection","parent":null,"updated":"2021-05-22T12:48:00+02:00","labels":{"en_US":"Winter collection","fr_FR":"Collection hiver"}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/categories?page=2&limit=5"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/categories?page=1&limit=5"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/categories?page=1&limit=5"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/categories?page=3&limit=5"}},"current_page":2,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/categories/winter_collection"}},"code":"winter_collection","parent":null,"updated":"2021-05-21T11:32:00+02:00","labels":{"en_US":"Winter collection","fr_FR":"Collection hiver","de_DE":"Winter-Kollektion"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/categories/woman"}},"code":"woman","parent":"winter_collection","updated":"2021-04-21T10:41:02+02:00","labels":{"en_US":"Woman","fr_FR":"Femme","de_DE":"Damen"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/categories/man"}},"code":"man","parent":"winter_collection","updated":"2021-03-02T12:59:59+02:00","labels":{"en_US":"Man","fr_FR":"Homme","de_DE":"Herren"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/categories/kids"}},"code":"kids","parent":"winter_collection","updated":"2021-01-03T12:40:00+02:00","labels":{"en_US":"Kids","fr_FR":"Enfant","de_DE":"Kinder"}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/categories/summer_collection"}},"code":"summer_collection","parent":null,"updated":"2021-04-04T09:42:00+02:00","labels":{"en_US":"Summer collection","fr_FR":"Collection été","de_DE":"Sommer-Kollektion"}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new category","operationId":"post_categories","description":"This endpoint allows you to create a new category.","tags":["Category"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Category code","x-immutable":true},"parent":{"type":"string","description":"Category code of the parent's category","x-validation-rules":"&bull; It is either equal to `null` or to an existing category code. &#10;&bull; If equal to an existing category code, it cannot reference itself.","default":"null"},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"labels":{"type":"object","description":"Category labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Category label for the locale `localeCode`"}}}},"example":{"code":"winter_collection","parent":null,"updated":"2021-05-22T12:48:00+02:00","labels":{"en_US":"Winter collection","fr_FR":"Collection hiver"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several categories","operationId":"patch_categories","tags":["Category"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update several categories at once.","x-body-by-line":"Contains several lines, each line is a category in JSON standard format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\":\"spring_collection\",\"parent\":null}","x-example-2":"{\"code\":\"woman\",\"parent\":\"spring_collectionn\"}","x-example-3":"{\"code\":\"man\",\"parent\":\"spring_collection\"}"},"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Category code","x-immutable":true},"parent":{"type":"string","description":"Category code of the parent's category","x-validation-rules":"&bull; It is either equal to `null` or to an existing category code. &#10;&bull; If equal to an existing category code, it cannot reference itself.","default":"null"},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"labels":{"type":"object","description":"Category labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Category label for the locale `localeCode`"}}}},"example":{"code":"winter_collection","parent":null,"updated":"2021-05-22T12:48:00+02:00","labels":{"en_US":"Winter collection","fr_FR":"Collection hiver"}}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"spring_collection\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"woman\",\"status_code\":422,\"message\":\"Category \"spring_collectionn\" does not exist.\"}","x-example-3":"{\"line\":3,\"code\":\"man\",\"status_code\":204}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/categories/{code}":{"get":{"summary":"Get a category","operationId":"get_categories__code_","description":"This endpoint allows you to get the information about a given category.","tags":["Category"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the category in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Category code","x-immutable":true},"parent":{"type":"string","description":"Category code of the parent's category","x-validation-rules":"&bull; It is either equal to `null` or to an existing category code. &#10;&bull; If equal to an existing category code, it cannot reference itself.","default":"null"},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"labels":{"type":"object","description":"Category labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Category label for the locale `localeCode`"}}}},"example":{"code":"winter_collection","parent":null,"updated":"2021-05-22T12:48:00+02:00","labels":{"en_US":"Winter collection","fr_FR":"Collection hiver"}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a category","operationId":"patch_categories__code_","tags":["Category"],"x-versions":["1.7","2.x","3.x","4.0","5.0","SaaS"],"description":"This endpoint allows you to update a given category. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no category exists for the given code, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Category code","x-immutable":true},"parent":{"type":"string","description":"Category code of the parent's category","x-validation-rules":"&bull; It is either equal to `null` or to an existing category code. &#10;&bull; If equal to an existing category code, it cannot reference itself.","default":"null"},"updated":{"type":"string","description":"Date of the last update","format":"dateTime","x-read-only":true},"labels":{"type":"object","description":"Category labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Category label for the locale `localeCode`"}}}},"example":{"code":"winter_collection","parent":null,"updated":"2021-05-22T12:48:00+02:00","labels":{"en_US":"Winter collection","fr_FR":"Collection hiver"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/currencies":{"get":{"summary":"Get a list of currencies","operationId":"currencies_get_list","description":"This endpoint allows you to get a list of currencies. Currencies are paginated and sorted by code.","tags":["Currency"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Return currencies paginated","schema":{"title":"Currencies","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Currency code","x-immutable":true},"enabled":{"type":"boolean","description":"Whether the currency is enabled"}},"example":{"code":"EUR","enabled":true}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/currencies?page=1&limit=3"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/currencies?page=1&limit=3"}},"current_page":1,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/currencies/ADP"}},"code":"ADP","enabled":true},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/currencies/AED"}},"code":"AED","enabled":true},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/currencies/AFA"}},"code":"AFA","enabled":false}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/currencies/{code}":{"get":{"summary":"Get a currency","operationId":"currencies_get","description":"This endpoint allows you to get the information about a given currency.","tags":["Currency"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the currency in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Currency code","x-immutable":true},"enabled":{"type":"boolean","description":"Whether the currency is enabled"}},"example":{"code":"EUR","enabled":true}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/measure-families":{"get":{"summary":"Get list of measure familiy","operationId":"measure_families_get_list","description":"This endpoint allows you to get a list of measure families. Measure families are paginated and sorted by code.","tags":["Measure family"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"responses":{"200":{"description":"Return measure families paginated","schema":{"title":"Measure Families","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Measure family code","x-immutable":true},"standard":{"type":"string","description":"Measure family standard","x-immutable":true},"units":{"type":"array","description":"Family units","items":{"type":"object","properties":{"code":{"type":"string","description":"Measure code","x-immutable":true},"convert":{"type":"object","description":"Mathematic operation to convert the unit into the standard unit"},"symbol":{"type":"string","description":"Measure symbol","x-immutable":true}}}}},"example":{"code":"Area","standard":"SQUARE_METER","units":[{"code":"SQUARE_MILLIMETER","convert":{"mul":"0.001"},"symbol":"mm²"},{"code":"SQUARE_CENTIMETER","convert":{"mul":"0.001"},"symbol":"cm²"}]}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/measure-families?page=1&limit=1"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/measure-families?page=1&limit=1"}},"current_page":1,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/measure-families/Area"}},"code":"Area","standard":"SQUARE_METER","units":[{"code":"SQUARE_MILLIMETER","convert":{"mul":"0.000001"},"symbol":"mm²"},{"code":"SQUARE_CENTIMETER","convert":{"mul":"0.0001"},"symbol":"cm²"},{"code":"SQUARE_DECIMETER","convert":{"mul":"0.01"},"symbol":"dm²"},{"code":"SQUARE_METER","convert":{"mul":"1"},"symbol":"m²"},{"code":"CENTIARE","convert":{"mul":"1"},"symbol":"ca"},{"code":"SQUARE_DEKAMETER","convert":{"mul":"100"},"symbol":"dam²"},{"code":"ARE","convert":{"mul":"100"},"symbol":"a"},{"code":"SQUARE_HECTOMETER","convert":{"mul":"10000"},"symbol":"hm²"}]}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/measure-families/{code}":{"get":{"summary":"Get a measure family","operationId":"measure_families_get","description":"This endpoint allows you to get the information about a given measure family.","tags":["Measure family"],"x-versions":["2.x","3.x","4.0","5.0","SaaS"],"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the measure family in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Measure family code","x-immutable":true},"standard":{"type":"string","description":"Measure family standard","x-immutable":true},"units":{"type":"array","description":"Family units","items":{"type":"object","properties":{"code":{"type":"string","description":"Measure code","x-immutable":true},"convert":{"type":"object","description":"Mathematic operation to convert the unit into the standard unit"},"symbol":{"type":"string","description":"Measure symbol","x-immutable":true}}}}},"example":{"code":"Area","standard":"SQUARE_METER","units":[{"code":"SQUARE_MILLIMETER","convert":{"mul":"0.001"},"symbol":"mm²"},{"code":"SQUARE_CENTIMETER","convert":{"mul":"0.001"},"symbol":"cm²"}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/measurement-families":{"get":{"summary":"Get list of measurement families","operationId":"measurement_families_get_list","description":"This endpoint allows you to get a list of measurement families.","tags":["Measurement family"],"x-versions":["5.0","SaaS"],"responses":{"200":{"description":"Return the measurement families","x-no-entity":true,"schema":{"type":"object","required":["code","standard_unit_code","units"],"properties":{"code":{"type":"string","description":"Measurement family code","x-immutable":true},"labels":{"type":"object","description":"Measurement family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Measurement family label for the locale `localeCode`"}}},"standard_unit_code":{"type":"string","description":"Unit code used as the standard unit for this measurement family","x-immutable":true,"x-validation-rules":"The unit code exists in the list of the property `units`"},"units":{"type":"object","description":"Measurement units for this family with their conversion operations. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>.","x-validation-rules":"A unit can't be added when a product attribute is linked to this measurement family","properties":{"unitCode":{"type":"object","properties":{"code":{"type":"string","description":"Measurement unit code. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>.","x-immutable":true},"labels":{"type":"object","description":"Unit labels for each locale. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>.","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Unit label for the locale `localeCode`"}}},"convert_from_standard":{"type":"array","description":"Calculation to convert the unit into the standard unit. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>.","x-validation-rules":"&bull; The conversion operations can't be updated when a product attribute is linked to this measurement family &#10;&bull; At least one conversion operation per unit is required","items":{"type":"object","properties":{"operator":{"type":"string","description":"Operator for a conversion operation to convert the unit in the standard unit","x-validation-rules":"The operator is one of the following values","enum":["mul","div","add","sub"]},"value":{"type":"string","description":"Value for a conversion operation to convert the unit in the standard unit"}}}},"symbol":{"type":"string","description":"Measurement unit symbol. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>."}}}}}},"example":{"code":"AREA","labels":{"en_US":"Area","fr_FR":"Surface"},"standard_unit_code":"SQUARE_METER","units":{"SQUARE_MILLIMETER":{"code":"SQUARE_MILLIMETER","labels":{"en_US":"Square millimeter","fr_FR":"Millimètre carré"},"convert_from_standard":[{"operator":"mul","value":"0.000001"}],"symbol":"mm²"},"SQUARE_CENTIMETER":{"code":"SQUARE_CENTIMETER","labels":{"en_US":"Square centimeter","fr_FR":"Centimètre carré"},"convert_from_standard":[{"operator":"mul","value":"0.0001"}],"symbol":"cm²"},"SQUARE_METER":{"code":"SQUARE_METER","labels":{"en_US":"Square meter","fr_FR":"Mètre carré"},"convert_from_standard":[{"operator":"mul","value":"1"}],"symbol":"m²"}}}},"x-examples":[{"code":"AREA","labels":{"en_US":"Area","fr_FR":"Surface"},"standard_unit_code":"SQUARE_METER","units":{"SQUARE_MILLIMETER":{"code":"SQUARE_MILLIMETER","labels":{"en_US":"Square millimeter","fr_FR":"Millimètre carré"},"convert_from_standard":[{"operator":"mul","value":"0.000001"}],"symbol":"mm²"},"SQUARE_CENTIMETER":{"code":"SQUARE_CENTIMETER","labels":{"en_US":"Square centimeter","fr_FR":"Centimètre carré"},"convert_from_standard":[{"operator":"mul","value":"0.0001"}],"symbol":"cm²"},"SQUARE_METER":{"code":"SQUARE_METER","labels":{"en_US":"Square meter","fr_FR":"Mètre carré"},"convert_from_standard":[{"operator":"mul","value":"1"}],"symbol":"m²"}}}]},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create several measurement families","operationId":"patch_measurement_families","tags":["Measurement family"],"x-versions":["5.0","SaaS"],"description":"This endpoint allows you to update and/or create several measurement families at once.","parameters":[{"name":"body","in":"body","schema":{"type":"array","items":{"type":"object","required":["code","standard_unit_code","units"],"properties":{"code":{"type":"string","description":"Measurement family code","x-immutable":true},"labels":{"type":"object","description":"Measurement family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Measurement family label for the locale `localeCode`"}}},"standard_unit_code":{"type":"string","description":"Unit code used as the standard unit for this measurement family","x-immutable":true,"x-validation-rules":"The unit code exists in the list of the property `units`"},"units":{"type":"object","description":"Measurement units for this family with their conversion operations. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>.","x-validation-rules":"A unit can't be added when a product attribute is linked to this measurement family","properties":{"unitCode":{"type":"object","properties":{"code":{"type":"string","description":"Measurement unit code. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>.","x-immutable":true},"labels":{"type":"object","description":"Unit labels for each locale. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>.","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Unit label for the locale `localeCode`"}}},"convert_from_standard":{"type":"array","description":"Calculation to convert the unit into the standard unit. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>.","x-validation-rules":"&bull; The conversion operations can't be updated when a product attribute is linked to this measurement family &#10;&bull; At least one conversion operation per unit is required","items":{"type":"object","properties":{"operator":{"type":"string","description":"Operator for a conversion operation to convert the unit in the standard unit","x-validation-rules":"The operator is one of the following values","enum":["mul","div","add","sub"]},"value":{"type":"string","description":"Value for a conversion operation to convert the unit in the standard unit"}}}},"symbol":{"type":"string","description":"Measurement unit symbol. More details <a href='/concepts/target-market-settings.html#focus-on-the-units'>here</a>."}}}}}},"example":{"code":"AREA","labels":{"en_US":"Area","fr_FR":"Surface"},"standard_unit_code":"SQUARE_METER","units":{"SQUARE_MILLIMETER":{"code":"SQUARE_MILLIMETER","labels":{"en_US":"Square millimeter","fr_FR":"Millimètre carré"},"convert_from_standard":[{"operator":"mul","value":"0.000001"}],"symbol":"mm²"},"SQUARE_CENTIMETER":{"code":"SQUARE_CENTIMETER","labels":{"en_US":"Square centimeter","fr_FR":"Centimètre carré"},"convert_from_standard":[{"operator":"mul","value":"0.0001"}],"symbol":"cm²"},"SQUARE_METER":{"code":"SQUARE_METER","labels":{"en_US":"Square meter","fr_FR":"Mètre carré"},"convert_from_standard":[{"operator":"mul","value":"1"}],"symbol":"m²"}}}},"example":[{"code":"AREA","labels":{"en_US":"Area","fr_FR":"Surface"},"standard_unit_code":"SQUARE_METER","units":{"SQUARE_MILLIMETER":{"code":"SQUARE_MILLIMETER","labels":{"en_US":"Square millimeter","fr_FR":"Millimètre carré"},"convert_from_standard":[{"operator":"mul","value":"0.000001"}],"symbol":"mm²"},"SQUARE_CENTIMETER":{"code":"SQUARE_CENTIMETER","labels":{"en_US":"Square centimeter","fr_FR":"Centimètre carré"},"convert_from_standard":[{"operator":"mul","value":"0.0001"}],"symbol":"cm²"},"SQUARE_METER":{"code":"SQUARE_METER","labels":{"en_US":"Square meter","fr_FR":"Mètre carré"},"convert_from_standard":[{"operator":"mul","value":"1"}],"symbol":"m²"}}}]}}],"responses":{"200":{"description":"OK","x-details":"Returns a JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string","description":"Resource code"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"},"errors":{"type":"array","description":"List of errors","items":{"type":"object","properties":{"property":{"type":"string"},"message":{"type":"string"}}}}}}},"x-examples":[{"code":"Angle","status_code":201},{"code":"Force","status_code":204},{"code":"Area","status_code":422,"message":"The measurement family has data that does not comply with the business rules.","errors":[{"property":"standard_unit_code","message":"The standard unit code of the \"Angle\" measurement family cannot be changed"}]}]},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/reference-entities":{"get":{"summary":"Get list of reference entities","operationId":"get_reference_entities","description":"This endpoint allows you to get a list of reference entities. Reference entities are paginated.","tags":["Reference entity"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"search_after","in":"query","description":"Cursor when using the `search_after` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"cursor to the first page"}],"responses":{"200":{"description":"Return reference entities paginated","schema":{"title":"Reference Entities","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}},"image_download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the binaries of the reference entity image file"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Reference entity code","x-immutable":true},"labels":{"type":"object","description":"Reference entity labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Reference entity label for the locale `localeCode`"}}},"image":{"type":"string","description":"Code of the reference entity image","default":null}},"example":{"code":"brands","labels":{"en_US":"Brands","fr_FR":"Marques"},"image":"0/2/d/6/54d81dc888ba1501a8g765f3ab5797569f3bv756c_ref_img.png"}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities?search_after=2x055w%3D%3D"}},"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/brands"},"image_download":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities-media-files/0/2/d/6/54d81dc888ba1501a8g765f3ab5797569f3bv756c_ref_img.png"}},"code":"brands","labels":{"en_US":"Brands","fr_FR":"Marque"},"image":"0/2/d/6/54d81dc888ba1501a8g765f3ab5797569f3bv756c_ref_img.png"},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/designers"}},"code":"designers","labels":{"en_US":"Designers","fr_FR":"Designers"},"image":null},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/colors"}},"code":"colors","labels":{"en_US":"Colors","fr_FR":"Couleurs"},"image":null}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/reference-entities/{code}":{"get":{"summary":"Get a reference entity","operationId":"get_reference_entities__code_","tags":["Reference entity"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given reference entity.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the reference entity in JSON format.","schema":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","x-read-only":true,"properties":{"image_download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the binaries of the reference entity image file"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Reference entity code","x-immutable":true},"labels":{"type":"object","description":"Reference entity labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Reference entity label for the locale `localeCode`"}}},"image":{"type":"string","description":"Code of the reference entity image","default":null}},"example":{"code":"brands","labels":{"en_US":"Brands","fr_FR":"Marques"},"image":"0/2/d/6/54d81dc888ba1501a8g765f3ab5797569f3bv756c_ref_img.png"}}],"example":{"_links":{"image_download":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities-media-files/0/2/d/6/54d81dc888ba1501a8g765f3ab5797569f3bv756c_ref_img.png"}},"code":"brands","labels":{"en_US":"Brands","fr_FR":"Marques"},"image":"0/2/d/6/54d81dc888ba1501a8g765f3ab5797569f3bv756c_ref_img.png"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a reference entity","operationId":"patch_reference_entity__code_","tags":["Reference entity"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update a given reference entity. Note that if the reference entity does not already exist, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Reference entity code","x-immutable":true},"labels":{"type":"object","description":"Reference entity labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Reference entity label for the locale `localeCode`"}}},"image":{"type":"string","description":"Code of the reference entity image","default":null}},"example":{"code":"brands","labels":{"en_US":"Brands","fr_FR":"Marques"},"image":"0/2/d/6/54d81dc888ba1501a8g765f3ab5797569f3bv756c_ref_img.png"}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/reference-entities/{reference_entity_code}/attributes":{"get":{"summary":"Get the list of attributes of a given reference entity","operationId":"get_reference_entities__code__attributes","description":"This endpoint allows you to get the list of attributes of a given reference entity.","tags":["Reference entity attribute"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"}],"responses":{"200":{"description":"Return the attributes of the given reference entity","x-no-entity":true,"schema":{"type":"array","items":{"type":"object","required":["code","type"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"type":{"type":"string","description":"Attribute type","enum":["text","image","number","single_option","multiple_options","reference_entity_single_link","reference_entity_multiple_links"],"x-immutable":true},"value_per_locale":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"value_per_channel":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"is_required_for_completeness":{"type":"boolean","description":"Whether the attribute should be part of the record's completeness calculation","default":false},"max_characters":{"type":"integer","description":"Maximum number of characters allowed for the value of the attribute when the attribute type is `text`","x-warning":"Only for `text` attribute type"},"is_textarea":{"type":"boolean","description":"Whether the UI should display a text area instead of a simple field when the attribute type is `text`","default":false,"x-warning":"Only for `text` attribute type"},"is_rich_text_editor":{"type":"boolean","description":"Whether the UI should display a rich text editor instead of a simple text area when the attribute type is `text`","x-validation-rules":"Required when the property `is_textarea` is equal to `true`","x-warning":"Only for `text` attribute type"},"validation_rule":{"type":"string","description":"Validation rule type used to validate the attribute value when the attribute type is `text`","default":"none","x-warning":"Only for `text` attribute type","enum":["email","url","regexp","none"]},"validation_regexp":{"type":"string","description":"Regexp expression used to validate the attribute value when the attribute type is `text`","default":null,"x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `text` attribute type"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `image`","default":[],"x-warning":"Only for `image` attribute type","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `image`","default":null,"x-warning":"Only for `image` attribute type"},"reference_entity_code":{"type":"string","description":"Code of the linked reference entity when the attribute type is `reference_entity_single_link` or `reference_entity_multiple_links`","default":null,"x-validation-rules":"Required when the attribute type is either `reference_entity_single_link` or `reference_entity_multiple_links`","x-warning":"Only for `reference_entity_single_link` and `reference_entity_multiple_links` attribute type","x-immutable":true},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `number`","default":false,"x-warning":"Only for `number` attribute type"},"min_value":{"type":"string","description":"Minimum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The minimum value must be lower than the maximum value","x-warning":"Only for `number` attribute type"},"max_value":{"type":"string","description":"Maximum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The maximum value must be greater than the minimum value","x-warning":"Only for `number` attribute type"}},"example":{"code":"description","labels":{"en_US":"Description","fr_FR":"Description"},"type":"text","value_per_locale":true,"value_per_channel":false,"is_required_for_completeness":true,"max_characters":null,"is_textarea":true,"is_rich_text_editor":true,"validation_rule":"none","validation_regexp":null}}},"x-examples":[{"code":"description","labels":{"en_US":"Description","fr_FR":"Description"},"type":"text","value_per_locale":true,"value_per_channel":false,"is_required_for_completeness":true,"max_characters":null,"is_textarea":true,"is_rich_text_editor":true,"validation_rule":"none","validation_regexp":null},{"code":"country","labels":{"en_US":"Country","fr_FR":"Pays"},"type":"text","value_per_locale":false,"value_per_channel":false,"is_required_for_completeness":false},{"code":"creation_year","labels":{"en_US":"Creation year","fr_FR":"Année de création"},"type":"number","value_per_locale":false,"value_per_channel":false,"is_required_for_completeness":false,"decimals_allowed":false,"min_value":"1800","max_value":"2100"},{"code":"collection_overview","labels":{"en_US":"Collection overview","fr_FR":"Aperçu de la collection"},"type":"image","value_per_locale":true,"value_per_channel":false,"is_required_for_completeness":true,"allowed_extensions":["png"],"max_file_size":"1000"}]},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/reference-entities/{reference_entity_code}/attributes/{code}":{"get":{"summary":"Get an attribute of a given reference entity","operationId":"get_reference_entity_attributes__code_","tags":["Reference entity attribute"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given attribute for a given reference entity.","parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the reference entity attribute in JSON format","schema":{"type":"object","required":["code","type"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"type":{"type":"string","description":"Attribute type","enum":["text","image","number","single_option","multiple_options","reference_entity_single_link","reference_entity_multiple_links"],"x-immutable":true},"value_per_locale":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"value_per_channel":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"is_required_for_completeness":{"type":"boolean","description":"Whether the attribute should be part of the record's completeness calculation","default":false},"max_characters":{"type":"integer","description":"Maximum number of characters allowed for the value of the attribute when the attribute type is `text`","x-warning":"Only for `text` attribute type"},"is_textarea":{"type":"boolean","description":"Whether the UI should display a text area instead of a simple field when the attribute type is `text`","default":false,"x-warning":"Only for `text` attribute type"},"is_rich_text_editor":{"type":"boolean","description":"Whether the UI should display a rich text editor instead of a simple text area when the attribute type is `text`","x-validation-rules":"Required when the property `is_textarea` is equal to `true`","x-warning":"Only for `text` attribute type"},"validation_rule":{"type":"string","description":"Validation rule type used to validate the attribute value when the attribute type is `text`","default":"none","x-warning":"Only for `text` attribute type","enum":["email","url","regexp","none"]},"validation_regexp":{"type":"string","description":"Regexp expression used to validate the attribute value when the attribute type is `text`","default":null,"x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `text` attribute type"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `image`","default":[],"x-warning":"Only for `image` attribute type","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `image`","default":null,"x-warning":"Only for `image` attribute type"},"reference_entity_code":{"type":"string","description":"Code of the linked reference entity when the attribute type is `reference_entity_single_link` or `reference_entity_multiple_links`","default":null,"x-validation-rules":"Required when the attribute type is either `reference_entity_single_link` or `reference_entity_multiple_links`","x-warning":"Only for `reference_entity_single_link` and `reference_entity_multiple_links` attribute type","x-immutable":true},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `number`","default":false,"x-warning":"Only for `number` attribute type"},"min_value":{"type":"string","description":"Minimum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The minimum value must be lower than the maximum value","x-warning":"Only for `number` attribute type"},"max_value":{"type":"string","description":"Maximum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The maximum value must be greater than the minimum value","x-warning":"Only for `number` attribute type"}},"example":{"code":"description","labels":{"en_US":"Description","fr_FR":"Description"},"type":"text","value_per_locale":true,"value_per_channel":false,"is_required_for_completeness":true,"max_characters":null,"is_textarea":true,"is_rich_text_editor":true,"validation_rule":"none","validation_regexp":null}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an attribute of a given reference entity","operationId":"patch_reference_entity_attributes__code_","tags":["Reference entity attribute"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update a given attribute for a given renference entity. Note that if the attribute does not already exist for the given reference entity, it creates it.","parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code","type"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"type":{"type":"string","description":"Attribute type","enum":["text","image","number","single_option","multiple_options","reference_entity_single_link","reference_entity_multiple_links"],"x-immutable":true},"value_per_locale":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"value_per_channel":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"is_required_for_completeness":{"type":"boolean","description":"Whether the attribute should be part of the record's completeness calculation","default":false},"max_characters":{"type":"integer","description":"Maximum number of characters allowed for the value of the attribute when the attribute type is `text`","x-warning":"Only for `text` attribute type"},"is_textarea":{"type":"boolean","description":"Whether the UI should display a text area instead of a simple field when the attribute type is `text`","default":false,"x-warning":"Only for `text` attribute type"},"is_rich_text_editor":{"type":"boolean","description":"Whether the UI should display a rich text editor instead of a simple text area when the attribute type is `text`","x-validation-rules":"Required when the property `is_textarea` is equal to `true`","x-warning":"Only for `text` attribute type"},"validation_rule":{"type":"string","description":"Validation rule type used to validate the attribute value when the attribute type is `text`","default":"none","x-warning":"Only for `text` attribute type","enum":["email","url","regexp","none"]},"validation_regexp":{"type":"string","description":"Regexp expression used to validate the attribute value when the attribute type is `text`","default":null,"x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `text` attribute type"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `image`","default":[],"x-warning":"Only for `image` attribute type","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `image`","default":null,"x-warning":"Only for `image` attribute type"},"reference_entity_code":{"type":"string","description":"Code of the linked reference entity when the attribute type is `reference_entity_single_link` or `reference_entity_multiple_links`","default":null,"x-validation-rules":"Required when the attribute type is either `reference_entity_single_link` or `reference_entity_multiple_links`","x-warning":"Only for `reference_entity_single_link` and `reference_entity_multiple_links` attribute type","x-immutable":true},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `number`","default":false,"x-warning":"Only for `number` attribute type"},"min_value":{"type":"string","description":"Minimum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The minimum value must be lower than the maximum value","x-warning":"Only for `number` attribute type"},"max_value":{"type":"string","description":"Maximum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The maximum value must be greater than the minimum value","x-warning":"Only for `number` attribute type"}},"example":{"code":"description","labels":{"en_US":"Description","fr_FR":"Description"},"type":"text","value_per_locale":true,"value_per_channel":false,"is_required_for_completeness":true,"max_characters":null,"is_textarea":true,"is_rich_text_editor":true,"validation_rule":"none","validation_regexp":null}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/reference-entities/{reference_entity_code}/attributes/{attribute_code}/options":{"get":{"summary":"Get a list of attribute options of a given attribute for a given reference entity","operationId":"get_reference_entity_attributes__attribute_code__options","description":"This endpoint allows you to get a list of attribute options for a given reference entity.","tags":["Reference entity attribute option"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"}],"responses":{"200":{"description":"Return the options of the given attributes of the given reference entity","x-no-entity":true,"schema":{"type":"array","items":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute's option code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}}},"example":{"code":"global_nomad","labels":{"en_US":"Global Nomad","fr_FR":"Nomade du Monde"}}}},"x-examples":[{"code":"woodland_retreat","labels":{"en_US":"Woodland Retreat","fr_FR":"Retraite dans les Bois"}},{"code":"new_nordic","labels":{"en_US":"New Nordic","fr_FR":"Renouveau Scandinave"}},{"code":"global_nomad","labels":{"en_US":"Global Nomad","fr_FR":"Nomade du Monde"}}]},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/reference-entities/{reference_entity_code}/attributes/{attribute_code}/options/{code}":{"get":{"summary":"Get an attribute option for a given attribute of a given reference entity","operationId":"get_reference_entity_attributes__attribute_code__options__code_","description":"This endpoint allows you to get the information about a given attribute option.","tags":["Reference entity attribute option"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the reference entity attribute option in JSON format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute's option code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}}},"example":{"code":"global_nomad","labels":{"en_US":"Global Nomad","fr_FR":"Nomade du Monde"}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a reference entity attribute option","operationId":"patch_reference_entity_attributes__attribute_code__options__code_","tags":["Reference entity attribute option"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update a given option for a given attribute and a given reference entity. Learn more about <a href=\"/documentation/update.html#patch-reference-entity-record-values\">Update behavior</a>. Note that if the option does not already exist for the given attribute of the given reference entity, it creates it.","parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute's option code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}}},"example":{"code":"global_nomad","labels":{"en_US":"Global Nomad","fr_FR":"Nomade du Monde"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/reference-entities/{reference_entity_code}/records":{"get":{"summary":"Get the list of the records of a reference entity","operationId":"get_reference_entity_records","tags":["Reference entity record"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get a list of records of a given reference entity. Records are paginated and can be filtered.","parameters":[{"name":"search","in":"query","description":"Filter records of the reference entity, for more details see the <a href=\"/documentation/filter.html#filter-reference-entity-records\">Filters</a> section","required":false,"type":"string"},{"name":"channel","in":"query","type":"string","description":"Filter attribute values to return scopable attributes for the given channel as well as the non localizable/non scopable attributes, for more details see the <a href=\"/documentation/filter.html#filter-attribute-values-by-channel\">Filter attribute values by channel</a> section","required":false},{"name":"locales","in":"query","type":"string","description":"Filter attribute values to return localizable attributes for the given locales as well as the non localizable/non scopable attributes, for more details see the <a href=/documentation/filter.html#filter-attribute-values-by-locale\">Filter attribute values by locale</a> section","required":false},{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"search_after","in":"query","description":"Cursor when using the `search_after` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"cursor to the first page"}],"responses":{"200":{"description":"Return the records of the given reference entity paginated","schema":{"title":"Reference entity record","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of the record","x-immutable":true},"values":{"type":"object","description":"Record attributes values, see <a href='/concepts/reference-entities.html#focus-on-the-reference-entity-record-values'>Reference entity record values</a> section for more details","x-validation-rules":"Validation rules detailed in Reference entity record values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel code of the reference entity record value"},"locale":{"type":"string","description":"Locale code of the reference entity record value"},"data":{"type":"object","description":"Reference entity record value"}}}}}}},"example":{"code":"kartell","values":{"label":[{"locale":"en_US","channel":null,"data":"Kartell"}],"image":[{"locale":null,"channel":null,"data":"0/c/b/0/0cb0c0e115dedba676f8d1ad8343ec207ab54c7b_image.jpg"}],"description":[{"locale":"en_US","channel":null,"data":"Kartell, the Italian furniture company that sells modern and remarkable pieces of furnitures."},{"locale":"fr_FR","channel":null,"data":"Kartell, l'éditeur de meuble italien spécialisé dans la signature de belle pièces au design contemporain."}],"country":[{"locale":null,"channel":null,"data":"italy"}],"collection_overview":[{"locale":null,"channel":null,"data":"5/1/d/8/51d81dc778ba1501a8f998f3ab5797569f3b9e25_img.png"}],"creation_year":[{"locale":null,"channel":null,"data":"1949"}]}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/brands/records"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/brands/records"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/brands/records?search_after=2x088w%3D%3D"}},"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/brands/records/kartell"}},"code":"kartell","values":{"label":[{"locale":"en_US","channel":null,"data":"Kartell"}],"image":[{"locale":null,"channel":null,"data":"0/c/b/0/0cb0c0e115dedba676f8d1ad8343ec207ab54c7b_image.jpg"}],"description":[{"data":"The contemporary Italian furniture brand","locale":"en_US","channel":null},{"data":"L'éditeur de meubles comtemporain italien","locale":"fr_FR","channel":null}],"country":[{"locale":null,"channel":null,"data":"italy"}]}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/brands/records/usm"}},"code":"usm","values":{"label":[{"locale":"en_US","channel":null,"data":"USM"}],"image":[{"locale":null,"channel":null,"data":"9/c/g/1/0cb0c0e115dedba76f8d1ad8343ec897abc43bv4_image.jpg"}],"description":[{"data":"Modular furniture from Switzerland for your home and office","locale":"en_US","channel":null},{"data":"L'éditeur de meubles modulaires suisse pour votre intérieur et pour les entreprises","locale":"fr_FR","channel":null}],"country":[{"locale":null,"channel":null,"data":"switzerland"}]}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/reference-entities/brands/records/ligneroset"}},"code":"ligneroset","values":{"label":[{"locale":"en_US","channel":null,"data":"Ligne Roset"}],"image":[{"locale":null,"channel":null,"data":"4/b/0/1/0cb0c0e115dedde78b8d1ad8343ec980cd5daa54_image.jpg"}],"description":[{"data":"Very well known French brand of modern and luxury furniture","locale":"en_US","channel":null},{"data":"La marque renommée des meubles de luxe à la française","locale":"fr_FR","channel":null}],"country":[{"locale":null,"channel":null,"data":"france"}]}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create several reference entity records","operationId":"patch_reference_entity_records","tags":["Reference entity record"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update and/or create several records of one given reference entity at once. Learn more about <a href=\"/documentation/update.html#patch-reference-entity-record-values\">Update behavior</a>. Note that if the record does not already exist for the given reference entity, it creates it.","parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"array","items":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of the record","x-immutable":true},"values":{"type":"object","description":"Record attributes values, see <a href='/concepts/reference-entities.html#focus-on-the-reference-entity-record-values'>Reference entity record values</a> section for more details","x-validation-rules":"Validation rules detailed in Reference entity record values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel code of the reference entity record value"},"locale":{"type":"string","description":"Locale code of the reference entity record value"},"data":{"type":"object","description":"Reference entity record value"}}}}}}},"example":{"code":"kartell","values":{"label":[{"locale":"en_US","channel":null,"data":"Kartell"}],"image":[{"locale":null,"channel":null,"data":"0/c/b/0/0cb0c0e115dedba676f8d1ad8343ec207ab54c7b_image.jpg"}],"description":[{"locale":"en_US","channel":null,"data":"Kartell, the Italian furniture company that sells modern and remarkable pieces of furnitures."},{"locale":"fr_FR","channel":null,"data":"Kartell, l'éditeur de meuble italien spécialisé dans la signature de belle pièces au design contemporain."}],"country":[{"locale":null,"channel":null,"data":"italy"}],"collection_overview":[{"locale":null,"channel":null,"data":"5/1/d/8/51d81dc778ba1501a8f998f3ab5797569f3b9e25_img.png"}],"creation_year":[{"locale":null,"channel":null,"data":"1949"}]}}},"example":[{"code":"kartell","values":{"label":[{"locale":"en_US","channel":null,"data":"Kartell"}],"image":[{"locale":null,"channel":null,"data":"0/c/b/0/0cb0c0e115dedba676f8d1ad8343ec207ab54c7b_image.jpg"}],"description":[{"locale":"en_US","channel":null,"data":"Kartell, the Italian furniture company that sells modern and remarkable pieces of furnitures."},{"locale":"fr_FR","channel":null,"data":"Kartell, l'éditeur de meuble italien spécialisé dans la signature de belle pièces au design contemporain."}],"country":[{"locale":null,"channel":null,"data":"italy"}],"collection_overview":[{"locale":null,"channel":null,"data":"5/1/d/8/51d81dc778ba1501a8f998f3ab5797569f3b9e25_img.png"}],"creation_year":[{"locale":null,"channel":null,"data":"1949"}]}},{"code":"ligneroset","values":{"label":[{"locale":"en_US","channel":null,"data":"Ligne Roset"}],"image":[{"locale":null,"channel":null,"data":"4/b/0/1/0cb0c0e115dedde78b8d1ad8343ec980cd5daa54_image.jpg"}],"description":[{"data":"Very well known French brand of modern and luxury furniture","locale":"en_US","channel":null},{"data":"La marque renommée des meubles de luxe à la française","locale":"fr_FR","channel":null}],"country":[{"locale":null,"channel":null,"data":"france"}],"creation_year":[{"locale":null,"channel":null,"data":"1860"}]}},{"code":"usm","values":{"label":[{"locale":"en_US","channel":null,"data":"USM"}],"image":[{"locale":null,"channel":null,"data":"9/c/g/1/0cb0c0e115dedba76f8d1ad8343ec897abc43bv4_image.jpg"}],"description":[{"data":"Modular furniture from Switzerland for your home and office","locale":"en_US","channel":null},{"data":"L'éditeur de meubles modulaires suisse pour votre intérieur et pour les entreprises","locale":"fr_FR","channel":null}],"country":[{"locale":null,"channel":null,"data":"switzerland"}],"creation_year":[{"locale":null,"channel":null,"data":"1885"}]}}]}}],"responses":{"200":{"description":"OK","x-details":"Returns an JSON array in which each object gives you the status of each record creation or update","x-no-entity":true,"schema":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string","description":"Resource code"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}}},"x-examples":[{"code":"kartell","status_code":204},{"code":"ligneroset","status_code":422,"message":"Property 'group' does not exist."},{"code":"usm","status_code":201}]},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/reference-entities/{reference_entity_code}/records/{code}":{"get":{"summary":"Get a record of a given reference entity","operationId":"get_reference_entity_records__code_","tags":["Reference entity record"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given record for a given reference entity.","parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the product in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of the record","x-immutable":true},"values":{"type":"object","description":"Record attributes values, see <a href='/concepts/reference-entities.html#focus-on-the-reference-entity-record-values'>Reference entity record values</a> section for more details","x-validation-rules":"Validation rules detailed in Reference entity record values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel code of the reference entity record value"},"locale":{"type":"string","description":"Locale code of the reference entity record value"},"data":{"type":"object","description":"Reference entity record value"}}}}}}},"example":{"code":"kartell","values":{"label":[{"locale":"en_US","channel":null,"data":"Kartell"}],"image":[{"locale":null,"channel":null,"data":"0/c/b/0/0cb0c0e115dedba676f8d1ad8343ec207ab54c7b_image.jpg"}],"description":[{"locale":"en_US","channel":null,"data":"Kartell, the Italian furniture company that sells modern and remarkable pieces of furnitures."},{"locale":"fr_FR","channel":null,"data":"Kartell, l'éditeur de meuble italien spécialisé dans la signature de belle pièces au design contemporain."}],"country":[{"locale":null,"channel":null,"data":"italy"}],"collection_overview":[{"locale":null,"channel":null,"data":"5/1/d/8/51d81dc778ba1501a8f998f3ab5797569f3b9e25_img.png"}],"creation_year":[{"locale":null,"channel":null,"data":"1949"}]}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a record of a given reference entity","operationId":"patch_reference_entity_records__code_","tags":["Reference entity record"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update a given record of a given renference entity. Learn more about <a href=\"/documentation/update.html#patch-reference-entity-record-values\">Update behavior</a>. Note that if the record does not already exist for the given reference entity, it creates it.","parameters":[{"name":"reference_entity_code","in":"path","description":"Code of the reference entity","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of the record","x-immutable":true},"values":{"type":"object","description":"Record attributes values, see <a href='/concepts/reference-entities.html#focus-on-the-reference-entity-record-values'>Reference entity record values</a> section for more details","x-validation-rules":"Validation rules detailed in Reference entity record values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel code of the reference entity record value"},"locale":{"type":"string","description":"Locale code of the reference entity record value"},"data":{"type":"object","description":"Reference entity record value"}}}}}}},"example":{"code":"kartell","values":{"label":[{"locale":"en_US","channel":null,"data":"Kartell"}],"image":[{"locale":null,"channel":null,"data":"0/c/b/0/0cb0c0e115dedba676f8d1ad8343ec207ab54c7b_image.jpg"}],"description":[{"locale":"en_US","channel":null,"data":"Kartell, the Italian furniture company that sells modern and remarkable pieces of furnitures."},{"locale":"fr_FR","channel":null,"data":"Kartell, l'éditeur de meuble italien spécialisé dans la signature de belle pièces au design contemporain."}],"country":[{"locale":null,"channel":null,"data":"italy"}],"collection_overview":[{"locale":null,"channel":null,"data":"5/1/d/8/51d81dc778ba1501a8f998f3ab5797569f3b9e25_img.png"}],"creation_year":[{"locale":null,"channel":null,"data":"1949"}]}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/reference-entities-media-files":{"post":{"summary":"Create a new media file for a reference entity or a record","operationId":"post_reference_entity_media_files","description":"This endpoint allows you to create a new media file and associate it to the image of a reference entity, or to the main image or to an attribute value of a record.","tags":["Reference entity media file"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"Content-type","in":"header","type":"string","description":"Equal to 'multipart/form-data', no other value allowed","required":true},{"name":"body","in":"body","x-form-data":true,"schema":{"required":["file"],"properties":{"file":{"type":"string","description":"The binary of the media file","format":"binary"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the media file creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"},"Reference-entities-media-file-code":{"description":"Code of the media file","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `multipart/form-data`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘multipart/form-data’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/reference-entities-media-files/{code}":{"get":{"summary":"Download the media file associated to a reference entity or a record","operationId":"get_reference_entity_media_files__code","description":"This endpoint allows you to download a given media file that is associated with a reference entity or a record.","x-content-type":"Mime-type of the media file","tags":["Reference entity media file"],"x-versions":["3.x","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the binary of the media file","x-content-type":"Mime-type of the media file"},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}}}}},"/api/rest/v1/asset-families":{"get":{"summary":"Get list of asset families","operationId":"get_asset_families","description":"This endpoint allows you to get a list of asset families. Asset families are paginated.","tags":["Asset family"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"search_after","in":"query","description":"Cursor when using the `search_after` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"cursor to the first page"}],"responses":{"200":{"description":"Return asset families paginated","schema":{"title":"Asset families","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}}}},{"properties":{"_embedded":{"type":"object","properties":{"_items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Asset family code","x-immutable":true},"labels":{"type":"object","description":"Asset family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Asset family label for the locale `localeCode`"}}},"attribute_as_main_media":{"type":"string","description":"Attribute code that is used as the main media of the asset family.","x-validation-rules":"It should be the code of an attribute that belongs to this family, and it must be a media file or a media link attribute type.","default":"First media file or media link attribute that was created"},"naming_convention":{"type":"object","description":"The naming convention ran over the asset code or the main media filename upon each asset creation, in order to automatically set several values in asset attributes. To learn more and see the format of this property, take a look at <a href='/concepts/asset-manager.html#focus-on-the-naming-convention'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our naming convention format.","default":{},"properties":{"source":{"type":"object","description":"The string on which the naming convention should be applied. More details <a href='/concepts/asset-manager.html#source'>here</a>."},"pattern":{"type":"string","description":"The regular expression that should be applied on the source. More details <a href='/concepts/asset-manager.html#pattern'>here</a>."},"abort_asset_creation_on_error":{"type":"boolean","description":"Whether the asset should be created if the naming convention failed to apply. More details <a href='/concepts/asset-manager.html#abort-asset-creation-on-error'>here</a>."}}},"product_link_rules":{"type":"array","description":"The rules that will be run after the asset creation, in order to automatically link the assets of this family to a set of products. To understand the format of this property, see <a href='/concepts/asset-manager.html#focus-on-the-product-link-rule'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our product link rule format.","default":{},"items":{"type":"object","properties":{"product_selections":{"type":"array","description":"The product selection to which the assets of the asset family to be automatically linked. More details <a href='/concepts/asset-manager.html#product-selection'>here</a>.","items":{"type":"object","required":["field","operator","value"],"properties":{"field":{"type":"string"},"operator":{"type":"string"},"value":{"type":"string"},"locale":{"type":"string"},"channel":{"type":"string"}}}},"assign_assets_to":{"type":"array","description":"The product value in which your assets will be assigned. More details <a href='/concepts/asset-manager.html#product-value-assignment'>here</a>.","items":{"type":"object","required":["attribute","mode"],"properties":{"attribute":{"type":"string"},"locale":{"type":"string"},"channel":{"type":"string"},"mode":{"type":"string"}}}}}}},"transformations":{"type":"array","description":"The transformations to perform on source files in order to generate new files into your asset attributes (only available since v4.0). To understand the format of this property, see <a href='/concepts/asset-manager.html#focus-on-the-transformations'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our transformation format.","default":{},"items":{"type":"object","required":["label","target","source","operations"],"properties":{"label":{"type":"string","description":"The name of the transformation"},"filename_suffix":{"type":"string","description":"The suffix that will be appended to the source filename to generate the target filename. More details <a href='/concepts/asset-manager.html#target-filename'>here</a>."},"filename_prefix":{"type":"string","description":"The prefix that will be prepended to the source filename to generate the target filename. More details <a href='/concepts/asset-manager.html#target-filename'>here</a>."},"source":{"type":"object","required":["attribute","channel","locale"],"description":"The attribute value in which is stored the media file you want to use as the source file for your transformation. More details <a href='/concepts/asset-manager.html#source-file'>here</a>.","properties":{"attribute":{"type":"string"},"channel":{"type":"string"},"locale":{"type":"string"}}},"target":{"type":"object","required":["attribute","channel","locale"],"description":"The attribute value in which the PIM will generate the new transformed file, aka the target file. More details <a href='/concepts/asset-manager.html#target-file'>here</a>.","properties":{"attribute":{"type":"string"},"channel":{"type":"string"},"locale":{"type":"string"}}},"operations":{"type":"object","description":"The transformations that should be applied to your source file to generate the target file. More details <a href='/concepts/asset-manager.html#transformation-operations'>here</a>.","x-validation-rules":"Should contain at least one operation","properties":{"type":{"type":"string"},"parameters":{"type":"object","properties":{"colorspace":{"type":"string"},"width":{"type":"integer"},"height":{"type":"integer"},"ratio":{"type":"integer"},"resolution-unit":{"type":"string"},"resolution-x":{"type":"integer"},"resolution-y":{"type":"integer"},"quality":{"type":"integer"}}}}}}}}},"example":{"code":"model_pictures","labels":{"en_US":"Model pictures","fr_FR":"Photographies en pied"},"attribute_as_main_media":"main_image","naming_convention":{"source":{"property":"code","channel":null,"locale":null},"pattern":"/(?P<product_ref>.*)-.*/","abort_asset_creation_on_error":true},"product_link_rules":[{"product_selections":[{"field":"sku","operator":"EQUALS","value":"{{product_ref}}"}],"assign_assets_to":[{"attribute":"model_pictures","mode":"replace"}]}],"transformations":[{"label":"Thumbnail plus black and white transformation","filename_suffix":"_thumbnailBW","source":{"attribute":"main_image","channel":null,"locale":null},"target":{"attribute":"thumbnail","channel":null,"locale":null},"operations":[{"type":"thumbnail","parameters":{"width":150,"height":150}},{"type":"colorspace","parameters":{"colorspace":"grey"}}]}]}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families?search_after=2x055w%3D%3D"}},"_embedded":{"_items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/packshots"}},"code":"packshots","labels":{"en_US":"Packshots","fr_FR":"Plans produit"},"“naming_convention”":{"source":{"property":"code","channel":null,"locale":null},"pattern":"/(?P<product_ref>.*)\\.jpg/","abort_asset_creation_on_error":true},"product_link_rules":[{"product_selections":[{"field":"sku","operator":"=","value":"{{product_ref}}"}],"assign_assets_to":[{"attribute":"{{my_product_attribute}}","mode":"add"}]}],"transformations":[{"label":"My transformation","filename_suffix":"_thumbnailBW","source":{"attribute":"main_image","locale":null,"channel":null},"target":{"attribute":"thumbnail","locale":null,"channel":null},"operations":[{"type":"thumbnail","parameters":{"width":150,"height":150}},{"type":"colorspace","parameters":{"colorspace":"grey"}}]}]},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/videos"}},"code":"videos","labels":{"en_US":"Videos","fr_FR":"Vidéos"},"product_link_rules":[{"product_selections":[{"field":"categories","operator":"IN","value":["{{category}}"]}],"assign_assets_to":[{"attribute":"presentation_video","locale":"{{locale}}","mode":"replace"}]}]},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/user_guides"}},"code":"user_guides","labels":{"en_US":"User guides","fr_FR":"Guides utilisateur"},"product_link_rules":[{"product_selections":[{"field":"sku","operator":"=","value":"{{product_ref}}"}],"assign_assets_to":[{"attribute":"user_instructions","locale":"{{locale}}","mode":"replace"}]}]}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/asset-families/{code}":{"get":{"summary":"Get an asset family","operationId":"get_asset_family__code_","tags":["Asset family"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given asset family.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the asset family in JSON format.","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Asset family code","x-immutable":true},"labels":{"type":"object","description":"Asset family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Asset family label for the locale `localeCode`"}}},"attribute_as_main_media":{"type":"string","description":"Attribute code that is used as the main media of the asset family.","x-validation-rules":"It should be the code of an attribute that belongs to this family, and it must be a media file or a media link attribute type.","default":"First media file or media link attribute that was created"},"naming_convention":{"type":"object","description":"The naming convention ran over the asset code or the main media filename upon each asset creation, in order to automatically set several values in asset attributes. To learn more and see the format of this property, take a look at <a href='/concepts/asset-manager.html#focus-on-the-naming-convention'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our naming convention format.","default":{},"properties":{"source":{"type":"object","description":"The string on which the naming convention should be applied. More details <a href='/concepts/asset-manager.html#source'>here</a>."},"pattern":{"type":"string","description":"The regular expression that should be applied on the source. More details <a href='/concepts/asset-manager.html#pattern'>here</a>."},"abort_asset_creation_on_error":{"type":"boolean","description":"Whether the asset should be created if the naming convention failed to apply. More details <a href='/concepts/asset-manager.html#abort-asset-creation-on-error'>here</a>."}}},"product_link_rules":{"type":"array","description":"The rules that will be run after the asset creation, in order to automatically link the assets of this family to a set of products. To understand the format of this property, see <a href='/concepts/asset-manager.html#focus-on-the-product-link-rule'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our product link rule format.","default":{},"items":{"type":"object","properties":{"product_selections":{"type":"array","description":"The product selection to which the assets of the asset family to be automatically linked. More details <a href='/concepts/asset-manager.html#product-selection'>here</a>.","items":{"type":"object","required":["field","operator","value"],"properties":{"field":{"type":"string"},"operator":{"type":"string"},"value":{"type":"string"},"locale":{"type":"string"},"channel":{"type":"string"}}}},"assign_assets_to":{"type":"array","description":"The product value in which your assets will be assigned. More details <a href='/concepts/asset-manager.html#product-value-assignment'>here</a>.","items":{"type":"object","required":["attribute","mode"],"properties":{"attribute":{"type":"string"},"locale":{"type":"string"},"channel":{"type":"string"},"mode":{"type":"string"}}}}}}},"transformations":{"type":"array","description":"The transformations to perform on source files in order to generate new files into your asset attributes (only available since v4.0). To understand the format of this property, see <a href='/concepts/asset-manager.html#focus-on-the-transformations'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our transformation format.","default":{},"items":{"type":"object","required":["label","target","source","operations"],"properties":{"label":{"type":"string","description":"The name of the transformation"},"filename_suffix":{"type":"string","description":"The suffix that will be appended to the source filename to generate the target filename. More details <a href='/concepts/asset-manager.html#target-filename'>here</a>."},"filename_prefix":{"type":"string","description":"The prefix that will be prepended to the source filename to generate the target filename. More details <a href='/concepts/asset-manager.html#target-filename'>here</a>."},"source":{"type":"object","required":["attribute","channel","locale"],"description":"The attribute value in which is stored the media file you want to use as the source file for your transformation. More details <a href='/concepts/asset-manager.html#source-file'>here</a>.","properties":{"attribute":{"type":"string"},"channel":{"type":"string"},"locale":{"type":"string"}}},"target":{"type":"object","required":["attribute","channel","locale"],"description":"The attribute value in which the PIM will generate the new transformed file, aka the target file. More details <a href='/concepts/asset-manager.html#target-file'>here</a>.","properties":{"attribute":{"type":"string"},"channel":{"type":"string"},"locale":{"type":"string"}}},"operations":{"type":"object","description":"The transformations that should be applied to your source file to generate the target file. More details <a href='/concepts/asset-manager.html#transformation-operations'>here</a>.","x-validation-rules":"Should contain at least one operation","properties":{"type":{"type":"string"},"parameters":{"type":"object","properties":{"colorspace":{"type":"string"},"width":{"type":"integer"},"height":{"type":"integer"},"ratio":{"type":"integer"},"resolution-unit":{"type":"string"},"resolution-x":{"type":"integer"},"resolution-y":{"type":"integer"},"quality":{"type":"integer"}}}}}}}}},"example":{"code":"model_pictures","labels":{"en_US":"Model pictures","fr_FR":"Photographies en pied"},"attribute_as_main_media":"main_image","naming_convention":{"source":{"property":"code","channel":null,"locale":null},"pattern":"/(?P<product_ref>.*)-.*/","abort_asset_creation_on_error":true},"product_link_rules":[{"product_selections":[{"field":"sku","operator":"EQUALS","value":"{{product_ref}}"}],"assign_assets_to":[{"attribute":"model_pictures","mode":"replace"}]}],"transformations":[{"label":"Thumbnail plus black and white transformation","filename_suffix":"_thumbnailBW","source":{"attribute":"main_image","channel":null,"locale":null},"target":{"attribute":"thumbnail","channel":null,"locale":null},"operations":[{"type":"thumbnail","parameters":{"width":150,"height":150}},{"type":"colorspace","parameters":{"colorspace":"grey"}}]}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an asset family","operationId":"patch_asset_family__code_","tags":["Asset family"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update a given asset family. Note that if the asset family does not already exist, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Asset family code","x-immutable":true},"labels":{"type":"object","description":"Asset family labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Asset family label for the locale `localeCode`"}}},"attribute_as_main_media":{"type":"string","description":"Attribute code that is used as the main media of the asset family.","x-validation-rules":"It should be the code of an attribute that belongs to this family, and it must be a media file or a media link attribute type.","default":"First media file or media link attribute that was created"},"naming_convention":{"type":"object","description":"The naming convention ran over the asset code or the main media filename upon each asset creation, in order to automatically set several values in asset attributes. To learn more and see the format of this property, take a look at <a href='/concepts/asset-manager.html#focus-on-the-naming-convention'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our naming convention format.","default":{},"properties":{"source":{"type":"object","description":"The string on which the naming convention should be applied. More details <a href='/concepts/asset-manager.html#source'>here</a>."},"pattern":{"type":"string","description":"The regular expression that should be applied on the source. More details <a href='/concepts/asset-manager.html#pattern'>here</a>."},"abort_asset_creation_on_error":{"type":"boolean","description":"Whether the asset should be created if the naming convention failed to apply. More details <a href='/concepts/asset-manager.html#abort-asset-creation-on-error'>here</a>."}}},"product_link_rules":{"type":"array","description":"The rules that will be run after the asset creation, in order to automatically link the assets of this family to a set of products. To understand the format of this property, see <a href='/concepts/asset-manager.html#focus-on-the-product-link-rule'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our product link rule format.","default":{},"items":{"type":"object","properties":{"product_selections":{"type":"array","description":"The product selection to which the assets of the asset family to be automatically linked. More details <a href='/concepts/asset-manager.html#product-selection'>here</a>.","items":{"type":"object","required":["field","operator","value"],"properties":{"field":{"type":"string"},"operator":{"type":"string"},"value":{"type":"string"},"locale":{"type":"string"},"channel":{"type":"string"}}}},"assign_assets_to":{"type":"array","description":"The product value in which your assets will be assigned. More details <a href='/concepts/asset-manager.html#product-value-assignment'>here</a>.","items":{"type":"object","required":["attribute","mode"],"properties":{"attribute":{"type":"string"},"locale":{"type":"string"},"channel":{"type":"string"},"mode":{"type":"string"}}}}}}},"transformations":{"type":"array","description":"The transformations to perform on source files in order to generate new files into your asset attributes (only available since v4.0). To understand the format of this property, see <a href='/concepts/asset-manager.html#focus-on-the-transformations'>here</a>.","x-validation-rules":"To know more about the validation of this property, take a look at our transformation format.","default":{},"items":{"type":"object","required":["label","target","source","operations"],"properties":{"label":{"type":"string","description":"The name of the transformation"},"filename_suffix":{"type":"string","description":"The suffix that will be appended to the source filename to generate the target filename. More details <a href='/concepts/asset-manager.html#target-filename'>here</a>."},"filename_prefix":{"type":"string","description":"The prefix that will be prepended to the source filename to generate the target filename. More details <a href='/concepts/asset-manager.html#target-filename'>here</a>."},"source":{"type":"object","required":["attribute","channel","locale"],"description":"The attribute value in which is stored the media file you want to use as the source file for your transformation. More details <a href='/concepts/asset-manager.html#source-file'>here</a>.","properties":{"attribute":{"type":"string"},"channel":{"type":"string"},"locale":{"type":"string"}}},"target":{"type":"object","required":["attribute","channel","locale"],"description":"The attribute value in which the PIM will generate the new transformed file, aka the target file. More details <a href='/concepts/asset-manager.html#target-file'>here</a>.","properties":{"attribute":{"type":"string"},"channel":{"type":"string"},"locale":{"type":"string"}}},"operations":{"type":"object","description":"The transformations that should be applied to your source file to generate the target file. More details <a href='/concepts/asset-manager.html#transformation-operations'>here</a>.","x-validation-rules":"Should contain at least one operation","properties":{"type":{"type":"string"},"parameters":{"type":"object","properties":{"colorspace":{"type":"string"},"width":{"type":"integer"},"height":{"type":"integer"},"ratio":{"type":"integer"},"resolution-unit":{"type":"string"},"resolution-x":{"type":"integer"},"resolution-y":{"type":"integer"},"quality":{"type":"integer"}}}}}}}}},"example":{"code":"model_pictures","labels":{"en_US":"Model pictures","fr_FR":"Photographies en pied"},"attribute_as_main_media":"main_image","naming_convention":{"source":{"property":"code","channel":null,"locale":null},"pattern":"/(?P<product_ref>.*)-.*/","abort_asset_creation_on_error":true},"product_link_rules":[{"product_selections":[{"field":"sku","operator":"EQUALS","value":"{{product_ref}}"}],"assign_assets_to":[{"attribute":"model_pictures","mode":"replace"}]}],"transformations":[{"label":"Thumbnail plus black and white transformation","filename_suffix":"_thumbnailBW","source":{"attribute":"main_image","channel":null,"locale":null},"target":{"attribute":"thumbnail","channel":null,"locale":null},"operations":[{"type":"thumbnail","parameters":{"width":150,"height":150}},{"type":"colorspace","parameters":{"colorspace":"grey"}}]}]}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/asset-families/{asset_family_code}/attributes":{"get":{"summary":"Get the list of attributes of a given asset family","operationId":"get_asset_families__code__attributes","description":"This endpoint allows you to get the list of attributes of a given asset family.","tags":["Asset attribute"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"}],"responses":{"200":{"description":"Return the attributes of the given asset family","x-no-entity":true,"schema":{"type":"array","items":{"type":"object","required":["code","type","media_type"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"type":{"type":"string","description":"Attribute type","enum":["text","media_link","number","media_file","single_option","multiple_options","reference_entity_single_link","reference_entity_multiple_links"],"x-immutable":true},"value_per_locale":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"value_per_channel":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"is_required_for_completeness":{"type":"boolean","description":"Whether the attribute should be part of the record's completeness calculation","default":false},"is_read_only":{"type":"boolean","description":"Whether the attribute should be in read only mode only in the UI, but you can still update it with the API","default":false},"max_characters":{"type":"integer","description":"Maximum number of characters allowed for the value of the attribute when the attribute type is `text`","x-warning":"Only for `text` attribute type"},"is_textarea":{"type":"boolean","description":"Whether the UI should display a text area instead of a simple field when the attribute type is `text`","default":false,"x-warning":"Only for `text` attribute type"},"is_rich_text_editor":{"type":"boolean","description":"Whether the UI should display a rich text editor instead of a simple text area when the attribute type is `text`","x-validation-rules":"Required when the property `is_textarea` is equal to `true`","x-warning":"Only for `text` attribute type"},"validation_rule":{"type":"string","description":"Validation rule type used to validate the attribute value when the attribute type is `text`","default":"none","x-warning":"Only for `text` attribute type","enum":["email","url","regexp","none"]},"validation_regexp":{"type":"string","description":"Regexp expression used to validate the attribute value when the attribute type is `text`","default":null,"x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `text` attribute type"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `media_file`","default":[],"x-warning":"Only for `media_file` attribute type","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `media_file`","default":null,"x-warning":"Only for `media_file` attribute type"},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `number`","default":false,"x-warning":"Only for `number` attribute type"},"min_value":{"type":"string","description":"Minimum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The minimum value must be lower than the maximum value","x-warning":"Only for `number` attribute type"},"max_value":{"type":"string","description":"Maximum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The maximum value must be greater than the minimum value","x-warning":"Only for `number` attribute type"},"media_type":{"type":"string","description":"For the `media_link` attribute type, it is the type of the media behind the url, to allow its preview in the PIM. For the `media_file` attribute type, it is the type of the file.","enum":["image","pdf","youtube","vimeo","other"],"x-warning":"Only required for `media_link` and `media_file` attribute types"},"prefix":{"type":"string","description":"Prefix of the `media_link` attribute type. The common url root that prefixes the link to the media","default":null,"x-warning":"Only for `media_link` attribute type"},"suffix":{"type":"string","description":"Suffix of the `media_link` attribute type. The common url suffix for the media","default":null,"x-warning":"Only for `media_link` attribute type"}},"example":{"code":"model_is_wearing_size","labels":{"en_US":"Model is wearing size","fr_FR":"Le mannequin porte la taille"},"type":"single_option","value_per_locale":false,"value_per_channel":false,"is_required_for_completeness":true}}},"x-examples":[{"code":"model_is_wearing_size","labels":{"en_US":"Model is wearing size","fr_FR":"Le mannequin porte la taille"},"type":"single_option","value_per_locale":false,"value_per_channel":false,"is_required_for_completeness":true},{"code":"media_link","labels":{"en_US":"Media link","fr_FR":"Lien vers le média"},"type":"media_link","value_per_locale":false,"value_per_channel":false,"is_required_for_completeness":true,"prefix":"https://my-dam.com/","suffix":"?height=630&width=485","media_type":"image"},{"code":"warning_mention","labels":{"en_US":"Warning mention","fr_FR":"Phrase d'avertissement"},"type":"text","value_per_locale":true,"value_per_channel":false,"is_required_for_completeness":false,"max_characters":"50","is_textarea":false,"is_rich_text_editor":false,"validation_rule":"none","validation_regexp":null}]},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/asset-families/{asset_family_code}/attributes/{code}":{"get":{"summary":"Get an attribute of a given asset family","operationId":"get_asset_family_attributes__code_","tags":["Asset attribute"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given attribute for a given asset family.","parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the asset attribute in JSON format","schema":{"type":"object","required":["code","type","media_type"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"type":{"type":"string","description":"Attribute type","enum":["text","media_link","number","media_file","single_option","multiple_options","reference_entity_single_link","reference_entity_multiple_links"],"x-immutable":true},"value_per_locale":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"value_per_channel":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"is_required_for_completeness":{"type":"boolean","description":"Whether the attribute should be part of the record's completeness calculation","default":false},"is_read_only":{"type":"boolean","description":"Whether the attribute should be in read only mode only in the UI, but you can still update it with the API","default":false},"max_characters":{"type":"integer","description":"Maximum number of characters allowed for the value of the attribute when the attribute type is `text`","x-warning":"Only for `text` attribute type"},"is_textarea":{"type":"boolean","description":"Whether the UI should display a text area instead of a simple field when the attribute type is `text`","default":false,"x-warning":"Only for `text` attribute type"},"is_rich_text_editor":{"type":"boolean","description":"Whether the UI should display a rich text editor instead of a simple text area when the attribute type is `text`","x-validation-rules":"Required when the property `is_textarea` is equal to `true`","x-warning":"Only for `text` attribute type"},"validation_rule":{"type":"string","description":"Validation rule type used to validate the attribute value when the attribute type is `text`","default":"none","x-warning":"Only for `text` attribute type","enum":["email","url","regexp","none"]},"validation_regexp":{"type":"string","description":"Regexp expression used to validate the attribute value when the attribute type is `text`","default":null,"x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `text` attribute type"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `media_file`","default":[],"x-warning":"Only for `media_file` attribute type","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `media_file`","default":null,"x-warning":"Only for `media_file` attribute type"},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `number`","default":false,"x-warning":"Only for `number` attribute type"},"min_value":{"type":"string","description":"Minimum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The minimum value must be lower than the maximum value","x-warning":"Only for `number` attribute type"},"max_value":{"type":"string","description":"Maximum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The maximum value must be greater than the minimum value","x-warning":"Only for `number` attribute type"},"media_type":{"type":"string","description":"For the `media_link` attribute type, it is the type of the media behind the url, to allow its preview in the PIM. For the `media_file` attribute type, it is the type of the file.","enum":["image","pdf","youtube","vimeo","other"],"x-warning":"Only required for `media_link` and `media_file` attribute types"},"prefix":{"type":"string","description":"Prefix of the `media_link` attribute type. The common url root that prefixes the link to the media","default":null,"x-warning":"Only for `media_link` attribute type"},"suffix":{"type":"string","description":"Suffix of the `media_link` attribute type. The common url suffix for the media","default":null,"x-warning":"Only for `media_link` attribute type"}},"example":{"code":"model_is_wearing_size","labels":{"en_US":"Model is wearing size","fr_FR":"Le mannequin porte la taille"},"type":"single_option","value_per_locale":false,"value_per_channel":false,"is_required_for_completeness":true}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an attribute of a given asset family","operationId":"patch_asset_family_attributes__code_","tags":["Asset attribute"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update a given attribute for a given asset family. Note that if the attribute does not already exist for the given asset family, it creates it.","parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code","type","media_type"],"properties":{"code":{"type":"string","description":"Attribute code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}},"type":{"type":"string","description":"Attribute type","enum":["text","media_link","number","media_file","single_option","multiple_options","reference_entity_single_link","reference_entity_multiple_links"],"x-immutable":true},"value_per_locale":{"type":"boolean","description":"Whether the attribute is localizable, i.e. can have one value by locale","default":false,"x-immutable":true},"value_per_channel":{"type":"boolean","description":"Whether the attribute is scopable, i.e. can have one value by channel","default":false,"x-immutable":true},"is_required_for_completeness":{"type":"boolean","description":"Whether the attribute should be part of the record's completeness calculation","default":false},"is_read_only":{"type":"boolean","description":"Whether the attribute should be in read only mode only in the UI, but you can still update it with the API","default":false},"max_characters":{"type":"integer","description":"Maximum number of characters allowed for the value of the attribute when the attribute type is `text`","x-warning":"Only for `text` attribute type"},"is_textarea":{"type":"boolean","description":"Whether the UI should display a text area instead of a simple field when the attribute type is `text`","default":false,"x-warning":"Only for `text` attribute type"},"is_rich_text_editor":{"type":"boolean","description":"Whether the UI should display a rich text editor instead of a simple text area when the attribute type is `text`","x-validation-rules":"Required when the property `is_textarea` is equal to `true`","x-warning":"Only for `text` attribute type"},"validation_rule":{"type":"string","description":"Validation rule type used to validate the attribute value when the attribute type is `text`","default":"none","x-warning":"Only for `text` attribute type","enum":["email","url","regexp","none"]},"validation_regexp":{"type":"string","description":"Regexp expression used to validate the attribute value when the attribute type is `text`","default":null,"x-validation-rules":"Required when the property `validation_rule` is equal to `regexp`","x-warning":"Only for `text` attribute type"},"allowed_extensions":{"type":"array","description":"Extensions allowed when the attribute type is `media_file`","default":[],"x-warning":"Only for `media_file` attribute type","items":{"type":"string"}},"max_file_size":{"type":"string","description":"Max file size in MB when the attribute type is `media_file`","default":null,"x-warning":"Only for `media_file` attribute type"},"decimals_allowed":{"type":"boolean","description":"Whether decimals are allowed when the attribute type is `number`","default":false,"x-warning":"Only for `number` attribute type"},"min_value":{"type":"string","description":"Minimum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The minimum value must be lower than the maximum value","x-warning":"Only for `number` attribute type"},"max_value":{"type":"string","description":"Maximum value allowed when the attribute type is `number`","default":null,"x-validation-rules":"The maximum value must be greater than the minimum value","x-warning":"Only for `number` attribute type"},"media_type":{"type":"string","description":"For the `media_link` attribute type, it is the type of the media behind the url, to allow its preview in the PIM. For the `media_file` attribute type, it is the type of the file.","enum":["image","pdf","youtube","vimeo","other"],"x-warning":"Only required for `media_link` and `media_file` attribute types"},"prefix":{"type":"string","description":"Prefix of the `media_link` attribute type. The common url root that prefixes the link to the media","default":null,"x-warning":"Only for `media_link` attribute type"},"suffix":{"type":"string","description":"Suffix of the `media_link` attribute type. The common url suffix for the media","default":null,"x-warning":"Only for `media_link` attribute type"}},"example":{"code":"model_is_wearing_size","labels":{"en_US":"Model is wearing size","fr_FR":"Le mannequin porte la taille"},"type":"single_option","value_per_locale":false,"value_per_channel":false,"is_required_for_completeness":true}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/asset-families/{asset_family_code}/attributes/{attribute_code}/options":{"get":{"summary":"Get a list of attribute options of a given attribute for a given asset family","operationId":"get_asset_family_attributes__attribute_code__options","description":"This endpoint allows you to get a list of attribute options for a given asset family.","tags":["Asset attribute option"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"}],"responses":{"200":{"description":"Return the options of the given attribute of the given asset family","x-no-entity":true,"schema":{"type":"array","items":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute's option code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}}},"example":{"code":"small","labels":{"en_US":"S","fr_FR":"S"}}}},"x-examples":[{"code":"unique_size","labels":{"en_US":"Unique size","fr_FR":"Taille unique"}},{"code":"size_27","labels":{"en_US":"Size 27","fr_FR":"Taille 36"}},{"code":"small","labels":{"en_US":"S","fr_FR":"S"}}]},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}}},"/api/rest/v1/asset-families/{asset_family_code}/attributes/{attribute_code}/options/{code}":{"get":{"summary":"Get an attribute option for a given attribute of a given asset family","operationId":"get_asset_attributes__attribute_code__options__code_","description":"This endpoint allows you to get the information about a given asset attribute option.","tags":["Asset attribute option"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the asset attribute option in JSON format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute's option code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}}},"example":{"code":"small","labels":{"en_US":"S","fr_FR":"S"}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an asset attribute option for a given asset family","operationId":"patch_asset_attributes__attribute_code__options__code_","tags":["Asset attribute option"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update a given option for a given attribute and a given asset family. Learn more about the <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if the option does not already exist for the given attribute of the given asset family, it creates it.","parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"attribute_code","in":"path","description":"Code of the attribute","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Attribute's option code","x-immutable":true},"labels":{"type":"object","description":"Attribute labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"Attribute label for the locale `localeCode`"}}}},"example":{"code":"small","labels":{"en_US":"S","fr_FR":"S"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/asset-media-files":{"post":{"summary":"Create a new media file for an asset","operationId":"post_asset_media_files","description":"This endpoint allows you to create a new media file and associate it to a media file attribute value of an asset.","tags":["Asset media file"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"Content-type","in":"header","type":"string","description":"Equal to 'multipart/form-data', no other value allowed","required":true},{"name":"body","in":"body","x-form-data":true,"schema":{"required":["file"],"properties":{"file":{"type":"string","description":"The binary of the media file","format":"binary"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the media file creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"},"Asset-media-file-code":{"description":"Code of the media file","type":"string"}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `multipart/form-data`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘multipart/form-data’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/asset-media-files/{code}":{"get":{"summary":"Download the media file associated to an asset","operationId":"get_asset_media_files__code","description":"This endpoint allows you to download a given media file that is associated with an asset.","x-content-type":"Mime-type of the media file","tags":["Asset media file"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the binary of the media file","x-content-type":"Mime-type of the media file"},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}}}}},"/api/rest/v1/asset-families/{asset_family_code}/assets":{"get":{"summary":"Get the list of the assets of a given asset family","operationId":"get_assets","tags":["Asset"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get a list of assets of a given asset family. Assets are paginated. This endpoint is case sensitive on the asset family code.","parameters":[{"name":"search","in":"query","description":"Filter assets, for more details see the <a href=\"/documentation/filter.html#filter-assets\">Asset filters</a> section","required":false,"type":"string"},{"name":"channel","in":"query","type":"string","description":"Filter asset values to return scopable asset attributes for the given channel as well as the non localizable/non scopable asset attributes, for more details see the <a href=\"/documentation/filter.html#asset-values-by-channel\">Filter asset values by channel</a> section","required":false},{"name":"locales","in":"query","type":"string","description":"Filter asset values to return localizable attributes for the given locales as well as the non localizable/non scopable asset attributes, for more details see the <a href=\"/documentation/filter.html#asset-values-by-locale\">Filter asset values by locale</a> section","required":false},{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"search_after","in":"query","description":"Cursor when using the `search_after` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"cursor to the first page"}],"responses":{"200":{"description":"Return the assets of the given asset family paginated","schema":{"title":"Asset","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}}}},{"properties":{"_embedded":{"type":"object","properties":{"_items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of the asset","x-immutable":true},"values":{"type":"object","description":"Asset attributes values, see the <a href='/concepts/asset-manager.html#focus-on-the-asset-values'>Focus on the asset values</a> section for more details.","x-validation-rules":"Validation rules detailed in Asset attribute values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel code of the asset attribute value"},"locale":{"type":"string","description":"Locale code of the asset attribute value"},"data":{"type":"object","description":"Asset attribute value"}}}}}}},"example":{"code":"sku_54628_picture1","values":{"media_preview":[{"locale":null,"channel":null,"data":"sku_54628_picture1.jpg"}],"model_wears_size":[{"locale":null,"channel":null,"data":"s"}],"photographer":[{"locale":null,"channel":null,"data":"ben_levy"}],"main_colors":[{"locale":null,"channel":null,"data":["red","purple"]}],"end_of_use_date":[{"locale":null,"channel":null,"data":"02/03/2021"}]}}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/model_pictures/assets"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/model_pictures/assets"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/model_pictures/assets?search_after=2x088w%3D%3D"}},"_embedded":{"_items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/model_pictures/assets/allie_jean_model_picture"}},"code":"allie_jean_model_picture","values":{"media_link":[{"locale":null,"channel":null,"data":"allie_jean_model_picture.png"}],"model_is_wearing_size":[{"locale":null,"channel":null,"data":"size_27"}],"warning_mention":[{"data":"Photo not retouched","locale":"en_US","channel":null},{"data":"Photo non retouchée","locale":"fr_FR","channel":null}]}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/model_pictures/assets/amy_socks_model_picture"}},"code":"amy_socks_model_picture","values":{"media_link":[{"locale":null,"channel":null,"data":"amy_socks_model_picture.png"}],"model_is_wearing_size":[{"locale":null,"channel":null,"data":"unique_size"}],"warning_mention":[{"data":"Photo not retouched","locale":"en_US","channel":null},{"data":"Photo non retouchée","locale":"fr_FR","channel":null}]}},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/asset-families/model_pictures/assets/alice_blouse_model_picture"}},"code":"alice_blouse_model_picture","values":{"media_link":[{"locale":null,"channel":null,"data":"alice_blouse_model_picture.png"}],"model_is_wearing_size":[{"locale":null,"channel":null,"data":"small"}],"warning_mention":[{"data":"Photo retouched","locale":"en_US","channel":null},{"data":"Photo non retouchée","locale":"fr_FR","channel":null}]}}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create several assets","operationId":"patch_assets","tags":["Asset"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update and/or create several assets of one given asset family at once. Learn more about the <a href=\"/documentation/update.html#patch-asset-attribute-values\">Update behavior</a>. Note that if the asset does not already exist for the given asset family, it creates it. This endpoint is case sensitive on the asset family code.","parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"array","items":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of the asset","x-immutable":true},"values":{"type":"object","description":"Asset attributes values, see the <a href='/concepts/asset-manager.html#focus-on-the-asset-values'>Focus on the asset values</a> section for more details.","x-validation-rules":"Validation rules detailed in Asset attribute values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel code of the asset attribute value"},"locale":{"type":"string","description":"Locale code of the asset attribute value"},"data":{"type":"object","description":"Asset attribute value"}}}}}}},"example":{"code":"sku_54628_picture1","values":{"media_preview":[{"locale":null,"channel":null,"data":"sku_54628_picture1.jpg"}],"model_wears_size":[{"locale":null,"channel":null,"data":"s"}],"photographer":[{"locale":null,"channel":null,"data":"ben_levy"}],"main_colors":[{"locale":null,"channel":null,"data":["red","purple"]}],"end_of_use_date":[{"locale":null,"channel":null,"data":"02/03/2021"}]}}},"example":[{"code":"sku_54628_picture1","values":{"media_preview":[{"locale":null,"channel":null,"data":"sku_54628_picture1.jpg"}],"model_wears_size":[{"locale":null,"channel":null,"data":"s"}],"photographer":[{"locale":null,"channel":null,"data":"ben_levy"}],"main_colors":[{"locale":null,"channel":null,"data":["red","purple"]}],"end_of_use_date":[{"locale":null,"channel":null,"data":"02/03/2021"}]}},{"code":"sku_54628_picture2","values":{"media_preview":[{"locale":null,"channel":null,"data":"sku_54628_picture2.jpg"}],"model_wears_size":[{"locale":null,"channel":null,"data":"s"}],"photographer":[{"locale":null,"channel":null,"data":"ben_levy"}],"main_colors":[{"locale":null,"channel":null,"data":["blue","white"]}],"end_of_use_date":[{"locale":null,"channel":null,"data":"02/03/2021"}]}},{"code":"sku_54628_picture3","values":{"media_preview":[{"locale":null,"channel":null,"data":"sku_54628_picture3.jpg"}],"model_wears_size":[{"locale":null,"channel":null,"data":"s"}],"photographer":[{"locale":null,"channel":null,"data":"ben_levy"}],"main_colors":[{"locale":null,"channel":null,"data":["purple"]}],"end_of_use_date":[{"locale":null,"channel":null,"data":"02/03/2021"}]}}]}}],"responses":{"200":{"description":"OK","x-details":"Returns an JSON array in which each object gives you the status of each asset creation or update","x-no-entity":true,"schema":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string","description":"Resource code"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}}},"x-examples":[{"code":"sku_54628_picture1","status_code":204},{"code":"sku_54628_picture2","status_code":422,"message":"Property 'group' does not exist."},{"code":"sku_54628_picture3","status_code":201}]},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/asset-families/{asset_family_code}/assets/{code}":{"get":{"summary":"Get an asset of a given asset family","operationId":"get_assets__code_","tags":["Asset"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to get the information about a given asset for a given asset family. This endpoint is case sensitive on the asset family code.","parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the asset in JSON standard format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of the asset","x-immutable":true},"values":{"type":"object","description":"Asset attributes values, see the <a href='/concepts/asset-manager.html#focus-on-the-asset-values'>Focus on the asset values</a> section for more details.","x-validation-rules":"Validation rules detailed in Asset attribute values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel code of the asset attribute value"},"locale":{"type":"string","description":"Locale code of the asset attribute value"},"data":{"type":"object","description":"Asset attribute value"}}}}}}},"example":{"code":"sku_54628_picture1","values":{"media_preview":[{"locale":null,"channel":null,"data":"sku_54628_picture1.jpg"}],"model_wears_size":[{"locale":null,"channel":null,"data":"s"}],"photographer":[{"locale":null,"channel":null,"data":"ben_levy"}],"main_colors":[{"locale":null,"channel":null,"data":["red","purple"]}],"end_of_use_date":[{"locale":null,"channel":null,"data":"02/03/2021"}]}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create an asset","operationId":"patch_asset__code_","tags":["Asset"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to update a given asset of a given asset family. Learn more about the <a href=\"/documentation/update.html#patch-asset-attribute-values\">Update behavior</a>. Note that if the asset does not already exist for the given asset family, it creates it. This endpoint is case sensitive on the asset family code.","parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"Code of the asset","x-immutable":true},"values":{"type":"object","description":"Asset attributes values, see the <a href='/concepts/asset-manager.html#focus-on-the-asset-values'>Focus on the asset values</a> section for more details.","x-validation-rules":"Validation rules detailed in Asset attribute values section","properties":{"attributeCode":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel code of the asset attribute value"},"locale":{"type":"string","description":"Locale code of the asset attribute value"},"data":{"type":"object","description":"Asset attribute value"}}}}}}},"example":{"code":"sku_54628_picture1","values":{"media_preview":[{"locale":null,"channel":null,"data":"sku_54628_picture1.jpg"}],"model_wears_size":[{"locale":null,"channel":null,"data":"s"}],"photographer":[{"locale":null,"channel":null,"data":"ben_levy"}],"main_colors":[{"locale":null,"channel":null,"data":["red","purple"]}],"end_of_use_date":[{"locale":null,"channel":null,"data":"02/03/2021"}]}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"delete":{"summary":"Delete an asset","operationId":"delete_assets__code_","tags":["Asset"],"x-versions":["3.2","4.0","5.0","SaaS"],"x-ee":true,"description":"This endpoint allows you to delete a given asset. This endpoint is case sensitive on the asset family code.","parameters":[{"name":"asset_family_code","in":"path","description":"Code of the asset family","required":true,"type":"string"},{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"204":{"description":"No content to return","x-details":"Means that the deletion was successful"},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}}}}},"/api/rest/v1/assets":{"get":{"summary":"Get list of PAM assets","operationId":"get_pam_assets","description":"This endpoint allows you to get a list of PAM assets. PAM assets are paginated.","tags":["PAM asset"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"pagination_type","in":"query","description":"Pagination method type, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"page","x-validation-rules":"One of the following values","enum":["page","search_after"]},{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"search_after","in":"query","description":"Cursor when using the `search_after` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"string","default":"cursor to the first page"},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Returns PAM assets paginated","schema":{"title":"PAM Assets","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"PAM asset code","x-immutable":true},"categories":{"type":"array","description":"Codes of the PAM asset categories in which the asset is classified","x-validation-rules":"Each string of the array is equal to an existing asset category code","items":{"type":"string"},"default":[]},"description":{"type":"string","description":"Description of the PAM asset","default":null},"localizable":{"type":"boolean","description":"Whether the asset is localized or not, meaning if you want to have different reference files for each of your locale","default":false,"x-immutable":true},"tags":{"type":"array","description":"Tags of the PAM asset","items":{"type":"string"},"default":[]},"end_of_use":{"type":"string","description":"Date on which the PAM asset expire","format":"dateTime","default":null,"x-validation-rules":"The date follows the ISO 8601 format"},"variation_files":{"type":"array","description":"Variations of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the variation file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the variation entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the variation file"}}}}},"locale":{"type":"string","description":"Locale code of the variation"},"scope":{"type":"string","description":"Channel code of the variation"},"code":{"type":"string","description":"Code of the variation"}}}},"reference_files":{"type":"array","description":"Reference files of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the reference file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the reference file entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the reference file"}}}}},"locale":{"type":"string","description":"Locale code of the reference file"},"code":{"type":"string","description":"Code of the reference file"}}}}},"example":{"code":"tshirt_artemis_main_picture","categories":["tshirts_assets"],"description":"The main picture of the Artemis t-shirt","localizable":false,"tags":["tshirts","red","summer"],"end_of_use":"2019-09-01T00:00:00+0200","variation_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale"}},"locale":null,"scope":"e_commerce","code":"7/5/8/e/758e39d48va7b42a55001434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_ecommerce.jpg"},{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale"}},"locale":null,"scope":"print","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_print.jpg"}],"reference_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale"}},"locale":null,"code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture.jpg"}]}}]}}}}}}]},"examples":{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets?page=2&limit=3"},"first":{"href":"https://demo.akeneo.com/api/rest/v1/assets?page=1&limit=3"},"previous":{"href":"https://demo.akeneo.com/api/rest/v1/assets?page=1&limit=3"},"next":{"href":"https://demo.akeneo.com/api/rest/v1/assets?page=3&limit=3"}},"current_page":2,"_embedded":{"items":[{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture"}},"code":"tshirt_artemis_main_picture","categories":["tshirts_assets"],"description":"The main picture of the Artemis t-shirt","localizable":false,"tags":["tshirts","red","summer"],"end_of_use":"2019-09-01T00:00:00+0200","variation_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale"}},"locale":null,"scope":"e_commerce","code":"7/5/8/e/758e39d48va7b42a55001434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_ecommerce.jpg"},{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale"}},"locale":null,"scope":"print","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_print.jpg"}],"reference_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale"}},"locale":null,"code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture.jpg"}]},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_profile_picture"}},"code":"tshirt_artemis_profile_picture","categories":["tshirts_assets"],"description":"The profile picture of the Artemis t-shirt","localizable":false,"tags":["tshirts","red","summer","profile_views"],"end_of_use":"2019-09-01T00:00:00+0200","variation_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_profile_picture/variation-files/ecommerce/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_profile_picture/variation-files/ecommerce/no_locale"}},"locale":null,"scope":"e_commerce","code":"7/5/8/e/758e39d48va7b42a55001434fd3d7b6cf3189b7f_tshirt_artemis_profile_picture_ecommerce.jpg"},{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_profile_picture/variation-files/print/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_profile_picture/variation-files/print/no_locale"}},"locale":null,"scope":"print","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_profile_picture_print.jpg"}],"reference_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_profile_picture/reference-files/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_profile_picture/reference-files/no_locale"}},"locale":null,"code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_profile_picture.jpg"}]},{"_links":{"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_maintenance_manual"}},"code":"tshirt_artemis_maintenance_manual","categories":["tshirts_assets"],"description":"The maintenance manual of the Artemis t-shirt","localizable":true,"tags":["tshirts","manuals"],"end_of_use":null,"variation_files":[],"reference_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_maintenance_manual/reference-files/en_US/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_maintenance_manual/reference-files/en_US"}},"locale":"en_US","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_maintenance_manual_en_US.pdf"},{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_maintenance_manual/reference-files/fr_FR/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_maintenance_manual/reference-files/fr_FR"}},"locale":"fr_FR","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_maintenance_manual_fr_FR.pdf"}]}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Create a new PAM asset","operationId":"post_pam_assets","description":"This endpoint allows you to create a new PAM asset.","tags":["PAM asset"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"body","in":"body","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"PAM asset code","x-immutable":true},"categories":{"type":"array","description":"Codes of the PAM asset categories in which the asset is classified","x-validation-rules":"Each string of the array is equal to an existing asset category code","items":{"type":"string"},"default":[]},"description":{"type":"string","description":"Description of the PAM asset","default":null},"localizable":{"type":"boolean","description":"Whether the asset is localized or not, meaning if you want to have different reference files for each of your locale","default":false,"x-immutable":true},"tags":{"type":"array","description":"Tags of the PAM asset","items":{"type":"string"},"default":[]},"end_of_use":{"type":"string","description":"Date on which the PAM asset expire","format":"dateTime","default":null,"x-validation-rules":"The date follows the ISO 8601 format"},"variation_files":{"type":"array","description":"Variations of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the variation file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the variation entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the variation file"}}}}},"locale":{"type":"string","description":"Locale code of the variation"},"scope":{"type":"string","description":"Channel code of the variation"},"code":{"type":"string","description":"Code of the variation"}}}},"reference_files":{"type":"array","description":"Reference files of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the reference file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the reference file entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the reference file"}}}}},"locale":{"type":"string","description":"Locale code of the reference file"},"code":{"type":"string","description":"Code of the reference file"}}}}},"example":{"code":"tshirt_artemis_main_picture","categories":["tshirts_assets"],"description":"The main picture of the Artemis t-shirt","localizable":false,"tags":["tshirts","red","summer"],"end_of_use":"2019-09-01T00:00:00+0200","variation_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale"}},"locale":null,"scope":"e_commerce","code":"7/5/8/e/758e39d48va7b42a55001434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_ecommerce.jpg"},{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale"}},"locale":null,"scope":"print","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_print.jpg"}],"reference_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale"}},"locale":null,"code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture.jpg"}]}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}},"patch":{"summary":"Update/create several PAM assets","operationId":"patch_pam_assets","tags":["PAM asset"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"description":"This endpoint allows you to update several PAM assets at once.","x-body-by-line":"Contains several lines, each line is a PAM asset in JSON format","parameters":[{"name":"body","in":"body","schema":{"x-examples":{"x-example-1":"{\"code\":\"tshirt_aria_main_picture\",\"categories\":[\"tshirts_assets\"],\"tags\":[\"tshirts\", \"red\", \"summer\"]}","x-example-2":"{\"code\":\"tshirt_artemis_maintenance_manual\",\"categories\":[\"tshirts_assets\",\"short_sleeve\"]}","x-example-3":"{\"code\":\"tshirt_artemis_main_picture\",\"tags\":[\"tshirts\", \"red\", \"summer\",\"short_sleeve\"]}"},"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"PAM asset code","x-immutable":true},"categories":{"type":"array","description":"Codes of the PAM asset categories in which the asset is classified","x-validation-rules":"Each string of the array is equal to an existing asset category code","items":{"type":"string"},"default":[]},"description":{"type":"string","description":"Description of the PAM asset","default":null},"localizable":{"type":"boolean","description":"Whether the asset is localized or not, meaning if you want to have different reference files for each of your locale","default":false,"x-immutable":true},"tags":{"type":"array","description":"Tags of the PAM asset","items":{"type":"string"},"default":[]},"end_of_use":{"type":"string","description":"Date on which the PAM asset expire","format":"dateTime","default":null,"x-validation-rules":"The date follows the ISO 8601 format"},"variation_files":{"type":"array","description":"Variations of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the variation file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the variation entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the variation file"}}}}},"locale":{"type":"string","description":"Locale code of the variation"},"scope":{"type":"string","description":"Channel code of the variation"},"code":{"type":"string","description":"Code of the variation"}}}},"reference_files":{"type":"array","description":"Reference files of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the reference file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the reference file entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the reference file"}}}}},"locale":{"type":"string","description":"Locale code of the reference file"},"code":{"type":"string","description":"Code of the reference file"}}}}},"example":{"code":"tshirt_artemis_main_picture","categories":["tshirts_assets"],"description":"The main picture of the Artemis t-shirt","localizable":false,"tags":["tshirts","red","summer"],"end_of_use":"2019-09-01T00:00:00+0200","variation_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale"}},"locale":null,"scope":"e_commerce","code":"7/5/8/e/758e39d48va7b42a55001434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_ecommerce.jpg"},{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale"}},"locale":null,"scope":"print","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_print.jpg"}],"reference_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale"}},"locale":null,"code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture.jpg"}]}}}],"responses":{"200":{"description":"OK","x-details":"Returns a plain text response whose lines are JSON containing the status of each update or creation","x-no-entity":true,"schema":{"type":"object","properties":{"line":{"type":"integer","description":"Line number"},"identifier":{"type":"string","description":"Resource identifier, only filled when the resource is a product"},"code":{"type":"string","description":"Resource code, only filled when the resource is not a product"},"status_code":{"type":"integer","description":"HTTP status code, see <a href=\"/documentation/responses.html#client-errors\">Client errors</a> to understand the meaning of each code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"x-example-1":"{\"line\":1,\"code\":\"tshirt_aria_main_picture\",\"status_code\":201}","x-example-2":"{\"line\":2,\"code\":\"tshirt_artemis_maintenance_manual\",\"status_code\":422,\"message\":\"Category \"short_sleeve\" does not exist.\"}","x-example-3":"{\"line\":3,\"code\":\"tshirt_artemis_main_picture\",\"status_code\":204}"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"413":{"description":"Request Entity Too Large","x-details":"There are too many resources to process (max 100) or the line of JSON is too long (max 1 000 000 characters)","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":413,"message":"Too many resources to process, 100 is the maximum allowed."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/vnd.akeneo.collection+json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/vnd.akeneo.collection+json’ is allowed."}}}}},"/api/rest/v1/assets/{code}":{"get":{"summary":"Get a PAM asset","operationId":"get_pam_assets__code_","description":"This endpoint allows you to get the information about a given PAM asset.","tags":["PAM asset"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the PAM asset in JSON format","schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"PAM asset code","x-immutable":true},"categories":{"type":"array","description":"Codes of the PAM asset categories in which the asset is classified","x-validation-rules":"Each string of the array is equal to an existing asset category code","items":{"type":"string"},"default":[]},"description":{"type":"string","description":"Description of the PAM asset","default":null},"localizable":{"type":"boolean","description":"Whether the asset is localized or not, meaning if you want to have different reference files for each of your locale","default":false,"x-immutable":true},"tags":{"type":"array","description":"Tags of the PAM asset","items":{"type":"string"},"default":[]},"end_of_use":{"type":"string","description":"Date on which the PAM asset expire","format":"dateTime","default":null,"x-validation-rules":"The date follows the ISO 8601 format"},"variation_files":{"type":"array","description":"Variations of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the variation file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the variation entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the variation file"}}}}},"locale":{"type":"string","description":"Locale code of the variation"},"scope":{"type":"string","description":"Channel code of the variation"},"code":{"type":"string","description":"Code of the variation"}}}},"reference_files":{"type":"array","description":"Reference files of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the reference file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the reference file entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the reference file"}}}}},"locale":{"type":"string","description":"Locale code of the reference file"},"code":{"type":"string","description":"Code of the reference file"}}}}},"example":{"code":"tshirt_artemis_main_picture","categories":["tshirts_assets"],"description":"The main picture of the Artemis t-shirt","localizable":false,"tags":["tshirts","red","summer"],"end_of_use":"2019-09-01T00:00:00+0200","variation_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale"}},"locale":null,"scope":"e_commerce","code":"7/5/8/e/758e39d48va7b42a55001434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_ecommerce.jpg"},{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale"}},"locale":null,"scope":"print","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_print.jpg"}],"reference_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale"}},"locale":null,"code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture.jpg"}]}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"patch":{"summary":"Update/create a PAM asset","operationId":"patch_pam_assets__code_","tags":["PAM asset"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"description":"This endpoint allows you to update a given PAM asset. Know more about <a href=\"/documentation/update.html#update-behavior\">Update behavior</a>. Note that if no asset exists for the given code, it creates it.","parameters":[{"name":"code","in":"path","description":"Code of the resource","required":true,"type":"string"},{"name":"body","in":"body","required":true,"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"PAM asset code","x-immutable":true},"categories":{"type":"array","description":"Codes of the PAM asset categories in which the asset is classified","x-validation-rules":"Each string of the array is equal to an existing asset category code","items":{"type":"string"},"default":[]},"description":{"type":"string","description":"Description of the PAM asset","default":null},"localizable":{"type":"boolean","description":"Whether the asset is localized or not, meaning if you want to have different reference files for each of your locale","default":false,"x-immutable":true},"tags":{"type":"array","description":"Tags of the PAM asset","items":{"type":"string"},"default":[]},"end_of_use":{"type":"string","description":"Date on which the PAM asset expire","format":"dateTime","default":null,"x-validation-rules":"The date follows the ISO 8601 format"},"variation_files":{"type":"array","description":"Variations of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the variation file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the variation entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the variation file"}}}}},"locale":{"type":"string","description":"Locale code of the variation"},"scope":{"type":"string","description":"Channel code of the variation"},"code":{"type":"string","description":"Code of the variation"}}}},"reference_files":{"type":"array","description":"Reference files of the PAM asset","x-read-only":true,"items":{"type":"object","properties":{"_link":{"type":"object","description":"Links to get and download the reference file","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the reference file entity"}}},"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the reference file"}}}}},"locale":{"type":"string","description":"Locale code of the reference file"},"code":{"type":"string","description":"Code of the reference file"}}}}},"example":{"code":"tshirt_artemis_main_picture","categories":["tshirts_assets"],"description":"The main picture of the Artemis t-shirt","localizable":false,"tags":["tshirts","red","summer"],"end_of_use":"2019-09-01T00:00:00+0200","variation_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale"}},"locale":null,"scope":"e_commerce","code":"7/5/8/e/758e39d48va7b42a55001434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_ecommerce.jpg"},{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/print/no_locale"}},"locale":null,"scope":"print","code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_print.jpg"}],"reference_files":[{"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale/download"},"self":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale"}},"locale":null,"code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture.jpg"}]}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"204":{"description":"No content to return","x-details":"Means that the update was successful","headers":{"Location":{"description":"URI of the updated resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `application/json`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘application/json’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/assets/{asset_code}/reference-files/{locale_code}":{"get":{"summary":"Get a reference file","operationId":"get_reference_files__locale_code_","description":"This endpoint allows you to get the information about a reference file of a given PAM asset.","tags":["PAM asset reference file"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"asset_code","in":"path","description":"Code of the asset","required":true,"type":"string"},{"name":"locale_code","in":"path","description":"Code of the locale if the asset is localizable or equal to `no-locale` if the asset is not localizable","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the reference file in JSON format","schema":{"type":"object","properties":{"code":{"type":"string","description":"Code of the PAM asset reference file","x-immutable":true},"locale":{"type":"string","description":"Locale of the PAM asset reference file, equal to `null` if the asset is not localizable"},"_link":{"type":"object","description":"Links to get and download the reference file","properties":{"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the reference file"}}}}}},"example":{"code":"7/5/8/e/759e39d48va7b42a55002434fd3d7b6cf3189b7f_tshirt_artemis_main_picture.jpg","locale":null,"_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/reference-files/no_locale/download"}}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Upload a new reference file","operationId":"post_reference_files__locale_code_","description":"This endpoint allows you to upload a new reference file for a given PAM asset and locale. It will also automatically generate all the variation files corresponding to this reference file.","tags":["PAM asset reference file"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"asset_code","in":"path","description":"Code of the asset","required":true,"type":"string"},{"name":"locale_code","in":"path","description":"Code of the locale if the asset is localizable or equal to `no-locale` if the asset is not localizable","required":true,"type":"string"},{"name":"Content-type","in":"header","type":"string","description":"Equal to 'multipart/form-data', no other value allowed","required":true},{"name":"body","in":"body","x-form-data":true,"schema":{"required":["file"],"properties":{"file":{"type":"string","description":"The binaries of the file","format":"binary"}}}}],"responses":{"201":{"description":"Uploaded","x-details":"Means that the reference file upload was successful. Beware that even if the reference file upload is complete, some variation files generations could have failed. If so, you will see a warning message in the response body.","headers":{"Location":{"description":"URI of the created resource","type":"string"}},"x-no-entity":true,"schema":{"type":"object","properties":{"message":{"type":"string","description":"Message explaining the warning"},"errors":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","description":"Channel for which the variation file generation failed"},"locale":{"type":"string","description":"Locale for which the variation file generation failed"},"message":{"type":"string","description":"Message explaining why the variation file generation failed"}}}}}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `multipart/form-data`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘multipart/form-data’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/assets/{asset_code}/reference-files/{locale_code}/download":{"get":{"summary":"Download a reference file","operationId":"get_reference_files__channel_code__locale_code__download","description":"This endpoint allows you to download a given reference file.","x-content-type":"Mime-type of the reference file","tags":["PAM asset reference file"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"asset_code","in":"path","description":"Code of the asset","required":true,"type":"string"},{"name":"locale_code","in":"path","description":"Code of the locale if the asset is localizable or equal to `no-locale` if the asset is not localizable","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the binary of the reference file","x-content-type":"Mime-type of the reference file"},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}}}}},"/api/rest/v1/assets/{asset_code}/variation-files/{channel_code}/{locale_code}":{"get":{"summary":"Get a variation file","operationId":"get_variation_files__channel_code__locale_code","description":"This endpoint allows you to get the information about a variation file of a given PAM asset.","tags":["PAM asset variation file"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"asset_code","in":"path","description":"Code of the asset","required":true,"type":"string"},{"name":"channel_code","in":"path","description":"Code of the channel","required":true,"type":"string"},{"name":"locale_code","in":"path","description":"Code of the locale if the asset is localizable or equal to `no-locale` if the asset is not localizable","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the content of the variation file in JSON format","schema":{"type":"object","properties":{"code":{"type":"string","description":"Code of the PAM asset variation file","x-immutable":true},"locale":{"type":"string","description":"Locale of the PAM asset variation file, equal to `null` if the asset is not localizable"},"scope":{"type":"string","description":"Channel of the PAM asset variation file"},"_link":{"type":"object","description":"Links to get and download the reference file","properties":{"download":{"type":"object","properties":{"href":{"type":"string","description":"URI to download the variation file"}}}}}},"example":{"code":"7/5/8/e/758e39d48va7b42a55001434fd3d7b6cf3189b7f_tshirt_artemis_main_picture_ecommerce.jpg","locale":null,"scope":"ecommerce","_link":{"download":{"href":"https://demo.akeneo.com/api/rest/v1/assets/tshirt_artemis_main_picture/variation-files/ecommerce/no_locale/download"}}}}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"406":{"description":"Not Acceptable","x-details":"The `Accept` header is not `application/json` but it should","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":406,"message":"‘xxx’ in ‘Accept‘ header is not valid. Only ‘application/json‘ is allowed."}}}},"post":{"summary":"Upload a new variation file","operationId":"post_variation_files__channel_code__locale_code_","description":"This endpoint allows you to upload a new variation file for a given PAM asset, channel and locale.","tags":["PAM asset variation file"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"asset_code","in":"path","description":"Code of the asset","required":true,"type":"string"},{"name":"channel_code","in":"path","description":"Code of the channel","required":true,"type":"string"},{"name":"locale_code","in":"path","description":"Code of the locale if the asset is localizable or equal to `no-locale` if the asset is not localizable","required":true,"type":"string"},{"name":"Content-type","in":"header","type":"string","description":"Equal to 'multipart/form-data', no other value allowed","required":true},{"name":"body","in":"body","x-form-data":true,"schema":{"required":["file"],"properties":{"file":{"type":"string","description":"The binaries of the file","format":"binary"}}}}],"responses":{"201":{"description":"Created","x-details":"Means that the creation was successful","headers":{"Location":{"description":"URI of the created resource","type":"string"}}},"400":{"description":"Bad request","x-details":"Can be caused by a malformed JSON request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":400,"message":"Invalid JSON message received"}},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}},"415":{"description":"Unsupported Media type","x-details":"The `Content-type` header has to be `multipart/form-data`","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":415,"message":"‘xxx’ in ‘Content-type’ header is not valid. Only ‘multipart/form-data’ is allowed."}},"422":{"description":"Unprocessable entity","x-details":"The validation of the entity given in the body of the request failed","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":422,"message":"Property \"labels\" expects an array as data, \"NULL\" given. Check the API reference documentation.","_links":{"documentation":{"href":"http://api.akeneo.com/api-reference.html"}}}}}}},"/api/rest/v1/assets/{asset_code}/variation-files/{channel_code}/{locale_code}/download":{"get":{"summary":"Download a variation file","operationId":"get_variation_files__channel_code__locale_code__download","description":"This endpoint allows you to download a given variation file.","x-content-type":"Mime-type of the variation file","tags":["PAM asset variation file"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"asset_code","in":"path","description":"Code of the asset","required":true,"type":"string"},{"name":"channel_code","in":"path","description":"Code of the channel","required":true,"type":"string"},{"name":"locale_code","in":"path","description":"Code of the locale if the asset is localizable or equal to `no-locale` if the asset is not localizable","required":true,"type":"string"}],"responses":{"200":{"description":"OK","x-details":"Returns the binary of the variation file","x-content-type":"Mime-type of the variation file"},"401":{"description":"Authentication required","x-details":"Can be caused by a missing or expired token","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":401,"message":"Authentication is required"}},"403":{"description":"Access forbidden","x-details":"The user does not have the permission to execute this request","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":403,"message":"Access forbidden. You are not allowed to list categories."}},"404":{"description":"Resource not found","x-details":"The resource code given in the URI does not correspond to any existing PIM resource","schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code"},"message":{"type":"string","description":"Message explaining the error"}}},"examples":{"code":404,"message":"Resource `my_resource_code` does not exist."}}}}},"/api/rest/v1/asset-categories":{"get":{"summary":"Get list of PAM asset categories","operationId":"get_asset_categories","description":"This endpoint allows you to get a list of PAM asset categories. PAM asset categories are paginated and sorted by `root/left`.","tags":["PAM asset category"],"x-versions":["2.1","2.2","2.3","3.x"],"x-ee":true,"x-deprecated":true,"parameters":[{"name":"page","in":"query","description":"Number of the page to retrieve when using the `page` pagination method type. <strong>Should never be set manually</strong>, see <a href=\"/documentation/pagination.html#pagination\">Pagination</a> section","required":false,"type":"integer","default":1},{"name":"limit","in":"query","description":"Number of results by page, see <a href=\"/documentation/pagination.html\">Pagination</a> section","required":false,"type":"integer","minimum":1,"maximum":100,"default":10},{"name":"with_count","in":"query","description":"Return the count of products in the response. Be carefull with that, on a big catalog, it can decrease performance in a significative way","default":false,"type":"boolean","required":false}],"responses":{"200":{"description":"Returns PAM asset categories paginated","schema":{"title":"PAM Asset Categories","type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the current page of resources"}}},"first":{"type":"object","properties":{"href":{"type":"string","description":"URI of the first page of resources"}}},"previous":{"type":"object","properties":{"href":{"type":"string","description":"URI of the previous page of resources"}}},"next":{"type":"object","properties":{"href":{"type":"string","description":"URI of the next page of resources"}}}}},"current_page":{"type":"integer","description":"Current page number"}}},{"properties":{"_embedded":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","allOf":[{"type":"object","properties":{"_links":{"type":"object","properties":{"self":{"type":"object","properties":{"href":{"type":"string","description":"URI of the resource"}}}}}}},{"type":"object","required":["code"],"properties":{"code":{"type":"string","description":"PAM asset category code","x-immutable":true},"parent":{"type":"string","description":"PAM ssset category code of the parent's asset category","x-validation-rules":"&bull; It is either equal to `null` or to an existing asset category code. &#10;&bull; If equal to an existing asset category code, it cannot reference itself.","default":"null"},"labels":{"type":"object","description":"PAM asset category labels for each locale","x-validation-rules":"The `localeCode` is the code of an existing and activated locale","default":{},"properties":{"localeCode":{"type":"string","description":"PAM asset