> ## Documentation Index
> Fetch the complete documentation index at: https://docs.datawiz.io/connector-api/llms.txt
> Use this file to discover all available pages before exploring further.

# Entity schema

> Field definitions for all upload entities

Column names in upload payloads (`columns` in `POST /uploading/:upload_uuid/:entity_name`) must match the **Field** names below.
Required fields are marked with a red asterisk (<span style={{color: "red"}}>\*</span>).

Field types and required flags reflect the Connector API validation schema. Descriptions are provided where available.

The list of entities enabled for your client is configured by support. See also [Entity upload](/connector-api/integration/entity-upload) and [Entity dependencies](/connector-api/integration/entity-dependencies).

## Stores

<h3 id="store">
  Store
</h3>

`entity_name`: `store`

store master data

| Field                                         | Type             | Description             |
| --------------------------------------------- | ---------------- | ----------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Store identifier        |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Store name              |
| `group_id`                                    | string (max 100) | Stores group identifier |
| `place`                                       | string (max 200) | City                    |
| `address`                                     | string (max 200) | Store address           |
| `trade_area`                                  | decimal          | Store area              |

<h3 id="storegroup">
  StoreGroup
</h3>

`entity_name`: `storegroup`

store group master data

*primary store hierarchy (geography)*

| Field                                         | Type             | Description                    |
| --------------------------------------------- | ---------------- | ------------------------------ |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Stores group identifier        |
| `parent_id`                                   | string (max 100) | Parent stores group identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Stores group name              |

<h3 id="storemarker">
  StoreMarker
</h3>

`entity_name`: `storemarker`

store tag reference

*additional structures / formats (can be created manually via DataConsole)*

| Field                                         | Type             | Description                     |
| --------------------------------------------- | ---------------- | ------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Stores marker identifier        |
| `parent_id`                                   | string (max 100) | Stores parent marker іdentifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Stores marker name              |

<h3 id="storemarkerm2m">
  StoreMarkerM2M
</h3>

`entity_name`: `storemarkerm2m`

store-to-tag mapping

| Field                                              | Type             | Description              |
| -------------------------------------------------- | ---------------- | ------------------------ |
| `store_id` <span style={{color: "red"}}>\*</span>  | string (max 100) | Store identifier         |
| `marker_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Stores marker identifier |

<h3 id="terminal">
  Terminal
</h3>

`entity_name`: `terminal`

POS terminal master data

| Field                                             | Type             | Description         |
| ------------------------------------------------- | ---------------- | ------------------- |
| `id` <span style={{color: "red"}}>\*</span>       | string (max 100) | Terminal identifier |
| `name` <span style={{color: "red"}}>\*</span>     | string (max 200) | Terminal name       |
| `store_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Store identifier    |

<h3 id="terminalmarker">
  TerminalMarker
</h3>

`entity_name`: `terminalmarker`

POS terminal type reference

| Field                                         | Type             | Description                                     |
| --------------------------------------------- | ---------------- | ----------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Cash register type identifier                   |
| `parent_id`                                   | string (max 100) | Identifier of the parent type of cash registers |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Name of cash register type                      |

<h3 id="terminalmarkerm2m">
  TerminalMarkerM2M
</h3>

`entity_name`: `terminalmarkerm2m`

terminal-to-type mapping

| Field                                                | Type             | Description                      |
| ---------------------------------------------------- | ---------------- | -------------------------------- |
| `terminal_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Cash register identifier         |
| `marker_id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Identifier of cash register type |

## Assortment

<h3 id="assortment">
  Assortment
</h3>

`entity_name`: `assortment`

assortment change log

| Field                                                | Type                | Description                                                                                       |
| ---------------------------------------------------- | ------------------- | ------------------------------------------------------------------------------------------------- |
| `product_id` <span style={{color: "red"}}>\*</span>  | string (max 100)    | Product identifier                                                                                |
| `type_id` <span style={{color: "red"}}>\*</span>     | string (max 100)    | Assortment type identifier                                                                        |
| `store_id`                                           | string (max 100)    | Store identifier *If the field is not filled in, then the assortment type applies to all stores.* |
| `modified_at` <span style={{color: "red"}}>\*</span> | date (`YYYY-MM-DD`) | Date of assortment change                                                                         |

<h3 id="assortmenttype">
  AssortmentType
</h3>

`entity_name`: `assortmenttype`

assortment type reference

| Field                                              | Type             | Description                                                                                    |
| -------------------------------------------------- | ---------------- | ---------------------------------------------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>        | string (max 100) | Assortment type identifier                                                                     |
| `name` <span style={{color: "red"}}>\*</span>      | string (max 200) | Assortment type name                                                                           |
| `is_active` <span style={{color: "red"}}>\*</span> | boolean          | Is this an active assortment? *Default always = 0, if = 1, then the assortment type is active* |

<h3 id="brand">
  Brand
</h3>

`entity_name`: `brand`

brand master data

| Field                                         | Type             | Description      |
| --------------------------------------------- | ---------------- | ---------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Brand identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Brand name       |

<h3 id="category">
  Category
</h3>

`entity_name`: `category`

product category master data

*primary category tree*

| Field                                         | Type             | Description                |
| --------------------------------------------- | ---------------- | -------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Category identifier        |
| `parent_id`                                   | string (max 100) | Parent category identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Category name              |

<h3 id="masterposition">
  MasterPosition
</h3>

`entity_name`: `masterposition`

master position product reference

