Skip to main content

API Models

This section describes the data models (schemas) used in the QMenu API. Click on a model name below to view its details.

Error

Represents an error response from the API.

FieldTypeDescriptionExample
codestringError code (see below for possible values)C0002
messagestringHuman-readable error messageInvalid token

Possible Error Codes:

  • C0000 - Success
  • C0001 - Bad request
  • C0002 - Invalid credentials
  • ...

Example:

{
"code": "C0002",
"message": "Invalid token"
}

Token

Represents an authorization token.

FieldTypeDescriptionExample
tokenstringAuthorization tokeneyJhbGciOi...

Example:

{
"token": "eyJhbGciOi..."
}

Represents a menu, which contains a list of categories.

FieldTypeDescription
namestringMenu name
categoriesarrayList of categories in menu

Category

Represents a category within a menu, which can contain subcategories and products.

FieldTypeDescription
idstringCategory ID
iconstringCategory icon
namestringCategory name
photostringCategory photo URL
childrenarrayList of subcategories (Category)
productsarrayList of products in this category

Product

Represents a product (menu item).

FieldTypeDescription
namestringProduct name
descriptionstringProduct description
specificationstringProduct specification
imagestringProduct image URL
categorystringCategory ID
bonusstringBonus name
statestringProduct state
withNotebooleanTrue if product can have a note
variantsarrayList of variants for this product

Variant

Represents a product variant (e.g., size, flavor).

FieldTypeDescription
idstringVariant ID
namestringVariant name
pricenumberVariant price
salePricenumberVariant sale price
statestringVariant state
codestringVariant code
barCodestringVariant barcode
optionsarrayList of options for variant

Option

Represents an option for a variant (e.g., add-ons, choices).

FieldTypeDescription
idstringOption ID
namestringOption name
typestringOption type
pricenumberOption price
statestringOption state
valuesarrayList of possible values

Order

Represents an order placed by a customer.

FieldTypeDescription
idstringOrder ID
datestringOrder date
numberstringOrder number
statestringOrder status (NEW, ACCEPTED, etc.)
paymentStatestringPayment state (UNPAID, PAID, PARTIAL)
addressstringDelivery address
floornumberFloor number
registerstringRegister ID
buyerstringBuyer name
contactstringContact info
commentstringOrder comment
deliveryDatestringDelivery date
totalAmountnumberTotal amount
discountAmountnumberDiscount amount
taxAmountnumberTax amount
cityTaxstringCity tax
grandTotalnumberGrand total
penaltyAmountnumberPenalty amount
loyaltyAmountnumberLoyalty amount
loyaltyBalancenumberLoyalty balance
vatAmountnumberVAT amount
vatExcludeAmountnumberVAT excluded amount
vatIncludeAmountnumberVAT included amount
vatTypestringVAT type (0: No VAT, 1: Citizen, 3: Org)
vatBillIdstringVAT bill ID
createdAtstringCreated at
updatedAtstringUpdated at
orderedAtstringOrdered at
acceptedAtstringAccepted at
preparingAtstringPreparing at
preparedAtstringPrepared at
deliveringAtstringDelivering at
deliveredAtstringDelivered at
completedAtstringCompleted at
reviewedbooleanWhether the order is reviewed
itemsarrayList of order items
chargesarrayList of order charges
discountsarrayList of order discounts
transactionsarrayList of order transactions

OrderItem

Represents an item in an order.

FieldTypeDescription
idstringOrder item ID
namestringItem name
variantNamestringVariant name
codestringItem code
barCodestringItem barcode
imagestringItem image
statestringItem state
pricenumberItem price
quantitynumberQuantity
commentstringComment
optionsarrayList of item options

OrderItemOption

Represents an option for an order item.

FieldTypeDescription
idstringOption ID
namestringOption name
pricenumberOption price
valuestringOption value

OrderDiscount

Represents a discount applied to an order.

FieldTypeDescription
idstringDiscount ID
namestringDiscount name
amountnumberDiscount amount

OrderCharge

Represents a charge applied to an order.

FieldTypeDescription
idstringCharge ID
namestringCharge name
amountnumberCharge amount

OrderReview

Represents a review for an order.

FieldTypeDescription
idstringReview ID
typestringReview type (S: Service, D: Delivery)
likednumberLiked rating
commentstringReview comment
additionalstringAdditional comments
picturesarrayList of review pictures
uploadsarrayList of review uploads
createdAtstringCreated at
updatedAtstringUpdated at

OrderInput

Represents the input for creating an order.

FieldTypeDescription
typestringOrder type (Dining, Delivery, etc.)
itemsarrayList of order items
addressstringAddress
contactstringContact
commentstringComment
deliveryDatestringDelivery date

OrderItemInput

Represents the input for an order item.

FieldTypeDescription
idstringVariant ID
quantitynumberQuantity
commentstringComment
optionsarrayList of item options

OrderItemOptionInput

Represents the input for an order item option.

FieldTypeDescription
idstringOption ID
valuestringOption value

Payment

Represents a payment method.

FieldTypeDescription
idstringPayment ID
namestringPayment name
typestringPayment type

PaymentInput

Represents the input for a payment.

FieldTypeDescription
paymentstringPayment ID
amountnumberPayment amount
vatTypestringVAT type
registerstringOrganization registration number
buyerstringOrganization name
codestringPayment code

Transaction

Represents a transaction.

FieldTypeDescription
idstringTransaction ID
typestringPayment type
statestringTransaction state
amountnumberTransaction amount
currencystringTransaction currency
descriptionstringTransaction description
linksarrayList of transaction links
createdAtstringCreated at
updatedAtstringUpdated at

Represents a link related to a transaction.

FieldTypeDescription
namestringLink name
descriptionstringLink description
logostringLink logo URL
urlstringLink URL

Kitchen

Represents a kitchen.

FieldTypeDescription
idstringKitchen ID
namestringKitchen name

Task

Represents a task in the system.

FieldTypeDescription
idstringTask ID
datestringTask date
statestringTask state (PENDING, ONGOING, READY, COMPLETED, CANCELLED)
kitchenIdstringKitchen ID
orderNostringOrder number
orderTypestringOrder type
tablestringTable ID
itemsarrayList of task items
createdAtstringCreated at
updatedAtstringUpdated at
startedAtstringStarted at
endedAtstringEnded at

TaskItem

Represents an item in a task.

FieldTypeDescription
idstringTask item ID
namestringTask item name
quantitynumberQuantity
statestringTask item state
commentstringComment
startedAtstringStarted at
endedAtstringEnded at
optionsarrayList of task item options

TaskItemOption

Represents an option for a task item.

FieldTypeDescription
idstringOption ID
namestringOption name
valuestringOption value

Table

Represents a table in the restaurant.

FieldTypeDescription
idstringTable ID
namestringTable name