Tax Definition
POST /tax-definition/entity/<entity_id>
DELETE /tax-definition/entity/<entity_id>
POST /tax-definition/updateEntitiesWithDependencies
GET /tax-definition/document/<_id>
PATCH /tax-definition/document/<_id>
DELETE /tax-definition/document/<_id>
GET /tax-definition/mapping/entity/<entity_id>
POST /tax-definition/mapping/entity/<entity_id>
Endpoints
GET /tax-definition/master
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
query |
| int32 | No | The maximum documents to return |
query |
| int32 | No | The documents to skip before returning |
query |
| string | No | A filter expression in OData v4 format |
query |
| string | No | An order by expression in OData v4 format |
query |
| boolean | No | Hydrates-related nested objects when returning a result (For example, populate a menu with menu categories and menu groups) |
query |
| boolean | No | Include the mappings for the document in the response |
query |
| [ csv of string ] | No | Specifies |
query |
| boolean | No | Includes the documents that inactive for the current sites |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| integer | |
| [ array, object ] | |
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity." |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The consumption types. The possible values are "OnPremises" or "OffPremises." |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate the total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The auto-assigned unique identifier (UID) of the entity, set on creation. All future versions of the entity share the same |
| boolean | |
| boolean | Marking property is the essence of active documents. Sets in |
| string | |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The last date and time (date-time) the document was updated |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
GET /tax-definition/current
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
header |
| [ csv of string ] | No | The unique identifiers (UIDs) of the site to manage data for |
query |
| string | No | A filter expression in OData v4 format |
query |
| int32 | No | The maximum documents to return |
query |
| int32 | No | The documents to skip before returning |
query |
| string | No | An order by expression in OData v4 format |
query |
| string | Yes | The date and time to query against |
query |
| [ string ] | No | An array of entity identifiers |
query |
| boolean | No | Hydrates-related nested objects when returning a result (For example, populate a menu with menu categories and menu groups) |
query |
| boolean | No | Include the mappings for the document in the response |
query |
| [ csv of string ] | No | Specifies entity types for which mappings are presented as a part of the response (For example, |
query |
| [ csv of string ] | No | Specifies |
query |
| boolean | No | Adds audit fields to each document when returning a result ( |
query |
| boolean | No | Includes the documents that are inactive for the current sites |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| integer | |
| [ array, object ] | |
| string | The name of the tax ( For example, NC sales tax) |
| string | The possible valudes are "fixed_amount" or "fixed_rate." Specifies the type of the tax rate. |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string | The scope of the conditions. The possible values are "order," "item," and "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" and "count." The total of the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The possible valudes are "OnPremises" or "OffPremises" |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first then loop back and calculate tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value the "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value . |
| boolean | The tax buckets which have this value as true are collectively rounded instead of individually rounded to calculate the total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The auto-assigned UID of the entity, set on creation. All future versions of the entity share the same |
| boolean | |
| boolean | Marking property is the essence of active documents. Sets in |
| string | |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The date and time (date-time) the document was created |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
GET /tax-definition/list
Request Parameters
In | Field Name | Type | Required | Description | Unique |
|---|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for | |
header |
| array, csv of string | No | The identifiers of the site to manage data for | Yes |
query |
| string | No | A filter expression in OData v4 format | |
query |
| int32 | No | The maximum documents to return | |
query |
| int32 | No | The documents to skip before returning | |
query |
| string | No | An order by expression in OData v4 format | |
query |
| string | Yes | The date and time to query against | |
query |
| string | No | An array of entity identifiers | |
query |
| boolean | No | Hydrates-related nested objects when returning a result (For example, populate a menu with menu categories and menu groups) | |
query |
| array, csv of string | No | Specifies | |
query |
| boolean | No | Adds audit fields to each document when returning a result ( | |
query |
| boolean | No | Includes the documents that are inactive for the current sites | |
query |
| array, csv of string | No | Specifies entity types for which mappings are presented as a part of the response (For example, |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| integer | |
| [ array, object ] | |
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity." |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The consumption types. The possible values are "OnPremises" or "OffPremises." |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." The rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The auto-assigned unique identifier (UID) of the entity, set on creation. All future versions of the entity share the same |
| boolean | |
| boolean | Marking property is the essence of active documents. Sets in |
| string | |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The last date and time (date-time) the document was updated |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
POST /tax-definition
Field Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
query |
| boolean | No | Hydrates-related nested objects when returning a result (For example, populate a menu with menu categories and menu groups) |
query |
| [ csv of string ] | No | Specifies |
body |
| Yes | The JSON formatted request |
Request Body
Field Name | Type | Description |
|---|---|---|
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The consumption types. The possible values are "OnPremises" or "OffPremises." |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned unique identifier (UID) of the entity, set on creation. All future versions of the entity share the same |
| string |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The consumption types. The possible values are "OnPremises" or "OffPremises." |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No.> The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The auto-assigned UID of the entity, set on creation. All future versions of the entity share the same |
| boolean | |
| boolean | Marking property is the essence of active documents. Sets in |
| string | |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The last date and time (date-time) the document was updated |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
POST /tax-definition/entity/<entity_id>
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
path |
| string | Yes | The identifier of the entity |
body |
| Yes | The JSON formatted request |
Request Body
Field Name | Type | Description |
|---|---|---|
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The possible values are "OnPremises"or "OffPremises." |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value . |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned unique identifier (UID) of the entity, set on creation. All future versions of the entity share the same |
| string |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| string | The name of the tax (For example NC sales tax) |
| string | Specifies the type of tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The possible values are "OnPremises" or "OffPremises" |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No". If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned system document identifiers |
| string | The identifier of the company who owns the document |
| string | The auto-assigned unique identifier (UID) of the entity, set on creation. All future versions of the entity share the same |
| boolean | |
| boolean | Marking property is the essence of active documents. Sets in |
| string | |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that updated the document |
| string | The date and time (date-time) the document was created |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
DELETE /tax-definition/entity/<entity_id>
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
path |
| string | Yes | The identifier of the entity |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
POST /tax-definition/updateEntitiesWithDependencies
Request Parameters
In | Name | Field Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
header |
| [ csv of string ] | No | The unique identifiers (UIDs) of the site to manage data for |
body |
|
| Yes | Supports the mappings field (array/boolean) for each document. With mappings: True mappings are created for the current date and sites from the |
Request Body
Field Name | Type | Description |
|---|---|---|
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The possible values are "OnPremises" or "OffPremises" |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned UID of the entity, set on creation. All future versions of the entity share the same |
| string |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| integer | |
| [ array, object ] | |
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" and "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The possible values are "OnPremises" or "OffPremises" |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The auto-assigned UID of the entity, set on creation. All future versions of the entity share the same |
| boolean | |
| boolean | Marking property is the essence of active documents. Sets in |
| string | |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The date and time (date-time) the document was created |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
GET /tax-definition/document/<_id>
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
path |
| string | Yes | The identifier of the document |
query |
| boolean | No | Hydrates-related nested objects when returning a result (For example, populate a menu with menu categories and menu groups) |
query |
| [ csv of string ] | No | Specifies |
query |
| [ csv of string ] | No | Specifies entity types for which mappings are presented as a part of the response (For example, |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| string | The name of the tax (For example, NC sales tax ) |
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations |
| [ string, object ] | The list of destination entity identifiers |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy filter tags |
| string | The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ array, string ] | The consumption types. The possible values are "OnPremises" or "OffPremises." |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No". The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." The rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as true are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ array, string ] | An array of allowed Order Source identifiers |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The auto-assigned unique identifier (UID) of the entity, set on creation. All future versions of the entity share the same |
| boolean | |
| boolean | Marking property is the essence of active documents. Sets in |
| string | |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The last date and time (date-time) the document was updated |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
PATCH /tax-definition/document/<_id>
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
path |
| string | Yes | The identifier of the document |
query |
| boolean | No | Hydrates-related nested objects when returning a result (For example, populate a menu with menu categories and menu groups) |
query |
| [ csv of string ] | No | Specifies |
body |
|
| Yes | The JSON of the category being patched |
Request Body
Field Name | Type | Description |
|---|---|---|
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations to filter on |
| [ string, object ] | The list of destination entity identifiers to filter on |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string |
The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ string ] | The possible values are "OnPremises" or "OffPremises" |
| number | |
| number | |
| [ string, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ string ] | An array of allowed Order Source identifiers |
| string |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
| object | |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ string ] | The list of destinations to filter on |
| [ string, object ] | The list of destination entity identifiers to filter on |
| [ string, object ] | The list of item names or tax category names to filter on |
| [ array, string ] | The list of tender type names to filter on |
| [ array, string ] | The list of discount tags to filter on |
| object | Specifies the condition around items that satisfy the filter tags |
| string |
The scope of the conditions. The possible values are "order," "item," or "tender." The scope of the condition is the whole order if the |
| string | The possible values are "price" or "count." The total is the price of the items across the check if the |
| string | The condition sign ( ==, >, <, >=, <= ) |
| string | The target value for the condition |
| [ string ] | The possible values are "OnPremises" or "OffPremises" |
| number | |
| number | |
| [ string, object ] | |
| string | |
| number | |
| number | |
| number | |
| [ array, object ] | |
| string | |
| number | |
| number | |
| number | |
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." It is the rounding method to apply on each tax value. |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to calculate total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ string ] | An array of allowed Order Source identifiers |
| string |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
DELETE /tax-definition/document/<_id>
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
path |
| string | Yes | The identifier of the document |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
GET /tax-definition/mapping/entity/<entity_id>
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
header |
| [ csv of string ] | No | The unique identifiers (UIDs) of the site to manage data for |
path |
| string | Yes | The identifier of the entity |
query |
| int32 | No | The maximum documents to return |
query |
| int32 | No | The documents to skip before returning |
query |
| string | No | A filter expression in OData v4 format |
query |
| string | No | An order by expression in OData v4 format |
query |
| boolean | No | Includes the documents that inactive for the current sites |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| integer | |
| [ array, object ] | (object) |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The identifier of the site associated with the document |
| string | The auto-assigned UID of the entity, set on creation. All future versions of the entity share the same |
| string | The identifier of the document in the collection the mapping refers to |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The last date and time the document was updated |
| string | The last date and time the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
POST /tax-definition/mapping/entity/<entity_id>
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
header |
| [ csv of string ] | No | The unique identifiers (UIDs) of the site to manage data for |
path |
| string | Yes | The identifier of the entity |
body |
| Yes | The array of the tax definition mappings being added |
Request Body
[ array ] (unspecified type)
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| integer | |
| [ array, object ] | |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The identifier of the site associated with the document |
| string | The auto-assigned UID of the entity, set on creation. All future versions of the entity share the same |
| string | The identifier of the document in the collection the mapping refers to |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The last date and time (date-time) the document was created |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
POST /tax-definition/mapping
Request Parameters
In | Field Name | Type | Required | Description |
|---|---|---|---|---|
header |
| string | Yes | The identifier of the company to manage data for |
body |
|
| Yes | The JSON of the tax definition mapping being added |
Request Body
Field Name | Type | Description |
|---|---|---|
| string | The identifier of the document in the collection the mapping refers to |
| string | The auto-assigned unique identifier (UID) of the entity, set on creation. All future versions of the entity share the same |
| string | The date and time the document becomes "current" |
| [ string ] | The identifier of the site associated with the document |
Response: 200 OK
Schema
Field Name | Type | Description |
|---|---|---|
| integer | |
| [ array, object ] | |
| string | The auto-assigned system document identifier |
| string | The identifier of the company that owns the document |
| string | The identifier of the site associated with the document |
| string | The auto-assigned UID of the entity, set on creation. All future versions of the entity share the same |
| string | The identifier of the document in the collection the mapping refers to |
| string | The identifier of the OPRA user or site that created the document |
| string | The identifier of the OPRA user or site that last updated the document |
| string | The last date and time (date-time) the document was created |
| string | The last date and time (date-time) the document was updated |
Response Codes
Response | Description |
|---|---|
200 OK | Success |
400 Bad Request | Bad request, for more information look at body error |
403 Forbidden | Invalid token |
404 Not Found | Not found |
422 Unprocessable Entity | Unprocessable error |
Default | Unexpected error |
Data Models
tax_definition
Field Name | Type | Required | Description |
|---|---|---|---|
| string | Yes | The name of the tax (For example, NC sales tax) |
| string | Yes | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | Yes | The value is either a percentage or a fixed amount based on the type value |
| string | Yes | The possible values are "price" or "quantity" |
| boolean | Yes | If active: Hide the tax amounts both in the guest check and within the order entry |
| No |
| |
| boolean | No | If active, this tax is liable to the marketplace facilitator when ordered from a tax liable marketplace facilitator source |
| string | No | The main tax classes that are applied to the restaurant business. The possible values are "sales_tax," "meal_tax," or "bag_tax." |
| string, object | No | Describes the administrative level that imposes a specific tax. The jurisdiction names are shown within the list. |
| object | No |
|
| number (currency) | No |
|
| number (currency) | No |
|
|
| No |
|
|
| No |
|
| boolean | No | The flag that indicates if the tax rule is active or not |
| boolean | No | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply, with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | No | The rounding method to apply on each tax value. The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." |
| boolean | No | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to produce total tax |
| [ string, object ] | No | An array of allowed Order Source entity identifiers |
| [ string ] | No | An array of allowed Order Source identifiers |
| No |
| |
| No |
| |
| No |
| |
| No |
| |
| No |
| |
| No |
| |
| No |
| |
| No |
| |
| No |
|
tax_definition_create
Field Name | Type | Required | Description |
|---|---|---|---|
| string | Yes | The name of the tax (For example, NC sales tax) |
| string | Yes | Specifies the type of the tax rate. Possible values are "fixed_amount" or "fixed_rate." |
| number | Yes | The value is either a percentage or a fixed amount based on the type value |
| string | Yes | The possible values are "price" or "quantity" |
| boolean | Yes | If active: Hide the tax amounts both in the guest check and within the order entry |
| No |
| |
| boolean | No | If active, this tax is liable to the marketplace facilitator when ordered from a tax liable marketplace facilitator source |
| string | No | The main tax classes that are applied to the restaurant business. The possible values are "sales_tax," "meal_tax," or "bag_tax." |
| string, object | No | Describes the administrative level that imposes a specific tax. The jurisdiction names are shown within the list. |
| object | No |
|
| number (currency) | No |
|
| number (currency) | No |
|
|
| No |
|
|
| No |
|
| boolean | No | The flag that indicates if the tax rule is active or not |
| boolean | No | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply, with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | No | The rounding method to apply on each tax value. The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." |
| boolean | No | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to produce total tax |
| [ string, object ] | No | An array of allowed Order Source entity identifiers |
| [ string ] | No | An array of allowed Order Source identifiers |
| No |
|
tax_definition_edit
Field Name | Type | Description |
|---|---|---|
| string | The name of the tax (For example, NC sales tax) |
| string | Specifies the type of the tax rate. The possible values are "fixed_amount" or "fixed_rate." |
| number | The value is either a percentage or a fixed amount based on the type value |
| string | The possible values are "price" or "quantity" |
| boolean | If active: Hide the tax amounts both in the guest check and within the order entry |
|
| |
| boolean | If active, this tax is liable to the marketplace facilitator when ordered from a tax liable marketplace facilitator source |
| string | The main tax classes that are applied to the restaurant business. The possible values are "sales_tax," "meal_tax," or "bag_tax." |
| string, object | Describes the administrative level that imposes a specific tax. The jurisdiction names are shown within the list. |
| object |
|
| number (currency) |
|
| number (currency) |
|
|
|
|
|
|
|
| boolean | The flag that indicates if the tax rule is active or not |
| boolean | The possible values are "Yes" or "No." The default value is "No." If "Yes," the tax on tax is calculated after calculating all the regular taxes first, and then loop back and calculate the tax on tax on the total taxes. For example, on a single item $1.00 order where three 10% tax rates apply, with the second two having tax on tax value "Yes," tax1 would be $0.10, and tax2 and tax3 would be $0.13, which is 10% of $1.00 + 10% of (0.10+0.10+0.10). |
| string | The rounding method to apply on each tax value. The possible values are "roundup," "rounddown," or "nearest." The default value is "nearest." |
| boolean | The tax buckets which have this value as "True" are collectively rounded instead of individually rounded to produce total tax |
| [ string, object ] | An array of allowed Order Source entity identifiers |
| [ string ] | An array of allowed Order Source identifiers |
tax_definition_list
Field Name | Type | Description |
|---|---|---|
| integer |
|
|
|
name
Field Name | Type | Description |
|---|---|---|
| string |
external_id
Field Name | Type | Description |
|---|---|---|
| string |
_id
The auto-assigned system document identifier.
Field Name | Type | Description |
|---|---|---|
| string | The auto-assigned system document identifier |
company_id
The identifier of the company that owns the document.
Field Name | Type | Description |
|---|---|---|
| string | The identifier of the company that owns the document |
entity_id
The auto-assigned unique identifier (UID) of the entity, set on creation. All future versions of the entity share the same entity_id.
Field Name | Type | Description |
|---|---|---|
| string | The auto-assigned unique ID of this entity, set on creation. All future versions of this entity will share the same |
is_master
Field Name | Type | Description |
|---|---|---|
| boolean |
is_active
Marking property is the essence of active documents. Sets in true by default.
Field Name | Type | Description |
|---|---|---|
| boolean | Marking property is the essence of active documents. Sets in true by default. |
created_by
The identifier of the OPRA user or site that created the document.
Field Name | Type | Description |
|---|---|---|
| string | The identifier of the OPRA user or site that created the document |
updated_by
The identifier of the OPRA user or site that last updated the document.
Field Name | Type | Description |
|---|---|---|
| string | The identifier of the OPRA user or site that last updated the document |
created_at
The date and time the document was created.
Field Name | Type | Description |
|---|---|---|
| string | The date and time (date-time) the document was created |
updated_at
The last date and time the document was updated.
Field Name | Type | Description |
|---|---|---|
| string | The last date and time (date-time) the document was updated |