| Field                                         | Type                    | Description                                                                       |
| --------------------------------------------- | ----------------------- | --------------------------------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100)        | Master position identifier                                                        |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200)        | Master position name                                                              |
| `code` <span style={{color: "red"}}>\*</span> | string (max 100)        | Internal code/article of master position                                          |
| `height`                                      | decimal (min 0.001)     | Master position height in m or inches                                             |
| `width`                                       | decimal (min 0.001)     | Master position width in m or inches                                              |
| `depth`                                       | decimal (min 0.001)     | Master position depth in m or inches                                              |
| `height_compression_coef`                     | decimal (min 0, max 90) | Master position compression coefficient in height \[0; 0.9]                       |
| `width_compression_coef`                      | decimal (min 0, max 90) | Master position compression coefficient in width \[0; 0.9]                        |
| `depth_compression_coef`                      | decimal (min 0, max 90) | Master position compression coefficient in depth \[0; 0.9]                        |
| `is_bulk`                                     | boolean                 | Weight master position *Default is always 0, if = 1, then the product is weight.* |
| `note`                                        | string (max 500)        | Master position description                                                       |

<h3 id="masterpositionproductm2m">
  MasterPositionProductM2M
</h3>

`entity_name`: `masterpositionproductm2m`

product-to-master-position mapping

| Field                                                      | Type             | Description                         |
| ---------------------------------------------------------- | ---------------- | ----------------------------------- |
| `product_id` <span style={{color: "red"}}>\*</span>        | string (max 100) | Product identifier                  |
| `masterposition_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Master position identifier          |
| `priority` <span style={{color: "red"}}>\*</span>          | integer          | Product priority in master position |

<h3 id="producer">
  Producer
</h3>

`entity_name`: `producer`

manufacturer master data

| Field                                         | Type             | Description         |
| --------------------------------------------- | ---------------- | ------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Producer identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Producer name       |

<h3 id="product">
  Product
</h3>

`entity_name`: `product`

product master data

| Field                                                | Type             | Description                                        |
| ---------------------------------------------------- | ---------------- | -------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>          | string (max 100) | Product identifier                                 |
| `name` <span style={{color: "red"}}>\*</span>        | string (max 200) | Product name                                       |
| `code` <span style={{color: "red"}}>\*</span>        | string (max 200) | Internal code/product article                      |
| `barcode` <span style={{color: "red"}}>\*</span>     | string (max 500) | Barcode (or multiple barcodes separated by commas) |
| `category_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Category identifier                                |
| `brand_id`                                           | string (max 100) | Brand identifier                                   |
| `producer_id`                                        | string (max 100) | Producer identifier                                |
| `unit_id`                                            | string (max 100) | Unit identifier                                    |

<h3 id="productimage">
  ProductImage
</h3>

`entity_name`: `productimage`

| Field                                               | Type             | Description |
| --------------------------------------------------- | ---------------- | ----------- |
| `product_id` <span style={{color: "red"}}>\*</span> | string (max 100) | —           |
| `image` <span style={{color: "red"}}>\*</span>      | string           | —           |

<h3 id="productmarker">
  ProductMarker
</h3>

`entity_name`: `productmarker`

product tag reference

*additional product hierarchies / attributes (can be created manually via DataConsole)*

| Field                                         | Type             | Description                       |
| --------------------------------------------- | ---------------- | --------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Products marker identifier        |
| `parent_id`                                   | string (max 100) | Parent products marker identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Products marker name              |

<h3 id="productmarkerm2m">
  ProductMarkerM2M
</h3>

`entity_name`: `productmarkerm2m`

product-to-tag mapping

