SalesTaxes (USA)
Using Product's HSCode
Infos to get the USA Sales Taxes
Headers
Name
Type
Description
{
"hscode_description": "Hats and other headgear, knitted or crocheted, or made up from lace, felt or other textile fabric, in the piece (but not in strips), whether or not lined or trimmed; hairnets of any material, whether or not lined or trimmed",
"import_statut": "Authorized for importation into this country",
"threshold_tax": "22",
"threshold_tax_currency": "EUR",
"annual_revenue_union_locals_taxes_minimis": 0,
"other_taxes": []
}1. Incorrect Json (json body request incorrect
a)
@ValidateIf(o => o.sku === undefined && o.product_text === undefined)
@IsNotEmpty()
hs_code: string;
@ValidateIf(o => o.hs_code === undefined && o.product_text === undefined)
@IsNotEmpty()
sku: string;
@ValidateIf(o => o.sku === undefined && o.hs_code === undefined)
@IsNotEmpty()
product_text: string;
@IsNotEmpty()
@Length(3, 3, {message: "from_country should be ISO3"})
from_country: string;
@IsNotEmpty()
@Length(3, 3, {message: "to_country should be ISO3"})
to_country: string;
to_district: string;
b) Error Response Example:
{
"code": "INCORRECT_JSON",
"name": "ClientError",
"message": "Incorrect Json Request",
"details": [
{
"parameter": {
"name": "hs_code / product_text / sku"
},
"causes": [
"hs_code or product_text or sku must be filled"
]
}
]
}
Json Request Format
{
“sku”: string,
“hs_code”: string,
“from_country”: string,
“to_country”: string,
“to_district”: string
}Request fields & values
"sku"
"hs_code"
"from_country"
"to_country"
"to_district"
Json Response Format
Result fields & values
"hscode_description"
"import_statut"
"threshold_tax"
"threshold_tax_currency"
"locals_taxes" / "label"
"locals_taxes" / "percentage"
JSON Examples - Request & Response
Video explainer
Last updated