QuoteItemList_Load
#
Description#
This function loads a list of items from a Quote.
Request Parameters#
Parameter |
Type | Description |
---|---|---|
function |
String | For module level functions this parameter will always have the value Module |
module_code |
String | The module code will always have the value quote for this function |
module_function |
String | Specifies the function being executed, in this case QuoteItemList_Load |
quote_id edit_quote quote_code |
Number String String |
The id of the quote The code of the quote The code of the quote |
Response Parameters#
Parameter |
Type | Description |
---|---|---|
success |
Boolean | Boolean value indicating if the API request was successful |
quote_id |
Number | The id number of the loaded quote |
line_id |
Number | The line_id number of the item in the quote |
product_id |
Number | The product_id number of the item in the quote |
code |
String | The product_code of the item in the quote |
name |
String | The product name of the item in the quote |
sku |
String | The product sku number of the item in the quote |
price |
Number | The price of the item in the quote |
base_price |
Number | The base price of the item in the quote |
weight |
Number | The product weight of the item in the quote |
taxable |
Boolean | The taxable status of the item in the quote |
upsold |
Boolean | The upsold status of the item in the quote |
quantity |
Number | The quantity of the item in the quote |
options |
Object | Product Options |
total |
Number | The total price of the item in the quote |
options
Object#
Parameter |
Type | Description |
---|---|---|
quote_id |
Number | The id number of the loaded quote |
line_id |
Number | The line_id number of the item in the quote |
attr_id |
Number | Item Attribute ID |
attr_code |
String | Item Attribute Code |
attmpat_id |
Number | Attribute Template ID |
option_id |
Number | Product Option Code ID |
opt_code |
String | Product Option Code |
price |
Number | Product Attribute Price |
base_price |
Number | Product Attribute Base Price |
weight |
Number | Product Attribute Weight |
data |
String | Product Attribute Data Field |
data_long |
String | Product Attribute Data Long Field |
attr_prompt |
String | Attribute Selection Prompt |
opt_prompt |
String | Product Attribute Option Selection |
attribute |
String | Product Attribute Option Name |
value |
String | Attribute Option Value |
Example Request#
{
"Store_Code": "{{Store_Code}}",
"Miva_Request_Timestamp": "{{$timestamp}}",
"Function": "Module",
"Module_Code": "quote",
"Module_Function": "QuoteItemList_Load",
"Quote_ID": 1000
}
Example Response#
{
"success": 1,
"data": [
{
"quote_id": 1000,
"line_id": 5,
"product_id": 2,
"code": "bulk-01",
"name": "Bulk Rock Coffee",
"sku": "817715",
"price": 1247.5,
"base_price": 1247.5,
"weight": 100.0,
"taxable": true,
"upsold": false,
"quantity": 1,
"options": [
{
"quote_id": 1000,
"line_id": 5,
"attr_id": 1,
"attr_code": "roast",
"attmpat_id": 0,
"option_id": 9,
"opt_code": "green",
"price": 0.0,
"base_price": 0.0,
"weight": 0.0,
"data": "",
"data_long": "",
"attr_prompt": "roast level",
"opt_prompt": "green - raw",
"attribute": "roast",
"value": "green"
}
],
"total": 1247.5
},
{
"quote_id": 1000,
"line_id": 6,
"product_id": 1,
"code": "coffee01",
"name": "Colombian Rock - Organic",
"sku": "6120615",
"price": 24.95,
"base_price": 24.95,
"weight": 1.05,
"taxable": true,
"upsold": false,
"quantity": 1,
"options": [
{
"quote_id": 1000,
"line_id": 6,
"attr_id": 3,
"attr_code": "roast",
"attmpat_id": 0,
"option_id": 3,
"opt_code": "toasted",
"price": 0.0,
"base_price": 0.0,
"weight": 0.0,
"data": "",
"data_long": "",
"attr_prompt": "roast_level",
"opt_prompt": "toasted - medium",
"attribute": "roast",
"value": "toasted"
}
],
"total": 24.95
}
]
}
Error Responses#
Error Code | Error Message | Error Description |
---|---|---|
MER-UTL-QUOTES-00343 | Quote not found | Quote not found |
MER-UTL-QUOTES-00346 | Unable to load quote: One of Quote_ID, Edit_Quote, or Quote_Code must be specified | Unable to load quote |
MER-JSN-00023 | One or more parameters are invalid | Missing line_id(s) parameter |