| Field                                               | Type             | Description               |
| --------------------------------------------------- | ---------------- | ------------------------- |
| `product_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Product identifier        |
| `marker_id` <span style={{color: "red"}}>\*</span>  | string (max 100) | Product marker identifier |

<h3 id="productsize">
  ProductSize
</h3>

`entity_name`: `productsize`

| Field                                               | Type                    | Description                                                                  |
| --------------------------------------------------- | ----------------------- | ---------------------------------------------------------------------------- |
| `product_id` <span style={{color: "red"}}>\*</span> | string (max 100)        | —                                                                            |
| `width`                                             | decimal (min 0.001)     | Width of the product, m. Minimal value - 0.001.                              |
| `height`                                            | decimal (min 0.001)     | Height of the product, m. Minimal value - 0.001.                             |
| `depth`                                             | decimal (min 0.001)     | Depth of the product, m. Minimal value - 0.001.                              |
| `height_compression_coef`                           | decimal (min 0, max 90) | Сompression coefficient of the product by height \[0; 90]                    |
| `width_compression_coef`                            | decimal (min 0, max 90) | Сompression coefficient of the product by width \[0; 90]                     |
| `depth_compression_coef`                            | decimal (min 0, max 90) | Сompression coefficient of the product by depth \[0; 90]                     |
| `is_bulk`                                           | boolean                 | Weighing product *Default always = 0, if = 1, then the product is weighted.* |
| `weight`                                            | decimal (min 0.01)      | Product weight *Minimum value - 0.01*                                        |

<h3 id="productstatus">
  ProductStatus
</h3>

`entity_name`: `productstatus`

product-to-status mapping per store

| Field                                               | Type             | Description               |
| --------------------------------------------------- | ---------------- | ------------------------- |
| `product_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Product identifier        |
| `store_id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Store identifier          |
| `status_id` <span style={{color: "red"}}>\*</span>  | string (max 100) | Product status identifier |

<h3 id="recommendedfaces">
  RecommendedFaces
</h3>

`entity_name`: `recommendedfaces`

recommended facings per product

| Field                                               | Type             | Description           |
| --------------------------------------------------- | ---------------- | --------------------- |
| `store_id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Store identifier      |
| `product_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Product identifier    |
| `qty` <span style={{color: "red"}}>\*</span>        | decimal          | Recommended faces qty |

<h3 id="status">
  Status
</h3>

`entity_name`: `status`

product status reference

| Field                                         | Type             | Description                          |
| --------------------------------------------- | ---------------- | ------------------------------------ |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Identifier of the status of products |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Product status name                  |

<h3 id="unit">
  Unit
</h3>

`entity_name`: `unit`

unit of measure reference

| Field                                         | Type             | Description     |
| --------------------------------------------- | ---------------- | --------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Unit identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Unit title      |

## Sales

<h3 id="receipt">
  Receipt
</h3>

`entity_name`: `receipt`

transaction receipts

| Field                                                | Type                             | Description                                                                                                                                                                                                                                         |
| ---------------------------------------------------- | -------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>          | string (max 100)                 | Receipt identifier                                                                                                                                                                                                                                  |
| `store_id` <span style={{color: "red"}}>\*</span>    | string (max 100)                 | Store identifier in receipt                                                                                                                                                                                                                         |
| `terminal_id` <span style={{color: "red"}}>\*</span> | string (max 100)                 | Terminal identifier in receipt                                                                                                                                                                                                                      |
| `opened_at` <span style={{color: "red"}}>\*</span>   | datetime (`YYYY-MM-DD HH:MM:SS`) | Receipt opening date and time                                                                                                                                                                                                                       |
| `closed_at` <span style={{color: "red"}}>\*</span>   | datetime (`YYYY-MM-DD HH:MM:SS`) | Receipt closing date and time                                                                                                                                                                                                                       |
| `loyalty_id`                                         | string (max 100)                 | LP client identifier in receipt                                                                                                                                                                                                                     |
| `staff_id`                                           | string (max 100)                 | Сashier identifier in receipt                                                                                                                                                                                                                       |
| `is_refund`                                          | boolean                          | Is it a return? *Refunds not included in the average receipt. If 1 - it is a refund, if 0 - it is not (default value is 0)*                                                                                                                         |
| `original_receipt_id`                                | string (max 100)                 | Binding to the original receipt, provided that is\_refund = 1. *Default value is NULL*                                                                                                                                                              |
| `is_regular`                                         | boolean                          | Is it a regular sale? *If it is 1 - this receipt will be taken into account in the calculation of the average receipt metric (default value is 1)* *Must be 0 if is\_refund = 1 or is\_excluded = 1*                                                |
| `is_excluded`                                        | boolean                          | Exclude this receipt from the analysis? *Receipts with is\_excluded = 1 will be completely excluded from any calculations and analysis. The data on these checks can be viewed only if you use the "Receipt markers" filter and select "Undefined"* |

<h3 id="receiptitem">
  ReceiptItem
</h3>

`entity_name`: `receiptitem`

receipt line items

| Field                                                      | Type                             | Description                                                                                                                                                                                                                              |
| ---------------------------------------------------------- | -------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>                | string (max 100)                 | Receipt product identifier                                                                                                                                                                                                               |
| `receipt_id` <span style={{color: "red"}}>\*</span>        | string (max 100)                 | Receipt identifier                                                                                                                                                                                                                       |
| `product_id` <span style={{color: "red"}}>\*</span>        | string (max 100)                 | Product identifier                                                                                                                                                                                                                       |
| `scanned_at`                                               | datetime (`YYYY-MM-DD HH:MM:SS`) | Scan of the product in receipt date and time                                                                                                                                                                                             |
| `receipt_closed_at` <span style={{color: "red"}}>\*</span> | datetime (`YYYY-MM-DD HH:MM:SS`) | Receipt closing date and time (from the Receipt entity)                                                                                                                                                                                  |
| `supplier_id`                                              | string (max 100)                 | Product supplier identifier                                                                                                                                                                                                              |
| `price` <span style={{color: "red"}}>\*</span>             | decimal                          | Unit selling price                                                                                                                                                                                                                       |
| `qty` <span style={{color: "red"}}>\*</span>               | decimal                          | Sales qty *If is\_refund = 1 (refund receipt), then the value of qty must be negative.*                                                                                                                                                  |
| `discount`                                                 | decimal                          | Discount amount (discount\*products qty)                                                                                                                                                                                                 |
| `turnover` <span style={{color: "red"}}>\*</span>          | decimal                          | The final price of the product paid by the customer (sales) *Cannot be empty. It must match the following condition* *turnover = qty\*price-discount* *If is\_refund = 1 (refund receipt), then the value of turnover must be negative.* |
| `cost_price` <span style={{color: "red"}}>\*</span>        | decimal                          | Unit cost price of product                                                                                                                                                                                                               |
| `profit`                                                   | decimal                          | Profit *If profit is not transmitted, then by default* *profit = (price-cost\_price)\*qty- discount* *If is\_refund = 1 (refund receipt), then the value of profit must be negative.*                                                    |
| `total_vat`                                                | decimal                          | Tax amount (VAT\*products qty)                                                                                                                                                                                                           |
| `total_excise`                                             | decimal                          | Amount of excise duty (excise\*products qty)                                                                                                                                                                                             |
| `advisor_id`                                               | string (max 100)                 | Sales consultant identifier in receiptitem                                                                                                                                                                                               |
| `commission`                                               | decimal                          | Commission amount per unit of product *If is\_refund = 1 (refund receipt), the commission value must be negative or equal to 0.*                                                                                                         |

<h3 id="receiptmarker">
  ReceiptMarker
</h3>

`entity_name`: `receiptmarker`

receipt tag reference

*transaction types: wholesale, online, cash, etc.*

| Field                                         | Type             | Description                |
| --------------------------------------------- | ---------------- | -------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Receipts marker identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Receipts marker name       |

<h3 id="receiptmarkerm2m">
  ReceiptMarkerM2M
</h3>

`entity_name`: `receiptmarkerm2m`

receipt-to-tag mapping

| Field                                                 | Type                             | Description                                 |
| ----------------------------------------------------- | -------------------------------- | ------------------------------------------- |
| `receipt_id` <span style={{color: "red"}}>\*</span>   | string (max 100)                 | Receipt identifier                          |
| `marker_id` <span style={{color: "red"}}>\*</span>    | string (max 100)                 | Receipt marker identifier                   |
| `receipt_date` <span style={{color: "red"}}>\*</span> | datetime (`YYYY-MM-DD HH:MM:SS`) | Date of the receipt this record belongs to. |

## Promotions

<h3 id="promotion">
  Promotion
</h3>

`entity_name`: `promotion`

promotion master data

*can be created manually via DataConsole*

| Field                                              | Type                | Description                                                                   |
| -------------------------------------------------- | ------------------- | ----------------------------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>        | string (max 100)    | Promo identifier                                                              |
| `name` <span style={{color: "red"}}>\*</span>      | string (max 200)    | Promo name                                                                    |
| `code`                                             | string (max 200)    | Internal promo code (comming soon...)                                         |
| `type_id`                                          | string (max 100)    | Promo type identifier                                                         |
| `is_demo`                                          | boolean             | Is this a demo promo? *1 is a demo promo, 0 is a regular promo. By default 0* |
| `note`                                             | string (max 500)    | Note on the promotion                                                         |
| `adv_cost`                                         | decimal             | Marketing expenses                                                            |
| `date_from` <span style={{color: "red"}}>\*</span> | date (`YYYY-MM-DD`) | Promo start date                                                              |
| `date_to`                                          | date (`YYYY-MM-DD`) | Promo end date                                                                |
| `is_hidden_sm`                                     | boolean             | —                                                                             |
| `is_receiptitem`                                   | boolean             | —                                                                             |

<h3 id="promotionproductm2m">
  PromotionProductM2M
</h3>

`entity_name`: `promotionproductm2m`

promotional products

| Field                                               | Type             | Description                                                             |
| --------------------------------------------------- | ---------------- | ----------------------------------------------------------------------- |
| `promo_id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Promo identifier                                                        |
| `store_id`                                          | string (max 100) | Store identifier *If no store is specified, then it acts on the chain.* |
| `product_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Promo product identifier                                                |
| `promo_price`                                       | decimal          | Promo product price                                                     |

<h3 id="promotionreceiptitemm2m">
  PromotionReceiptitemM2M
</h3>

`entity_name`: `promotionreceiptitemm2m`

promotional receipt line items

| Field                                                   | Type                | Description                                 |
| ------------------------------------------------------- | ------------------- | ------------------------------------------- |
| `promo_id` <span style={{color: "red"}}>\*</span>       | string (max 100)    | Promo identifier                            |
| `receiptitem_id` <span style={{color: "red"}}>\*</span> | string (max 100)    | Promo product identifier in receipt         |
| `receipt_date` <span style={{color: "red"}}>\*</span>   | date (`YYYY-MM-DD`) | Date of the receipt this record belongs to. |
| `discount`                                              | decimal             | Discount amount (discount\*products qty)    |

<h3 id="promotiontype">
  PromotionType
</h3>

`entity_name`: `promotiontype`

promotion type reference

*can be created manually via DataConsole*

| Field                                         | Type             | Description           |
| --------------------------------------------- | ---------------- | --------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Promo type identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Promo type name       |

## Logistics

<h3 id="posting">
  Posting
</h3>

`entity_name`: `posting`

inventory adjustment documents (stock count results)

| Field                                               | Type                             | Description                                              |
| --------------------------------------------------- | -------------------------------- | -------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>         | string (max 100)                 | Posting document identifier                              |
| `code` <span style={{color: "red"}}>\*</span>       | string (max 200)                 | External posting document code                           |
| `created_at` <span style={{color: "red"}}>\*</span> | datetime (`YYYY-MM-DD HH:MM:SS`) | Posting document date and time                           |
| `store_id` <span style={{color: "red"}}>\*</span>   | string (max 100)                 | Store or warehouse identifier                            |
| `staff_id`                                          | string (max 100)                 | Responsible employee identifier (author of the document) |

<h3 id="postingproduct">
  PostingProduct
</h3>

`entity_name`: `postingproduct`

inventory adjustment line items

| Field                                                 | Type                | Description                                                               |
| ----------------------------------------------------- | ------------------- | ------------------------------------------------------------------------- |
| `document_id` <span style={{color: "red"}}>\*</span>  | string (max 100)    | Posting document identifier                                               |
| `product_id` <span style={{color: "red"}}>\*</span>   | string (max 100)    | Product identifier                                                        |
| `posting_date` <span style={{color: "red"}}>\*</span> | date (`YYYY-MM-DD`) | Date of the posting document this line belongs to.                        |
| `qty` <span style={{color: "red"}}>\*</span>          | decimal             | Posting products qty                                                      |
| `cost_price` <span style={{color: "red"}}>\*</span>   | decimal             | Unit cost price of product                                                |
| `value`                                               | decimal             | Total cost price of the posting *By default, auto-filled by the formula:* |

<h3 id="purchaseorder">
  PurchaseOrder
</h3>

`entity_name`: `purchaseorder`

purchase order documents

| Field                                                | Type                             | Description                                              |
| ---------------------------------------------------- | -------------------------------- | -------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>          | string (max 100)                 | Order document identifier                                |
| `code` <span style={{color: "red"}}>\*</span>        | string (max 200)                 | External order document code                             |
| `created_at` <span style={{color: "red"}}>\*</span>  | datetime (`YYYY-MM-DD HH:MM:SS`) | Order document date and time                             |
| `store_id` <span style={{color: "red"}}>\*</span>    | string (max 100)                 | Store identifier                                         |
| `supplier_id` <span style={{color: "red"}}>\*</span> | string (max 100)                 | Supplier identifier                                      |
| `staff_id`                                           | string (max 100)                 | Responsible employee identifier (author of the document) |

<h3 id="purchaseorderproduct">
  PurchaseOrderProduct
</h3>

`entity_name`: `purchaseorderproduct`

purchase order line items

| Field                                                       | Type                | Description                                                                                                                                                                     |
| ----------------------------------------------------------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `document_id` <span style={{color: "red"}}>\*</span>        | string (max 100)    | Order document identifier                                                                                                                                                       |
| `product_id` <span style={{color: "red"}}>\*</span>         | string (max 100)    | Product identifier in order document                                                                                                                                            |
| `purchaseorder_date` <span style={{color: "red"}}>\*</span> | date (`YYYY-MM-DD`) | Date of the purchase order document this line belongs to.                                                                                                                       |
| `qty` <span style={{color: "red"}}>\*</span>                | decimal             | Ordered product qty                                                                                                                                                             |
| `cost_price` <span style={{color: "red"}}>\*</span>         | decimal             | Unit cost price of product                                                                                                                                                      |
| `value`                                                     | decimal             | Total cost price of the ordered products *If the field is not filled in, the field is auto- filled by the formula* *PurchaseOrderProduct.qty\*PurchaseOrderProduct.cost\_price* |

<h3 id="receive">
  Receive
</h3>

`entity_name`: `receive`

goods receipt documents

| Field                                                | Type                             | Description                                              |
| ---------------------------------------------------- | -------------------------------- | -------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>          | string (max 100)                 | Receiving document identifier                            |
| `code` <span style={{color: "red"}}>\*</span>        | string (max 200)                 | External receiving document code                         |
| `created_at` <span style={{color: "red"}}>\*</span>  | datetime (`YYYY-MM-DD HH:MM:SS`) | Receiving document date and time                         |
| `supplier_id` <span style={{color: "red"}}>\*</span> | string (max 100)                 | Supplier identifier                                      |
| `store_id` <span style={{color: "red"}}>\*</span>    | string (max 100)                 | Store identifier                                         |
| `purchaseorder_id`                                   | string (max 100)                 | —                                                        |
| `staff_id`                                           | string (max 100)                 | Responsible employee identifier (author of the document) |

<h3 id="receiveproduct">
  ReceiveProduct
</h3>

`entity_name`: `receiveproduct`

goods receipt line items

| Field                                                 | Type                | Description                                                                         |
| ----------------------------------------------------- | ------------------- | ----------------------------------------------------------------------------------- |
| `document_id` <span style={{color: "red"}}>\*</span>  | string (max 100)    | Receiving document identifier                                                       |
| `product_id` <span style={{color: "red"}}>\*</span>   | string (max 100)    | Product identifier in receiving document                                            |
| `receive_date` <span style={{color: "red"}}>\*</span> | date (`YYYY-MM-DD`) | Date of the receive document this line belongs to.                                  |
| `qty` <span style={{color: "red"}}>\*</span>          | decimal             | Received product qty                                                                |
| `cost_price` <span style={{color: "red"}}>\*</span>   | decimal             | Unit cost price of product                                                          |
| `value`                                               | decimal             | Total cost price of the received products *By default, auto-filled by the formula:* |
| `deferment`                                           | integer             | Payment delay in days                                                               |
| `produced_at`                                         | date (`YYYY-MM-DD`) | Product produced date                                                               |
| `sell_by_date`                                        | date (`YYYY-MM-DD`) | Best used before the `date`                                                         |

<h3 id="relocate">
  Relocate
</h3>

`entity_name`: `relocate`

inter-store transfer documents

| Field                                                      | Type                             | Description                                              |
| ---------------------------------------------------------- | -------------------------------- | -------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>                | string (max 100)                 | Relocation document identifier                           |
| `code` <span style={{color: "red"}}>\*</span>              | string (max 200)                 | External relocation document code                        |
| `created_at` <span style={{color: "red"}}>\*</span>        | datetime (`YYYY-MM-DD HH:MM:SS`) | Relocation document date and time                        |
| `store_sender_id` <span style={{color: "red"}}>\*</span>   | string (max 100)                 | Sender store identifier                                  |
| `store_receiver_id` <span style={{color: "red"}}>\*</span> | string (max 100)                 | Receiver store identifier                                |
| `staff_id`                                                 | string (max 100)                 | Responsible employee identifier (author of the document) |

<h3 id="relocateproduct">
  RelocateProduct
</h3>

`entity_name`: `relocateproduct`

transfer document line items

| Field                                                  | Type                | Description                                                                          |
| ------------------------------------------------------ | ------------------- | ------------------------------------------------------------------------------------ |
| `document_id` <span style={{color: "red"}}>\*</span>   | string (max 100)    | Relocation document identifier                                                       |
| `product_id` <span style={{color: "red"}}>\*</span>    | string (max 100)    | Product identifier in relocation document                                            |
| `relocate_date` <span style={{color: "red"}}>\*</span> | date (`YYYY-MM-DD`) | Date of the relocate document this line belongs to.                                  |
| `supplier_id`                                          | string (max 100)    | Supplier identifier                                                                  |
| `qty` <span style={{color: "red"}}>\*</span>           | decimal             | Relocated products qty                                                               |
| `cost_price` <span style={{color: "red"}}>\*</span>    | decimal             | Unit cost price of product                                                           |
| `value`                                                | decimal             | Total cost price of the relocated products *By default, auto-filled by the formula:* |

<h3 id="stock">
  Stock
</h3>

`entity_name`: `stock`

inventory stock levels

| Field                                               | Type                | Description                 |
| --------------------------------------------------- | ------------------- | --------------------------- |
| `store_id` <span style={{color: "red"}}>\*</span>   | string (max 100)    | Store identifier            |
| `product_id` <span style={{color: "red"}}>\*</span> | string (max 100)    | Product identifier          |
| `supplier_id`                                       | string (max 100)    | Supplier identifier         |
| `dt` <span style={{color: "red"}}>\*</span>         | date (`YYYY-MM-DD`) | Date of stocks availability |
| `qty` <span style={{color: "red"}}>\*</span>        | decimal             | Stock qty                   |
| `value` <span style={{color: "red"}}>\*</span>      | decimal             | Stock total cost            |

<h3 id="writeoff">
  Writeoff
</h3>

`entity_name`: `writeoff`

write-off documents

| Field                                               | Type                             | Description                                              |
| --------------------------------------------------- | -------------------------------- | -------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>         | string (max 100)                 | Write-off document identifier                            |
| `code` <span style={{color: "red"}}>\*</span>       | string (max 200)                 | External write-off document code                         |
| `created_at` <span style={{color: "red"}}>\*</span> | datetime (`YYYY-MM-DD HH:MM:SS`) | Write-off document date and time                         |
| `type_id` <span style={{color: "red"}}>\*</span>    | string (max 100)                 | Write-off type identifier                                |
| `store_id` <span style={{color: "red"}}>\*</span>   | string (max 100)                 | Store or warehouse identifier                            |
| `staff_id`                                          | string (max 100)                 | Responsible employee identifier (author of the document) |

<h3 id="writeoffproduct">
  WriteoffProduct
</h3>

`entity_name`: `writeoffproduct`

write-off document line items

| Field                                                  | Type                | Description                                                                           |
| ------------------------------------------------------ | ------------------- | ------------------------------------------------------------------------------------- |
| `document_id` <span style={{color: "red"}}>\*</span>   | string (max 100)    | Write-off document identifier                                                         |
| `product_id` <span style={{color: "red"}}>\*</span>    | string (max 100)    | Writte-off product identifier                                                         |
| `writeoff_date` <span style={{color: "red"}}>\*</span> | date (`YYYY-MM-DD`) | Date of the write-off document this line belongs to.                                  |
| `supplier_id` <span style={{color: "red"}}>\*</span>   | string (max 100)    | Supplier identifier                                                                   |
| `qty` <span style={{color: "red"}}>\*</span>           | decimal             | Write-off products qty                                                                |
| `cost_price` <span style={{color: "red"}}>\*</span>    | decimal             | Unit cost price of product                                                            |
| `value`                                                | decimal             | Total cost price of the writen off products *By default, auto-filled by the formula:* |

<h3 id="writeofftype">
  WriteoffType
</h3>

`entity_name`: `writeofftype`

shrinkage / write-off type reference

| Field                                         | Type             | Description               |
| --------------------------------------------- | ---------------- | ------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Write-off type identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Write-off type name       |

## Supplier

<h3 id="supplier">
  Supplier
</h3>

`entity_name`: `supplier`

supplier master data

| Field                                         | Type             | Description            |
| --------------------------------------------- | ---------------- | ---------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Supplier identifier    |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Supplier name          |
| `code`                                        | string (max 200) | Internal supplier code |

<h3 id="supplierbonus">
  SupplierBonus
</h3>

`entity_name`: `supplierbonus`

supplier bonuses / trade terms

| Field                                                | Type                             | Description                                                                                              |
| ---------------------------------------------------- | -------------------------------- | -------------------------------------------------------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>          | string (max 100)                 | Bonus identifier                                                                                         |
| `type_id` <span style={{color: "red"}}>\*</span>     | string (max 100)                 | Bonus type identifier                                                                                    |
| `store_id`                                           | string (max 100)                 | Store identifier *If the field is not filled in, then bonuses are divided into all stores*               |
| `supplier_id` <span style={{color: "red"}}>\*</span> | string (max 100)                 | Supplier identifier                                                                                      |
| `product_id`                                         | string (max 100)                 | Product identifier                                                                                       |
| `date_from` <span style={{color: "red"}}>\*</span>   | datetime (`YYYY-MM-DD HH:MM:SS`) | Bonus start date                                                                                         |
| `date_to` <span style={{color: "red"}}>\*</span>     | datetime (`YYYY-MM-DD HH:MM:SS`) | Bonus end date                                                                                           |
| `bonus` <span style={{color: "red"}}>\*</span>       | decimal                          | The amount of money received from suppliers as a bonus from the sale of products for the selected period |

<h3 id="supplierbonustype">
  SupplierBonusType
</h3>

`entity_name`: `supplierbonustype`

supplier bonus type reference

| Field                                         | Type             | Description           |
| --------------------------------------------- | ---------------- | --------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Bonus type identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Bonus type name       |

<h3 id="suppliermarker">
  SupplierMarker
</h3>

`entity_name`: `suppliermarker`

supplier tag reference

*can be created manually via DataConsole*

| Field                                         | Type             | Description                        |
| --------------------------------------------- | ---------------- | ---------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Suppliers marker identifier        |
| `parent_id`                                   | string (max 100) | Suppliers parent marker identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Suppliers marker name              |

<h3 id="suppliermarkerm2m">
  SupplierMarkerM2M
</h3>

`entity_name`: `suppliermarkerm2m`

supplier-to-tag mapping

| Field                                                | Type             | Description                 |
| ---------------------------------------------------- | ---------------- | --------------------------- |
| `supplier_id` <span style={{color: "red"}}>\*</span> | string (max 100) | Supplier identifier         |
| `marker_id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Suppliers marker identifier |

