e-Invoice Authentication
e-Invoice Authentication API takes API credentials set on the e-Invoice portal (NIC) and gives the e-Invoice access token in response. If you have not created API credentials, follow the steps here to create them.
NIC validations
View NIC validations
View NIC validations
- Only taxpayer GSTINs enabled for e-invoicing are allowed for authentication.
Request body schema
View request body schema
access_token works with both e-Invoice and E-Way Bill APIs until it expires.x-source and x-proxy.Authorizations
Sandbox access token returned by /authenticate.
Sandbox API key from your Sandbox account.
Headers
NIC server for authentication. primary selects NIC1. secondary selects NIC2. Defaults to primary. See NIC1 and NIC2 routing.
primary, secondary "primary"
API version
NIC server that receives the request. If omitted, the request goes to the server selected by x-source. When specified, selects the other server. See NIC1 and NIC2 routing.
primary, secondary Query Parameters
The value of this attribute is to be set true if the client needs to refresh the token 10 minutes before expiry. Possible Values - true or false
"true"
Body
Response
1015 Invalid GSTIN for user / 200 Authenticated / 1019 Incorrect password / 1017 Incorrect user id / GEN5008 GSTN Server Error
- Successful e-Invoice authentication response
- NIC e-Invoice business error
- GSTN server error
Authentication success, NIC business error, or platform error. These variants use HTTP 200.