Update a category

PATCH /company/categories/@id

Request

Authentication

This endpoint requires authentication.

Header Value
Authorization Set the value to Bearer + + access_token

URL parameters

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

Body

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
seo company.SeoData Optional. The category's webpage search engine metatags

Example request 1

PATCH /company/categories/19 HTTP/1.1
Host: api.bakeronline.be
X-VERSION: 0.2.1
Accept-Language: en-US,en;q=0.5
Content-Type: application/json
Content-Length: 687
{
    "name": "Ms. Amara Murphy III",
    "description": {
        "nl": "...",
        "en": "...",
        "fr": "..."
    },
    "active": true,
    "only_order_in_store": false,
    "seo": {
        "title": {
            "en": "Nesciunt voluptatem praesentium voluptatum doloribus nihil fugiat quia ut sit aliquam."
        },
        "description": {
            "en": "Libero nam est fugit error ipsum. Necessitatibus eum et doloremque suscipit. Nostrum autem inventore quis est. Odio dolor numquam enim dolorem qui et laborum vitae."
        },
        "url": {
            "en": "https://www.pfannerstill.org/iste-animi-est-voluptate-consequatur-nisi-quisquam"
        }
    }
}

Response

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

Example response 1

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Content-Length: 13128

{
    "name": "Prof. Mohammad Mayert",
    "description": {
        "nl": "...",
        "en": "...",
        "fr": "..."
    },
    "active": true,
    "only_order_in_store": false,
    "products": [
        {
            "name": {
                "nl": "...",
                "en": "...",
                "fr": "..."
            },
            "description": {
                "nl": "...",
                "en": "...",
                "fr": "..."
            },
            "specialty": false,
            "active": true,
            "only_order_in_store": true,
            "price_type": "PER_UNIT",
            "price": 13,
            "target_price": true,
            "url_type": "none",
            "url": "https://example.com",
            "min_max": {
                "amount": {
                    "minimum": 19,
                    "maximum": 14,
                    "maximum_day": 12,
                    "maximum_week": 15
                },
                "weight": {
                    "minimum": 11,
                    "maximum": 16,
                    "maximum_day": 11,
                    "maximum_week": 15,
                    "suggested": 11
                },
                "persons": {
                    "minimum": 18,
                    "maximum": 14
                }
            },
            "id": 11,
            "allergens": [
                {
                    "id": 10,
                    "name": "Sesame"
                },
                {
                    "id": 15,
                    "name": "Mustard"
                },
                {
                    "id": 19,
                    "name": "Fish"
                }
            ],
            "price_look_up_code": "...",
            "seo": {
                "title": {
                    "en": "Eaque tempore quam repellendus neque eos distinctio expedita delectus tenetur."
                },
                "description": {
                    "en": "Voluptatem laboriosam voluptatem voluptatibus in unde illo accusamus. Ut dolorem natus pariatur deserunt enim. Cum veritatis est deserunt fugiat doloremque."
                },
                "url": {
                    "en": "http://conn.com/et-saepe-similique-culpa-reprehenderit-vel"
                }
            }
        },
        {
            "name": {
                "nl": "...",
                "en": "...",
                "fr": "..."
            },
            "description": {
                "nl": "...",
                "en": "...",
                "fr": "..."
            },
            "specialty": false,
            "active": true,
            "only_order_in_store": true,
            "price_type": "PER_UNIT",
            "price": 12,
            "target_price": true,
            "url_type": "none",
            "url": "https://example.com",
            "min_max": {
                "amount": {
                    "minimum": 14,
                    "maximum": 18,
                    "maximum_day": 19,
                    "maximum_week": 11
                },
                "weight": {
                    "minimum": 10,
                    "maximum": 17,
                    "maximum_day": 15,
                    "maximum_week": 17,
                    "suggested": 16
                },
                "persons": {
                    "minimum": 17,
                    "maximum": 18
                }
            },
            "id": 15,
            "allergens": [
                {
                    "id": 15,
                    "name": "Egg"
                },
                {
                    "id": 18,
                    "name": "Soy"
                },
                {
                    "id": 17,
                    "name": "Egg"
                }
            ],
            "price_look_up_code": "...",
            "seo": {
                "title": {
                    "en": "Sed adipisci aut commodi impedit in incidunt."
                },
                "description": {
                    "en": "Sit odit aut nihil id consequatur et omnis. Excepturi consequatur odio a possimus iure dolores. Quo id non alias necessitatibus possimus ut quo."
                },
                "url": {
                    "en": "http://willms.com/rem-et-deserunt-temporibus-labore-consequatur-voluptates-qui-placeat"
                }
            }
        },
        {
            "name": {
                "nl": "...",
                "en": "...",
                "fr": "..."
            },
            "description": {
                "nl": "...",
                "en": "...",
                "fr": "..."
            },
            "specialty": true,
            "active": true,
            "only_order_in_store": true,
            "price_type": "PER_UNIT",
            "price": 11,
            "target_price": false,
            "url_type": "none",
            "url": "https://example.com",
            "min_max": {
                "amount": {
                    "minimum": 15,
                    "maximum": 15,
                    "maximum_day": 12,
                    "maximum_week": 12
                },
                "weight": {
                    "minimum": 15,
                    "maximum": 17,
                    "maximum_day": 13,
                    "maximum_week": 19,
                    "suggested": 10
                },
                "persons": {
                    "minimum": 16,
                    "maximum": 13
                }
            },
            "id": 10,
            "allergens": [
                {
                    "id": 12,
                    "name": "Peanut"
                },
                {
                    "id": 14,
                    "name": "Sesame"
                },
                {
                    "id": 13,
                    "name": "Gluten"
                }
            ],
            "price_look_up_code": "...",
            "seo": {
                "title": {
                    "en": "Quis suscipit placeat voluptatibus nam ea error aut sint dolores."
                },
                "description": {
                    "en": "Aspernatur porro sit commodi quidem eum voluptatem. Sunt quia est dolores atque. Totam ut dicta neque dicta incidunt. Ab quia est omnis minus non in nesciunt."
                },
                "url": {
                    "en": "http://ankunding.info/dolor-enim-saepe-voluptas-voluptatem"
                }
            }
        }
    ],
    "shops": [
        {
            "name": "Logan Terry",
            "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": true,
            "delivery_use_intervals": true,
            "id": 12,
            "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
            }
        },
        {
            "name": "Ms. Pearlie Ernser Jr.",
            "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": 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": false
            }
        },
        {
            "name": "Prof. Cheyanne Wiza IV",
            "active": false,
            "address": {
                "street": "Sint-Denijslaan",
                "nr": "96",
                "zipcode": "9000",
                "city": "Gent",
                "country": "BE",
                "position": {
                    "latitude": 1.54361,
                    "longitude": 0.45645
                }
            },
            "allow_comments": true,
            "allow_orders": true,
            "delivery_use_intervals": 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": 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": false
            }
        }
    ],
    "id": 17,
    "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": "Dolor pariatur sint fugit in ipsum aperiam aut."
        },
        "description": {
            "en": "Amet distinctio velit necessitatibus et voluptatem aspernatur. Assumenda sed sunt et non. Id rerum dolorem temporibus officia error dolor odio. Sunt voluptatibus nesciunt blanditiis culpa."
        },
        "url": {
            "en": "http://www.klein.com/et-facere-provident-libero-nesciunt-excepturi"
        }
    }
}
Version update available Please adjust your integration to the latest stable version (1.9.0)
0.2.1 stable