<h3 id="supplierpercentbonus">
  SupplierPercentBonus
</h3>

`entity_name`: `supplierpercentbonus`

| Field                                                  | Type                             | Description |
| ------------------------------------------------------ | -------------------------------- | ----------- |
| `id` <span style={{color: "red"}}>\*</span>            | string (max 100)                 | —           |
| `type_id` <span style={{color: "red"}}>\*</span>       | string (max 100)                 | —           |
| `store_id`                                             | string (max 100)                 | —           |
| `supplier_id` <span style={{color: "red"}}>\*</span>   | string (max 100)                 | —           |
| `product_id`                                           | string (max 100)                 | —           |
| `date_from` <span style={{color: "red"}}>\*</span>     | datetime (`YYYY-MM-DD HH:MM:SS`) | —           |
| `date_to` <span style={{color: "red"}}>\*</span>       | datetime (`YYYY-MM-DD HH:MM:SS`) | —           |
| `bonus_percent` <span style={{color: "red"}}>\*</span> | decimal                          | —           |

<h3 id="supplierproductm2m">
  SupplierProductM2M
</h3>

`entity_name`: `supplierproductm2m`

supplier product assortment

| Field                                                | Type                | Description                                                            |
| ---------------------------------------------------- | ------------------- | ---------------------------------------------------------------------- |
| `supplier_id` <span style={{color: "red"}}>\*</span> | string (max 100)    | Supplier identifier                                                    |
| `store_id`                                           | string (max 100)    | Store identifier *If no store is specified, then it acts on the chain* |
| `product_id` <span style={{color: "red"}}>\*</span>  | string (max 100)    | Product identifier                                                     |
| `date_from` <span style={{color: "red"}}>\*</span>   | date (`YYYY-MM-DD`) | Contract start date                                                    |
| `date_to`                                            | date (`YYYY-MM-DD`) | Contract end date                                                      |

