๐ŸŽš๏ธModifiers

This page provides a description of the available API routes for managing modifiers.

The data model for modifier is represented by Modifier class.

API methods

Get modifiers

GET http://{server-address}/modifiers

Returns all modifiers that matches query parameters. Result is of type QueryResult<Modifier>.

Query Parameters

NameTypeDescription

Id

string

Supports NData syntax.

$skip

int

Pagination property. Describing number of records to skip from beginning of result collection.

$take

int

Pagination property. Maximum count of items to be returned.

$sort

string[]

Comma separated list of property names. Please see NData syntax.

$count

bool

If set to true, response will not contain items collection. Use to get resource count, not the resources themselves.

Name

string

Supports NData syntax.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

{
    "items":
    [
        {
            "id": "657b20bbde0bfde5af0f59dd",
            "name": "Steak doneness",
            "displayName": "How do you like your steak cooked?",
            "minimumSelectedOptionsCount": 1,
            "maximumSelectedOptionsCount": 1,
            "maximumSelectedOptionsTotalQuantity": 1,
            "options":
            [
                {
                    "id": "c0b15868-bc3d-4c63-bf58-8b0a47a613c9",
                    "name": "Rare",
                    "unitPrice": null,
                    "isUnitPriceIncludingVat": true,
                    "pluId": null,
                    "defaultSelectedQuantity": 0,
                    "maximumSelectedQuantity": 1
                },
                {
                    "id": "0f74604d-8eeb-4c35-8f07-91730c7a80da",
                    "name": "Medium rare",
                    "unitPrice": null,
                    "isUnitPriceIncludingVat": true,
                    "pluId": null,
                    "defaultSelectedQuantity": 1,
                    "maximumSelectedQuantity": 1
                },
                {
                    "id": "e39889b9-3f1a-4f07-9d90-97edc1f8623c",
                    "name": "Medium",
                    "unitPrice": null,
                    "isUnitPriceIncludingVat": true,
                    "pluId": null,
                    "defaultSelectedQuantity": 0,
                    "maximumSelectedQuantity": 1
                },
                {
                    "id": "fcbad5e7-5e45-415c-bc02-90a2d5c4818c",
                    "name": "Medium well",
                    "unitPrice": null,
                    "isUnitPriceIncludingVat": true,
                    "pluId": null,
                    "defaultSelectedQuantity": 0,
                    "maximumSelectedQuantity": 1
                },
                {
                    "id": "a2b6b6de-6a87-40a0-9d10-4be83314e5dd",
                    "name": "Well done",
                    "unitPrice": null,
                    "isUnitPriceIncludingVat": true,
                    "pluId": null,
                    "defaultSelectedQuantity": 0,
                    "maximumSelectedQuantity": 1
                }
            ],
            "_v": 1
        },
        {
            "id": "65847589d77a632b9674c99c",
            "name": "side dishes for meat",
            "displayName": "Add a side",
            "minimumSelectedOptionsCount": 1,
            "maximumSelectedOptionsCount": 2,
            "maximumSelectedOptionsTotalQuantity": 2,
            "options":
            [
                {
                    "id": "c0b15868-bc3d-4c63-bf58-8b0a47a613c1",
                    "name": "Mashed Potatoes",
                    "unitPrice":
                    {
                        "amount": 4.90,
                        "currencyLabel": "EUR"
                    },
                    "isUnitPriceIncludingVat": true,
                    "pluId":
                    {
                        "code": 2,
                        "stockName": "S01"
                    },
                    "defaultSelectedQuantity": 0,
                    "maximumSelectedQuantity": null
                },
                {
                    "id": "0f74604d-8eeb-4c35-8f07-91730c7a80d5",
                    "name": "Grilled Vegetables",
                    "unitPrice":
                    {
                        "amount": 4.70,
                        "currencyLabel": "EUR"
                    },
                    "isUnitPriceIncludingVat": true,
                    "pluId":
                    {
                        "code": 3,
                        "stockName": "S01"
                    },
                    "defaultSelectedQuantity": 0,
                    "maximumSelectedQuantity": null
                }
            ],
            "_v": 7
        }
    ],
    "count": 2,
    "totalCount": 2
}

Get modifier by ID

GET http://{server-address}/modifiers/{id}

Result is of type Modifier.

Path Parameters

NameTypeDescription

id*

string

Unique modifier identifier.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

