Skip to content

GST Validation API

The GST Validation API allows organizations to verify Indian GST Identification Numbers (GSTIN) against government records. It returns the taxpayer's legal name, trade name, registration status, address, and latest filing information.

Authentication

All GST endpoints require a valid PASETO token and membership in the target organization.

Endpoints

POST /api/gst/:orgId/check

Validate a GSTIN by passing it in the request body.

Path Parameters

ParamTypeDescription
orgIdstringOrganization ID

Request Body

FieldTypeRequiredDescription
gstinstringYes15-character GSTIN to validate

Example Request

bash
curl -X POST /api/gst/org_abc123/check \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{ "gstin": "27AAPFU0939F1ZV" }'

Response 200 OK

json
{
  "success": true,
  "data": {
    "gstin": "27AAPFU0939F1ZV",
    "legalName": "SUNRISE HOSPITALITY PVT LTD",
    "tradeName": "Hotel Sunrise",
    "status": "Active",
    "registrationDate": "2018-07-01",
    "taxpayerType": "Regular",
    "address": {
      "building": "Plot 42, Tower B",
      "street": "MG Road",
      "city": "Mumbai",
      "state": "Maharashtra",
      "pincode": "400001"
    },
    "lastFilingDate": "2026-01-10",
    "lastFilingType": "GSTR-3B"
  }
}

GET /api/gst/:orgId/:gstId/check

Validate a GSTIN using a path-based lookup. Useful for quick verification without a request body.

Path Parameters

ParamTypeDescription
orgIdstringOrganization ID
gstIdstring15-character GSTIN to validate

Example Request

bash
curl -X GET /api/gst/org_abc123/27AAPFU0939F1ZV/check \
  -H "Authorization: Bearer <token>"

Response 200 OK

Same response structure as the POST endpoint above.


GSTIN Format

A valid GSTIN is a 15-character alphanumeric string:

27 AAPFU0939F 1 Z V
│  │           │ │ └─ Checksum digit
│  │           │ └─── Default "Z"
│  │           └───── Entity number (1–9, A–Z)
│  └───────────────── PAN (10 characters)
└──────────────────── State code (01–37)
PositionLengthDescription
1–22State code
3–1210PAN of the taxpayer
131Entity number within a state
141Default — "Z"
151Check digit

Response Fields

FieldTypeDescription
gstinstringThe validated GSTIN
legalNamestringLegal (registered) name of the business
tradeNamestringTrade / brand name
statusstringRegistration status: Active, Cancelled, Suspended
registrationDatestringDate of GST registration (YYYY-MM-DD)
taxpayerTypestringRegular, Composition, SEZ, etc.
addressobjectRegistered address of the taxpayer
lastFilingDatestringDate of the most recent GST return filing
lastFilingTypestringType of the last return filed (e.g. GSTR-3B)

Error Responses

StatusConditionExample Message
400Missing or malformed GSTIN"Invalid GSTIN format"
401Unauthorized — missing or invalid token"Authentication required"
403User not a member of the organization"Forbidden"
404GSTIN not found in government records"GSTIN not found"
502Upstream GST API failure"GST verification service unavailable"
json
{
  "success": false,
  "message": "Invalid GSTIN format"
}

Usage Notes

  • Results may be cached for up to 24 hours to reduce upstream API calls.
  • The GST verification service depends on an external government API; occasional timeouts are expected during peak hours.
  • Both endpoints return identical response structures — choose the one that fits your client's UX pattern.

Released under the MIT License.