<h3 id="supplierrefund">
  SupplierRefund
</h3>

`entity_name`: `supplierrefund`

supplier return documents

| Field                                                | Type                             | Description                                              |
| ---------------------------------------------------- | -------------------------------- | -------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>          | string (max 100)                 | Return document identifier                               |
| `code` <span style={{color: "red"}}>\*</span>        | string (max 200)                 | External return document code                            |
| `created_at` <span style={{color: "red"}}>\*</span>  | datetime (`YYYY-MM-DD HH:MM:SS`) | Return document date and time                            |
| `supplier_id` <span style={{color: "red"}}>\*</span> | string (max 100)                 | Supplier identifier (who received a return)              |
| `store_id` <span style={{color: "red"}}>\*</span>    | string (max 100)                 | Store identifier                                         |
| `staff_id`                                           | string (max 100)                 | Responsible employee identifier (author of the document) |

<h3 id="supplierrefundproduct">
  SupplierRefundProduct
</h3>

`entity_name`: `supplierrefundproduct`

supplier return line items

| Field                                                | Type                | Description                                                                                                                                                       |
| ---------------------------------------------------- | ------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `document_id` <span style={{color: "red"}}>\*</span> | string (max 100)    | Return document identifier                                                                                                                                        |
| `product_id` <span style={{color: "red"}}>\*</span>  | string (max 100)    | Product identifier                                                                                                                                                |
| `refund_date` <span style={{color: "red"}}>\*</span> | date (`YYYY-MM-DD`) | Date of the supplier refund document this line belongs to.                                                                                                        |
| `qty` <span style={{color: "red"}}>\*</span>         | decimal             | Returned products qty                                                                                                                                             |
| `cost_price` <span style={{color: "red"}}>\*</span>  | decimal             | Unit cost price of product                                                                                                                                        |
| `value`                                              | decimal             | Total cost price of the returned products to the supplier *By default, auto-filled by the formula* *SupplierRefundProduct.qty\*SupplierRefundProduct.cost\_price* |

