PATCH /company/categories/@id
This endpoint requires authentication.
Header | Value |
---|---|
Authorization | Set the value to Bearer + + access_token |
Replace the @ keywords in the URL with their corresponding value.
A dictionary with fields
Field | Type | Description |
---|---|---|
id | Int | The ID of the category you want to update |
Pass the following properties via application/json or form encoding in the body of the request.
Field | Type | Description |
---|---|---|
name | [Language: String] | Translated category name |
description | [Language: String] | Description of this category |
active | Bool | A boolean value |
only_order_in_store | Bool | Whether this product can only get ordered in the store with a separate UI for the shop employees, and not in the public webshop |
shop_ids | [Int] | Minimum 1. IDs of the shops the category will be available for |
seo | company.SeoData | Optional. The category's webpage search engine metatags |
product_ids | [Int] | Optional. Set the order of the products in a category by setting the IDs of the products in the right order. You can't add or remove products, only change the order. Don't set this field if you don't want to make changes. |
PATCH /company/categories/16 HTTP/1.1
Host: api.bakeronline.be
X-VERSION: 1.5.1
Accept-Language: en-US,en;q=0.5
Content-Type: application/json
Content-Length: 723
{
"name": "Jaiden Brakus DDS",
"description": {
"nl": "...",
"en": "...",
"fr": "..."
},
"active": false,
"only_order_in_store": true,
"shop_ids": [
16,
11,
13
],
"seo": {
"title": {
"en": "Sunt earum dolor similique aspernatur qui a sint."
},
"description": {
"en": "Eius laboriosam velit quia. Voluptas quo voluptas et. Sed perspiciatis voluptatem autem sunt perspiciatis consequatur accusamus."
},
"url": {
"en": "http://www.collins.org/velit-aut-accusamus-aut-ipsa-placeat-possimus"
}
},
"product_ids": [
18,
15,
16
]
}
Field | Type | Description |
---|---|---|
name | [Language: String] | Translated category name |
description | [Language: String] | Description of this category |
active | Bool | A boolean value |
only_order_in_store | Bool | Whether this product can only get ordered in the store with a separate UI for the shop employees, and not in the public webshop |
products | [company.Product.simple] | Array of company.Product.simple |
shops | [company.Shop.simple] | Array of company.Shop.simple |
id | Int | ID of the category |
banner | Image? | Nullable. |
seo | company.SeoData | Optional. The category's webpage search engine metatags |
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Content-Length: 13166
{
"name": "Dortha Kunde",
"description": {
"nl": "...",
"en": "...",
"fr": "..."
},
"active": true,
"only_order_in_store": true,
"products": [
{
"name": {
"nl": "...",
"en": "...",
"fr": "..."
},
"description": {
"nl": "...",
"en": "...",
"fr": "..."
},
"specialty": false,
"active": true,
"only_order_in_store": true,
"price_type": "PER_UNIT",
"price": 18,
"target_price": true,
"url_type": "none",
"url": "https://example.com",
"min_max": {
"amount": {
"minimum": 14,
"maximum": 19,
"maximum_day": 14,
"maximum_week": 12
},
"weight": {
"minimum": 16,
"maximum": 19,
"maximum_day": 10,
"maximum_week": 14,
"suggested": 12
},
"persons": {
"minimum": 11,
"maximum": 17
}
},
"id": 12,
"allergens": [
{
"id": 14,
"name": "Celery"
},
{
"id": 12,
"name": "Fish"
},
{
"id": 14,
"name": "Celery"
}
],
"category_id": 13,
"price_look_up_code": "...",
"code": "...",
"seo": {
"title": {
"en": "Architecto enim perferendis quisquam magnam eius."
},
"description": {
"en": "Rerum est amet mollitia deleniti. Atque facilis minima quo laudantium quibusdam esse eos. Nihil consequatur id est quibusdam labore id ab. Qui aut molestiae debitis qui sed commodi."
},
"url": {
"en": "http://braun.biz/reprehenderit-dolor-laboriosam-dicta-repellat-delectus"
}
}
},
{
"name": {
"nl": "...",
"en": "...",
"fr": "..."
},
"description": {
"nl": "...",
"en": "...",
"fr": "..."
},
"specialty": true,
"active": false,
"only_order_in_store": true,
"price_type": "PER_UNIT",
"price": 15,
"target_price": true,
"url_type": "none",
"url": "https://example.com",
"min_max": {
"amount": {
"minimum": 13,
"maximum": 14,
"maximum_day": 18,
"maximum_week": 11
},
"weight": {
"minimum": 11,
"maximum": 10,
"maximum_day": 14,
"maximum_week": 17,
"suggested": 19
},
"persons": {
"minimum": 19,
"maximum": 14
}
},
"id": 13,
"allergens": [
{
"id": 13,
"name": "Celery"
},
{
"id": 13,
"name": "Fish"
},
{
"id": 15,
"name": "Egg"
}
],
"category_id": 17,
"price_look_up_code": "...",
"code": "...",
"seo": {
"title": {
"en": "Architecto fuga nemo non qui a molestiae recusandae dolores reprehenderit eos."
},
"description": {
"en": "Beatae minima vel id in porro. Dignissimos et dolor hic illum. Et repudiandae voluptas aperiam assumenda ratione amet autem."
},
"url": {
"en": "http://www.volkman.net/"
}
}
},
{
"name": {
"nl": "...",
"en": "...",
"fr": "..."
},
"description": {
"nl": "...",
"en": "...",
"fr": "..."
},
"specialty": false,
"active": false,
"only_order_in_store": false,
"price_type": "PER_UNIT",
"price": 12,
"target_price": false,
"url_type": "none",
"url": "https://example.com",
"min_max": {
"amount": {
"minimum": 15,
"maximum": 10,
"maximum_day": 10,
"maximum_week": 19
},
"weight": {
"minimum": 17,
"maximum": 12,
"maximum_day": 12,
"maximum_week": 14,
"suggested": 16
},
"persons": {
"minimum": 14,
"maximum": 14
}
},
"id": 11,
"allergens": [
{
"id": 18,
"name": "Soy"
},
{
"id": 18,
"name": "Gluten"
},
{
"id": 10,
"name": "Egg"
}
],
"category_id": 10,
"price_look_up_code": "...",
"code": "...",
"seo": {
"title": {
"en": "Est natus sunt dicta sint nisi perferendis aut quia est."
},
"description": {
"en": "Rem consequatur deserunt voluptas et. Est laboriosam delectus mollitia at voluptas in."
},
"url": {
"en": "http://www.beier.com/qui-nisi-optio-autem-in-fuga-autem-qui"
}
}
}
],
"shops": [
{
"name": "Miss Christiana Murazik",
"active": true,
"address": {
"street": "Sint-Denijslaan",
"nr": "96",
"zipcode": "9000",
"city": "Gent",
"country": "BE",
"position": {
"latitude": 1.54361,
"longitude": 0.45645
}
},
"allow_comments": true,
"allow_orders": false,
"delivery_use_intervals": true,
"allow_invoices": true,
"id": 15,
"avatar": {
"resolutions": [
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
}
],
"white_background": true
},
"banner": {
"resolutions": [
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
}
],
"white_background": true
}
},
{
"name": "Jalon Dickinson",
"active": false,
"address": {
"street": "Sint-Denijslaan",
"nr": "96",
"zipcode": "9000",
"city": "Gent",
"country": "BE",
"position": {
"latitude": 1.54361,
"longitude": 0.45645
}
},
"allow_comments": false,
"allow_orders": true,
"delivery_use_intervals": false,
"allow_invoices": true,
"id": 18,
"avatar": {
"resolutions": [
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
}
],
"white_background": true
},
"banner": {
"resolutions": [
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
}
],
"white_background": true
}
},
{
"name": "Jillian Windler",
"active": false,
"address": {
"street": "Sint-Denijslaan",
"nr": "96",
"zipcode": "9000",
"city": "Gent",
"country": "BE",
"position": {
"latitude": 1.54361,
"longitude": 0.45645
}
},
"allow_comments": false,
"allow_orders": true,
"delivery_use_intervals": false,
"allow_invoices": false,
"id": 14,
"avatar": {
"resolutions": [
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
}
],
"white_background": false
},
"banner": {
"resolutions": [
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
}
],
"white_background": true
}
}
],
"id": 19,
"banner": {
"resolutions": [
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
},
{
"src": "https://example.com",
"width": 600,
"height": 350
}
],
"white_background": true
},
"seo": {
"title": {
"en": "Neque fugiat qui et repudiandae repellat numquam."
},
"description": {
"en": "Vero qui aut temporibus non maiores ut et temporibus. Ex saepe dolor fugit est iure. Maxime odio et esse saepe sunt totam."
},
"url": {
"en": "http://huels.com/"
}
}
}