Quotation APIs
This API allows you to make an HTTP request to get a quotation for a list of items.
Get a quotation
- URL:
/v1/reseller/quotation
- Method:
GET
- Header:
Authorization
. To make a valid request you need to be authenticated using access token. For more info see authentication - URL params:
- items: an array of items to get a quotation for. Every item must have the following fields:
- article: the box type, e.g. s020_v1. For more info see articles
- material: the type of material used to print the box, e.g. SBS300. For more info see materials
- width: the width of the box, e.g. 65, in millimeters. The width must be a numeric value with max precision set to two decimal places
- depth: the depth of the box, e.g. 65, in millimeters. The depth must be a numeric value with max precision set to two decimal places
- height: the height of the box, e.g. 75, in millimeters. The height must be a numeric value with max precision set to two decimal places
- references: an array of reference objects. At the moment only one object is allowed. Every reference object must have the following fields:
- quantity: the number of boxes to print. The quantity must be a positive integer number
- printing: CMYK printing. The printing field must be a boolean value
- gold: gold finishing. The gold field must be a boolean value
- silver: silver finishing. The silver field must be a boolean value
- varnish: varnish finishing. The varnish field must be a boolean value
- manufacturing_time: a string indicating the manufacturing time speed
- shipping(optional): a two character ISO code representing the shipping country. Default: IT
- items: an array of items to get a quotation for. Every item must have the following fields:
- Data params: none
- Response: the response will be provided with content type application/json and will contain the following fields:
- request: an object that contains all data you used on your HTTP request and it will contain the following fields:
- uri: the URI you used to make the HTTP request
- method: the HTTP method, e.g. GET
- query: an object containing all the parameters and the related values you used to make the HTTP request
- response: an object that contains a quote for all the items passed:
- total_amount_tax_excluded: the total amount tax excluded obtained by the sum of the total_amount_tax_excluded of production, shipping and conai objects in EUR
- total_amount_tax_included: the total amount tax included obtained by the sum of the total_amount_tax_included of production, shipping and conai objects in EUR
- tax_amount: the tax amount
- production: an object containing the amounts of the production costs:
- total_amount_tax_excluded: the total amount tax excluded obtained by the sum of the total_amount_tax_excluded of the production object in each item in EUR
- total_amount_tax_included: the total amount tax included obtained by the sum of the total_amount_tax_included of the production object in each item in EUR
- shipping: an object containing the amounts of the shipping costs:
- total_amount_tax_excluded: the total amount tax excluded obtained by the sum of the total_amount_tax_excluded of the shipping object in each item in EUR
- total_amount_tax_included: the total amount tax included obtained by the sum of the total_amount_tax_included of the shipping object in each item
- conai: an object containing the amounts of the CONAI costs:
- total_amount_tax_excluded: the total amount tax excluded obtained by the sum of the total_amount_tax_excluded of the conai object in each item in EUR
- total_amount_tax_included: the total amount tax included obtained by the sum of the total_amount_tax_included of the conai object in each item in EUR
- items: an array of objects where each object contains the details of a quoted items:
- total_amount_tax_excluded: the total amount tax excluded of the current item obtained by the sum of the total_amount_tax_excluded of the object production, shipping and conai in EUR
- total_amount_tax_included: the total amount tax included of the current item obtained by the sum of the total_amount_tax_included of the object production, shipping and conai in EUR
- production: an object containing the details of the production costs:
- total_amount_tax_excluded: the total amount tax excluded of the production costs obtained by the sum of the total_amount_tax_excluded in each production's item object in EUR
- total_amount_tax_included: the total amount tax included of the production costs obtained by the sum of the total_amount_tax_included in each production's item object in EUR
- items: an array of objects where each object contains the details of a quoted reference:
- total_amount_tax_excluded: the total amount tax excluded of the single reference in EUR
- total_amount_tax_included: the total amount tax included of the single reference in EUR
- details: the reference details that produced the current reference's quotation
- quantity: the number of boxes of the current reference
- shipping: an object containing the details of the shipping costs:
- total_amount_tax_excluded: the total amount tax excluded of the shipping costs in EUR
- total_amount_tax_included: the total amount tax included of the shipping costs in EUR
- conai: an object containing the details of the CONAI costs:
- total_amount_tax_excluded: the total amount tax excluded of the CONAI costs in EUR
- total_amount_tax_included: the total amount tax included of the CONAI costs in EUR
- details: the item details that produced the current item's quotation
- article: the box code
- width: the width of the box
- depth: the depth of the box
- height: the height of the box
- material: the material code
- references: an array of objects where each object is a reference made by the following fields:
- quantity: the number of boxes of the reference
- printing: CMYK printing
- gold: gold finishing
- silver: silver finishing
- varnish: varnish finishing
- manufacturing_time: a string indicating the manufacturing time speed
- details: the global details that produced the current quotation
- shipping: the ISO code of the shipping country
- request: an object that contains all data you used on your HTTP request and it will contain the following fields:
Errors
The errors raised by this endpoint can be of the following types:
- VALIDATION_ERROR
- QTT_1100: items is required
- QTT_1101: article must be a valid article code
- QTT_1102: material must be a valid material code
- QTT_1103: width is required and must be a positive number with no more than two decimal places
- QTT_1104: depth is required and must be a positive number with no more than two decimal places
- QTT_1105: height is required and must be a positive number with no more than two decimal places
- QTT_1106: references is required
- QTT_1107: quantity is required and must be a integer positive number
- QTT_1108: printing must be a boolean value
- QTT_1109: gold must be a boolean value or its value it's not allowed in this configuration
- QTT_1110: silver must be a boolean value or its value it's not allowed in this configuration
- QTT_1111: varnish must be a boolean value or its value it's not allowed in this configuration
- QTT_1112: manufacturing_time must be a valid manufacturing_time code
- QTT_1113: shipping must be a valid iso code
- QUANTITY_ERROR
- QTT_1114: the number of sheets doesn't reach the minimum required quantity
- BOX_ERROR
- for this type of errors, please refer to the errors page
- INTERNAL_SERVER_ERROR
- for this type of errors, please refer to the errors page
- NOT_FOUND
- for this type of errors, please refer to the errors page
Examples
Request
GET /v1/reseller/quotation HTTP/1.1
Authorization: Bearer eHZ6MWV2R ... o4OERSZHlPZw==
Content-Type: application/x-www-form-urlencoded;charset=UTF-8
items=[{"article":"s001_v0","material":"FBB285","width":70.66,"depth":80.77,"height":120,"references":[{"quantity":3000}],"printing":false,"gold":false,"silver":false,"varnish":false,"manufacturing_time":"standard"},{"article":"s001_v1","material":"SBS300","width":70.66,"depth":80.77,"height":120,"references":[{"quantity":100}],"printing":true,"gold":false,"silver":true,"varnish":false,"manufacturing_time":"express"},{"article":"s007_v0","material":"SBS400","width":170.66,"depth":80.77,"height":120,"references":[{"quantity":666}],"printing":true,"gold":false,"silver":false,"varnish":false,"manufacturing_time":"express"}]
shipping=FR
Response
HTTP status code: 200
{
"request": {
"uri": "/v1/reseller/quotation",
"method": "GET",
"query": {
"items": "[{ \"article\": \"s001_v0\", \"material\": \"FBB285\", \"width\": 70.66, \"depth\": 80.77, \"height\": 120, \"references\": [ { \"quantity\": 3000 } ], \"printing\": false, \"gold\": false, \"silver\": false, \"varnish\": false, \"manufacturing_time\": \"standard\" }, { \"article\": \"s001_v1\", \"material\": \"SBS300\", \"width\": 70.66, \"depth\": 80.77, \"height\": 120, \"references\": [ { \"quantity\": 100 } ], \"printing\": true, \"gold\": false, \"silver\": true, \"varnish\": false, \"manufacturing_time\": \"express\" }, { \"article\": \"s007_v0\", \"material\": \"SBS400\", \"width\": 170.66, \"depth\": 80.77, \"height\": 120, \"references\": [ { \"quantity\": 666 } ], \"printing\": true, \"gold\": false, \"silver\": false, \"varnish\": false, \"manufacturing_time\": \"express\" }]",
"shipping": "FR"
}
},
"response": {
"total_amount_tax_excluded": 2247.38,
"total_amount_tax_included": 2741.8,
"tax_amount": 494.42,
"production": {
"total_amount_tax_excluded": 2247,
"total_amount_tax_included": 2741.34
},
"shipping": {
"total_amount_tax_excluded": 0,
"total_amount_tax_included": 0
},
"conai": {
"total_amount_tax_excluded": 0.38,
"total_amount_tax_included": 0.4636
},
"items": [
{
"total_amount_tax_excluded": 752.65,
"total_amount_tax_included": 918.23,
"production": {
"total_amount_tax_excluded": 752.4,
"total_amount_tax_included": 917.93,
"items": [
{
"total_amount_tax_excluded": 752.4,
"total_amount_tax_included": 917.93,
"details": {
"quantity": 3000
}
}
]
},
"shipping": {
"total_amount_tax_excluded": 0,
"total_amount_tax_included": 0
},
"conai": {
"total_amount_tax_excluded": 0.25,
"total_amount_tax_included": 0.305
},
"details": {
"article": "s001_v0",
"width": 70.66,
"depth": 80.77,
"height": 120,
"material": "FBB285",
"references": [
{
"quantity": 3000
}
],
"printing": false,
"gold": false,
"silver": false,
"varnish": false
}
},
{
"total_amount_tax_excluded": 364.21,
"total_amount_tax_included": 444.33,
"production": {
"total_amount_tax_excluded": 364.2,
"total_amount_tax_included": 444.32,
"items": [
{
"total_amount_tax_excluded": 364.2,
"total_amount_tax_included": 444.32,
"details": {
"quantity": 100
}
}
]
},
"shipping": {
"total_amount_tax_excluded": 0,
"total_amount_tax_included": 0
},
"conai": {
"total_amount_tax_excluded": 0.01,
"total_amount_tax_included": 0.0122
},
"details": {
"article": "s001_v1",
"width": 70.66,
"depth": 80.77,
"height": 120,
"material": "SBS300",
"references": [
{
"quantity": 100
}
],
"printing": true,
"gold": false,
"silver": true,
"varnish": false
}
},
{
"total_amount_tax_excluded": 1130.52,
"total_amount_tax_included": 1379.24,
"production": {
"total_amount_tax_excluded": 1130.4,
"total_amount_tax_included": 1379.09,
"items": [
{
"total_amount_tax_excluded": 1130.4,
"total_amount_tax_included": 1379.09,
"details": {
"quantity": 666
}
}
]
},
"shipping": {
"total_amount_tax_excluded": 0,
"total_amount_tax_included": 0
},
"conai": {
"total_amount_tax_excluded": 0.12,
"total_amount_tax_included": 0.1464
},
"details": {
"article": "s007_v0",
"width": 170.66,
"depth": 80.77,
"height": 120,
"material": "SBS400",
"references": [
{
"quantity": 666
}
],
"printing": true,
"gold": false,
"silver": false,
"varnish": false
}
}
],
"details": {
"shipping": "FR"
}
}
}