## Price Reference

<h3 id="pricedocument">
  PriceDocument
</h3>

`entity_name`: `pricedocument`

price update documents

| Field                                              | Type                             | Description               |
| -------------------------------------------------- | -------------------------------- | ------------------------- |
| `id` <span style={{color: "red"}}>\*</span>        | string (max 100)                 | Price document identifier |
| `type_id` <span style={{color: "red"}}>\*</span>   | string (max 100)                 | Price type identifier     |
| `date_from` <span style={{color: "red"}}>\*</span> | datetime (`YYYY-MM-DD HH:MM:SS`) | Price start date          |
| `date_to`                                          | date (`YYYY-MM-DD`)              | Price end date            |

<h3 id="priceproduct">
  PriceProduct
</h3>

`entity_name`: `priceproduct`

product price assignments

| Field                                                | Type                             | Description                                      |
| ---------------------------------------------------- | -------------------------------- | ------------------------------------------------ |
| `document_id` <span style={{color: "red"}}>\*</span> | string (max 100)                 | Price document identifier                        |
| `product_id` <span style={{color: "red"}}>\*</span>  | string (max 100)                 | Product identifier                               |
| `price_date` <span style={{color: "red"}}>\*</span>  | datetime (`YYYY-MM-DD HH:MM:SS`) | Date of the price document this line belongs to. |
| `a_price` <span style={{color: "red"}}>\*</span>     | decimal                          | Product price                                    |

