Managed and Premium Tariff Code Classification

Version v2
Classifications
CreateHSClassificationRequest
GetHSClassification
HSCodeValidationRequest
HSCodeVerificationRequest
WebhookCallback

AvaTaxError

AvaTax-style error envelope { "error": { "code", "target", "details"[] } }.

Returned for:

  • Gateway / OAuth failures (401) before the controller runs.
  • POST /{companyId}/classifications HTTP-level failures: 402, 413, 422, 503, 500 (and downstream AvaTaxException bodies when mapped by the controller).
  • GET .../classifications/{id} 404, 422, 500 (mirrors legacy V1).

Nested per-item / per-COD errors inside a 207 ClassificationResponse still use the flat Error schema on the embedded error fields.

Use error.code plus error.details[].number to branch programmatically. Common numbers include 31 / 34 / 37 (auth), 5 (ValueRequiredError), 50 (UnhandledException), 70 (ModelStateInvalid), 3011 (MtccPlusNotProvisioned), 3015 (EntitlementRequired), 3016 (PayloadTooLarge), 3008 (RetryRequest), and values from ClassificationError.

This model is used in the following APIs:

Parameters
errorRequired
object