{
    "id": "657b20bbde0bfde5af0f59dd",
    "name": "Steak doneness",
    "displayName": "How do you like your steak cooked?",
    "minimumSelectedOptionsCount": 1,
    "maximumSelectedOptionsCount": 1,
    "maximumSelectedOptionsTotalQuantity": 1,
    "options":
    [
        {
            "id": "c0b15868-bc3d-4c63-bf58-8b0a47a613c9",
            "name": "Rare",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "0f74604d-8eeb-4c35-8f07-91730c7a80da",
            "name": "Medium rare",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 1,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "e39889b9-3f1a-4f07-9d90-97edc1f8623c",
            "name": "Medium",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "fcbad5e7-5e45-415c-bc02-90a2d5c4818c",
            "name": "Medium well",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "a2b6b6de-6a87-40a0-9d10-4be83314e5dd",
            "name": "Well done",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        }
    ],
    "_v": 1
}

Create modifier

POST http://{server-address}/modifiers

Creates new modifier. Result is of type Modifier.

Required rights

Authorized user must have ModifierCreate right assigned.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

Request Body

NameTypeDescription

(body)*

Modifier

Model to create

{
    "id": "657b20bbde0bfde5af0f59dd",
    "name": "Steak doneness",
    "displayName": "How do you like your steak cooked?",
    "minimumSelectedOptionsCount": 1,
    "maximumSelectedOptionsCount": 1,
    "maximumSelectedOptionsTotalQuantity": 1,
    "options":
    [
        {
            "id": "c0b15868-bc3d-4c63-bf58-8b0a47a613c9",
            "name": "Rare",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "0f74604d-8eeb-4c35-8f07-91730c7a80da",
            "name": "Medium rare",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 1,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "e39889b9-3f1a-4f07-9d90-97edc1f8623c",
            "name": "Medium",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "fcbad5e7-5e45-415c-bc02-90a2d5c4818c",
            "name": "Medium well",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "a2b6b6de-6a87-40a0-9d10-4be83314e5dd",
            "name": "Well done",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        }
    ],
    "_v": 1
}

Create or update modifier

PUT http://{server-address}/modifiers/{id}

Updates existing or creates new modifier. Result is of type Modifier.

Required rights

Authorized user must have assigned ModifierCreate or ModifierUpdate right.

Path Parameters

NameTypeDescription

id*

string

Unique modifier identifier.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

Request Body

NameTypeDescription

(body)*

Modifier

Modifier model to create or update.

{
    "id": "657b20bbde0bfde5af0f59dd",
    "name": "Steak doneness",
    "displayName": "How do you like your steak cooked?",
    "minimumSelectedOptionsCount": 1,
    "maximumSelectedOptionsCount": 1,
    "maximumSelectedOptionsTotalQuantity": 1,
    "options":
    [
        {
            "id": "c0b15868-bc3d-4c63-bf58-8b0a47a613c9",
            "name": "Rare",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "0f74604d-8eeb-4c35-8f07-91730c7a80da",
            "name": "Medium rare",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 1,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "e39889b9-3f1a-4f07-9d90-97edc1f8623c",
            "name": "Medium",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "fcbad5e7-5e45-415c-bc02-90a2d5c4818c",
            "name": "Medium well",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "a2b6b6de-6a87-40a0-9d10-4be83314e5dd",
            "name": "Well done",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        }
    ],
    "_v": 2
}

Delete modifier by ID

DELETE http://{server-address}/modifiers/{id}

Required rights

Authorized user must have ModifierDelete right assigned.

Path Parameters

NameTypeDescription

id*

string

Unique modifier identifier.

Headers

NameTypeDescription

Authorization*

string

Authorization header with authorization token.

{
    "id": "657b20bbde0bfde5af0f59dd",
    "name": "Steak doneness",
    "displayName": "How do you like your steak cooked?",
    "minimumSelectedOptionsCount": 1,
    "maximumSelectedOptionsCount": 1,
    "maximumSelectedOptionsTotalQuantity": 1,
    "options":
    [
        {
            "id": "c0b15868-bc3d-4c63-bf58-8b0a47a613c9",
            "name": "Rare",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "0f74604d-8eeb-4c35-8f07-91730c7a80da",
            "name": "Medium rare",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 1,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "e39889b9-3f1a-4f07-9d90-97edc1f8623c",
            "name": "Medium",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "fcbad5e7-5e45-415c-bc02-90a2d5c4818c",
            "name": "Medium well",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        },
        {
            "id": "a2b6b6de-6a87-40a0-9d10-4be83314e5dd",
            "name": "Well done",
            "unitPrice": null,
            "isUnitPriceIncludingVat": true,
            "pluId": null,
            "defaultSelectedQuantity": 0,
            "maximumSelectedQuantity": 1
        }
    ],
    "_v": 1
}

Last updated