<h3 id="pricestore">
  PriceStore
</h3>

`entity_name`: `pricestore`

store-level price assignments

| Field                                                | Type                             | Description                                      |
| ---------------------------------------------------- | -------------------------------- | ------------------------------------------------ |
| `document_id` <span style={{color: "red"}}>\*</span> | string (max 100)                 | Price document identifier                        |
| `store_id` <span style={{color: "red"}}>\*</span>    | string (max 100)                 | Store identifier                                 |
| `price_date` <span style={{color: "red"}}>\*</span>  | datetime (`YYYY-MM-DD HH:MM:SS`) | Date of the price document this line belongs to. |

<h3 id="pricetype">
  PriceType
</h3>

`entity_name`: `pricetype`

price type reference

| Field                                         | Type             | Description                                                                         |
| --------------------------------------------- | ---------------- | ----------------------------------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Price type identifier                                                               |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Price type name                                                                     |
| `is_actual`                                   | boolean          | Is this the current price? *By default always = 0, if it is = 1, then it's current* |

## Staff

<h3 id="categorymanagercategorym2m">
  CategoryManagerCategoryM2M
</h3>

`entity_name`: `categorymanagercategorym2m`

category manager scope — category assignments

| Field                                                | Type                | Description                                                                                                                                 |
| ---------------------------------------------------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------- |
| `staff_id` <span style={{color: "red"}}>\*</span>    | string (max 100)    | Category manager identifier                                                                                                                 |
| `store_id`                                           | string (max 100)    | Store identifier ( if the manager has access to all stores, do not fill it in)                                                              |
| `category_id` <span style={{color: "red"}}>\*</span> | string (max 100)    | Category identifier                                                                                                                         |
| `date_from` <span style={{color: "red"}}>\*</span>   | date (`YYYY-MM-DD`) | Start date of work with the category *If the field is not filled in, then the date of the first reporting period is automatically entered.* |
| `date_to`                                            | date (`YYYY-MM-DD`) | End date of work with the category                                                                                                          |

