Shipping to India

Ship to India: the PIN code every quote needs, and the paperwork some domestic parcels require.

India's six-digit PIN code works like a postal code anywhere, and the Rate API requires it, although the address form does not mark it required. Envia's own integrations also send items[] on domestic Indian parcels.

At a glance

Postal codeThe six-digit PIN, in postalCode: 400001. Required
StateA two-letter code, in state: MH, DL, KA
CityFree text: Mumbai
House numbernumber, required to create a label
Tax IDThe GSTIN, in identificationNumber. Optional
ItemsSend items[], even on domestic parcels
CurrencyQuote in INR. The label is charged in your account's currency
In sandboxBlue Dart runs the full cycle

What an address to India needs

The fields of an Indian address. Where the address form (GET /generic-form?country_code=IN&form=address_info) differs, the table says so:

FieldRequiredWhat goes in it
streetyesMG Road
cityyesMumbai — free text, no catalog
stateyesA two-letter code — MH, DL, KA. 37 of them, states and union territories
postalCodeyesThe six-digit PIN — 400001. Required by the API, although the form does not mark it
numberyes, for the labelBuilding or plot number
identificationNumbernoGSTIN, when the shipment is commercial
referencenoFree text for the carrier

Send the house number as number. The sandbox's address form calls it streetNumber; production and the API use number. Thirteen countries differ this way: see Address Rules by Country.

The states

API reference → Get states by country

curl https://queries.envia.com/state?country_code=IN

37 states and union territories, each with a unique two-letter code. Send the code, not the name.

Do not use GET /provinces/{state_code} for India. It searches every country at once: AN, Andaman and Nicobar, returns municipalities of Antioquia, Colombia. India's cities are free text and need no lookup.

All 37 states and union territories and their codes
CodeName
ANAndaman and Nicobar Islands
APAndhra Pradesh
ARArunachal Pradesh
ASAssam
BRBihar
CHChandigarh
CTChhattisgarh
DNDadra and Nagar Haveli
DDDaman and Diu
DLDelhi
GAGoa
GJGujarat
HRHaryana
HPHimachal Pradesh
JKJammu and Kashmir
JHJharkhand
KAKarnataka
KLKerala
LALadakh
LDLakshadweep
MPMadhya Pradesh
MHMaharashtra
MNManipur
MLMeghalaya
MZMizoram
NLNagaland
OROrissa
PYPuducherry
PBPunjab
RJRajasthan
SKSikkim
TNTamil Nadu
TGTelangana
TRTripura
UPUttar Pradesh
UTUttarakhand
WBWest Bengal

The list comes from GET /state?country_code=IN.

A complete address

{
  "name": "Priya Sharma",
  "email": "[email protected]",
  "phone": "+91 00000 00000",
  "street": "MG Road",
  "number": "42",
  "city": "Mumbai",
  "state": "MH",
  "postalCode": "400001",
  "country": "IN"
}

Whether a domestic parcel needs items[]

To know whether a route needs items[] and customs paperwork, ask; do not compare the two countries:

{ "origin":      { "country_code": "IN", "state_code": "MH", "postal_code": "400001" },
  "destination": { "country_code": "IN", "state_code": "DL", "postal_code": "110001" } }

POST https://geocodes.envia.com/location-requirements answers:

{ "applyTaxes": true, "includeBOL": false, "isInternalEU": false,
  "isInternalGB": false, "isInternalUK": false }

applyTaxes: true means domestic for tax purposes. It is the answer for every route inside India.

Send items[] anyway. Envia's own integrations send it on every domestic Indian or Brazilian shipment. Not every carrier enforces it, but one that does refuses the label without it, and it costs a few fields.

Ship it, end to end

One shipment from start to finish: New Delhi → Mumbai, with Blue Dart. Every request runs as written in sandbox, with the address above as the destination; only the tracking number is a placeholder.

Find the carriers that serve the lane

API reference → Get Carriers With Services

curl https://queries.test.envia.com/available-carrier/IN/0/1 \
  --header "Authorization: Bearer $ENVIA_TOKEN"

IN/0/1 reads: from India, domestic (0), parcel (1). Each carrier comes with the services you can pass when you create the label.

Quote

API reference → Get Shipping Rates

curl --request POST \
  --url https://api-test.envia.com/ship/rate/ \
  --header "Authorization: Bearer $ENVIA_TOKEN" \
  --header "Content-Type: application/json" \
  --data '{
    "origin": {
      "name": "Delhi Warehouse",
      "company": "Demo Store",
      "email": "[email protected]",
      "phone": "+91 11 0000 0000",
      "street": "Connaught Place, Block A",
      "number": "12",
      "city": "New Delhi",
      "state": "DL",
      "postalCode": "110001",
      "country": "IN"
    },
    "destination": {
      "name": "Priya Sharma",
      "email": "[email protected]",
      "phone": "+91 00000 00000",
      "street": "MG Road",
      "number": "42",
      "city": "Mumbai",
      "state": "MH",
      "postalCode": "400001",
      "country": "IN"
    },
    "packages": [
      {
        "content": "Ropa",
        "amount": 1,
        "type": "box",
        "weight": 1,
        "insurance": 0,
        "declaredValue": 0,
        "weightUnit": "KG",
        "lengthUnit": "CM",
        "dimensions": {
          "length": 20,
          "width": 20,
          "height": 10
        }
      }
    ],
    "shipment": {
      "carrier": "blueDart",
      "type": 1
    },
    "settings": {
      "currency": "INR"
    }
  }'

