Actions11
- Address Actions
- Carrier Actions
- Custom Actions
- Shipment Actions
Custom → Classify HS Code
AI-generatedSummary
Classify a product description into a harmonized system (HS) code via the Envia API.
Inputs
- description (required) — Product description to classify
- hsCodeProvided — An existing HS code to verify or refine
- destinationCountries — Comma-separated ISO country codes
- includeAlternatives — Whether to include alternative HS code suggestions
- environment — Environment (production or test)
- allowUnauthorizedCerts — Whether to accept the response even if SSL certificate validation is not possible
- proxy — HTTP proxy to use. If authentication is required it can be defined as: http://username:password@myproxy:3128
- timeout — Time in ms to wait for the server to send response headers before aborting the request
- requestOptions — Request configuration options including batching controls
Output shape
The Envia API returns a classification result containing the suggested HS code, description, and, if includeAlternatives is true, alternative HS code suggestions.
Batching (batchSize / batchInterval) is controlled via requestOptions and will split input items accordingly.
Examples
Example 1: Classify a product with description, destination countries, and alternatives
Set description, destinationCountries to appropriate ISO codes, and includeAlternatives to true.