<h3 id="categorymanagerproductm2m">
  CategoryManagerProductM2M
</h3>

`entity_name`: `categorymanagerproductm2m`

category manager scope — product assignments

| Field                                               | Type                | Description                                                                                                                                |
| --------------------------------------------------- | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| `staff_id` <span style={{color: "red"}}>\*</span>   | string (max 100)    | Category manager identifier                                                                                                                |
| `store_id`                                          | string (max 100)    | Store identifier ( if the manager has access to all stores, do not fill it in)                                                             |
| `product_id` <span style={{color: "red"}}>\*</span> | string (max 100)    | Product identifier                                                                                                                         |
| `date_from` <span style={{color: "red"}}>\*</span>  | date (`YYYY-MM-DD`) | Start date of work with the product *If the field is not filled in, then the date of the first reporting period is automatically entered.* |
| `date_to`                                           | date (`YYYY-MM-DD`) | End date of work with the product                                                                                                          |

<h3 id="staff">
  Staff
</h3>

`entity_name`: `staff`

employee master data

*cashiers, category managers, sales advisors*

| Field                                         | Type             | Description               |
| --------------------------------------------- | ---------------- | ------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Employee identifier       |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Name of the employee      |
| `group_id`                                    | string (max 100) | Employee group identifier |

<h3 id="staffgroup">
  StaffGroup
</h3>

`entity_name`: `staffgroup`

employee group reference

| Field                                         | Type             | Description                                                                                          |
| --------------------------------------------- | ---------------- | ---------------------------------------------------------------------------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | Staff group identifier                                                                               |
| `parent_id`                                   | string (max 100) | Staff parent group identifier                                                                        |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | Staff group name                                                                                     |
| `is_categorymanager`                          | boolean          | Default is set to "0", if set to "1", the employee of this group is identified as a category manager |
| `is_cashier`                                  | boolean          | Default is set to "0", if set to "1", the employee of this group is identified as a cashier          |
| `is_advisor`                                  | boolean          | Default is set to "0", if set to "1", the employee of this group is identified as a sales consultant |

## Loyalty

<h3 id="loyalty">
  Loyalty
</h3>

`entity_name`: `loyalty`

loyalty programme customer master data

| Field                                           | Type                | Description                                                        |
| ----------------------------------------------- | ------------------- | ------------------------------------------------------------------ |
| `id` <span style={{color: "red"}}>\*</span>     | string (max 100)    | LP client identifier                                               |
| `cardno` <span style={{color: "red"}}>\*</span> | string (max 20)     | LP client's discount card number                                   |
| `group_id`                                      | string (max 100)    | LP client group identifier                                         |
| `birthday`                                      | date (`YYYY-MM-DD`) | Date of birth LP client                                            |
| `registration_date`                             | date (`YYYY-MM-DD`) | Date of registration of the client LP                              |
| `gender`                                        | boolean             | Gender (male/female) *If 1 - male, 0 - female, Null - not defined* |

<h3 id="loyaltybonus">
  LoyaltyBonus
</h3>

`entity_name`: `loyaltybonus`

loyalty customer bonus register

| Field                                                | Type                             | Description                                                                                |
| ---------------------------------------------------- | -------------------------------- | ------------------------------------------------------------------------------------------ |
| `id` <span style={{color: "red"}}>\*</span>          | string (max 100)                 | Bonus identifier                                                                           |
| `record_type` <span style={{color: "red"}}>\*</span> | integer                          | Is it bonuses write-off? (0 - accumulation, 1 - write-off)                                 |
| `loyalty_id` <span style={{color: "red"}}>\*</span>  | string (max 100)                 | LP client identifier                                                                       |
| `receipt_id`                                         | string (max 100)                 | Receipt identifier                                                                         |
| `product_id`                                         | string (max 100)                 | Product identifier                                                                         |
| `created_at` <span style={{color: "red"}}>\*</span>  | datetime (`YYYY-MM-DD HH:MM:SS`) | Date of bonus accrual                                                                      |
| `bonus` <span style={{color: "red"}}>\*</span>       | decimal                          | Bonus amount in monetary units (if it is a write-off, the bonus amount should be negative) |

<h3 id="loyaltygroup">
  LoyaltyGroup
</h3>

`entity_name`: `loyaltygroup`

loyalty customer group reference

*primary hierarchy*

| Field                                         | Type             | Description                        |
| --------------------------------------------- | ---------------- | ---------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | LP clients group identifier        |
| `parent_id`                                   | string (max 100) | LP clients parent group identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | LP clients group name              |

<h3 id="loyaltymarker">
  LoyaltyMarker
</h3>

`entity_name`: `loyaltymarker`

loyalty customer tag reference

*additional structure (can be created manually via DataConsole)*

| Field                                         | Type             | Description                         |
| --------------------------------------------- | ---------------- | ----------------------------------- |
| `id` <span style={{color: "red"}}>\*</span>   | string (max 100) | LP clients marker identifier        |
| `parent_id`                                   | string (max 100) | LP clients parent marker identifier |
| `name` <span style={{color: "red"}}>\*</span> | string (max 200) | LP clients marker name              |

<h3 id="loyaltymarkerm2m">
  LoyaltyMarkerM2M
</h3>

`entity_name`: `loyaltymarkerm2m`

loyalty customer-to-tag mapping

| Field                                               | Type             | Description                 |
| --------------------------------------------------- | ---------------- | --------------------------- |
| `loyalty_id` <span style={{color: "red"}}>\*</span> | string (max 100) | LP client identifier        |
| `marker_id` <span style={{color: "red"}}>\*</span>  | string (max 100) | LP client marker identifier |