shipment.carrier takes one carrier per request; call it once per carrier to compare. Prices come back in settings.currency.

{
  "meta": "rate",
  "data": [
    {
      "carrier": "blueDart",
      "service": "dart_plus",
      "serviceDescription": "BlueDart Dart Plus",
      "deliveryEstimate": "4-6 días",
      "totalPrice": 158.02,
      "currency": "INR"
    }
  ]
}

deliveryEstimate is text for a person, in Spanish as the carrier sends it. Show it as is.

Create the label

API reference → Generate a Shipping Label

curl --request POST \
  --url https://api-test.envia.com/ship/generate/ \
  --header "Authorization: Bearer $ENVIA_TOKEN" \
  --header "Content-Type: application/json" \
  --data '{
    "origin": {
      "name": "Delhi Warehouse",
      "company": "Demo Store",
      "email": "[email protected]",
      "phone": "+91 11 0000 0000",
      "street": "Connaught Place, Block A",
      "number": "12",
      "city": "New Delhi",
      "state": "DL",
      "postalCode": "110001",
      "country": "IN"
    },
    "destination": {
      "name": "Priya Sharma",
      "email": "[email protected]",
      "phone": "+91 00000 00000",
      "street": "MG Road",
      "number": "42",
      "city": "Mumbai",
      "state": "MH",
      "postalCode": "400001",
      "country": "IN"
    },
    "packages": [
      {
        "content": "Ropa",
        "amount": 1,
        "type": "box",
        "weight": 1,
        "insurance": 0,
        "declaredValue": 0,
        "weightUnit": "KG",
        "lengthUnit": "CM",
        "dimensions": {
          "length": 20,
          "width": 20,
          "height": 10
        }
      }
    ],
    "shipment": {
      "carrier": "blueDart",
      "service": "dart_plus",
      "type": 1
    },
    "settings": {
      "currency": "INR",
      "printFormat": "PDF",
      "printSize": "STOCK_4X6"
    }
  }'
{
  "meta": "generate",
  "data": [
    {
      "carrier": "blueDart",
      "service": "dart_plus",
      "trackingNumber": "7000000001",
      "trackUrl": "https://envia.com/rastreo?label=7000000001&cntry_code=in",
      "label": "https://…/blueDart/7000000001.pdf",
      "totalPrice": 47.46,
      "currency": "MXN"
    }
  ]
}

The label is charged in your account's currency. The quote above is INR 158.02; a Mexican account is charged MXN 47.46.

Track it

API reference → Track Shipments

curl --request POST \
  --url https://api-test.envia.com/ship/generaltrack/ \
  --header "Authorization: Bearer $ENVIA_TOKEN" \
  --header "Content-Type: application/json" \
  --data '{
    "trackingNumbers": [
      "7000000001"
    ]
  }'

A label you just created answers "status": "Created". For anything at volume, subscribe to webhooks instead of polling.

Cancel it, if it does not ship

API reference → Cancel a Shipment

curl --request POST \
  --url https://api-test.envia.com/ship/cancel/ \
  --header "Authorization: Bearer $ENVIA_TOKEN" \
  --header "Content-Type: application/json" \
  --data '{
    "carrier": "blueDart",
    "trackingNumber": "7000000001"
  }'

The response includes refundedAmount and balanceReturned: the charge returns to your balance.

When a delivery fails: NDR

India is the only market with a dedicated non-delivery workflow in the API. A parcel the carrier could not deliver goes into NDR, is held, and after a number of failed attempts is returned at your cost.

It is time-critical, so it has its own operations: see NDR (India) to list what is waiting, send the action — reattempt, change address, return — and read what was already tried.

International, into and out of India

A shipment that crosses the Indian border is an ordinary international shipment: see International Shipping & Customs. The GSTIN in identificationNumber stays optional, unlike Brazil, where the tax ID is required.

Testing in sandbox

Which Indian carriers work in sandbox
  • Blue Dart runs the full cycle, and issues a domestic label without items[].
  • Delhivery and Ekart quote.
  • Shadowfax quotes in MXN when you ask for INR.
  • XpressBees answers with an internal error.
  • Amazon is not configured on the test account: 1126 Client authentication failed.
  • trackUrl opens a tracking page that does not know sandbox shipments. It works for labels created in production.

In production you use the carriers enabled on your account.

Next steps


Did this page help you?