> ## Documentation Index
> Fetch the complete documentation index at: https://developer.sandbox.co.in/llms.txt
> Use this file to discover all available pages before exploring further.

# E-Way Bill Authentication

> E-Way Bill Authentication

#### Request body schema

<Card title="View request body schema" icon="code" href="https://raw.githubusercontent.com/in-co-sandbox/in-co-sandbox-docs/refs/heads/main/data/gst/schema/request/e-way-bill/authenticate.json" arrow="true" horizontal />

<Warning>
  **Prerequisites:** You must have API credentials to hit E-Way Bill APIs. If not, [create API credentials](/api-reference/gst/compliance/guides/e-way-bill/authentication/create_api_credentials).
</Warning>


## OpenAPI

````yaml api-reference/gst/compliance/openapi.json POST /gst/compliance/e-way-bill/tax-payer/authenticate
openapi: 3.0.1
info:
  title: compliance
  description: >-
    **GST Compliance API** enables businesses to automate compliance
    requirements like [Taxpayer
    verification](https://developer.sandbox.co.in/reference/search-gstin-api),
    [GSTR
    Filing](https://developer.sandbox.co.in/reference/gst-taxpayer-authentication),
    [Generating
    E-Invoices](https://developer.sandbox.co.in/reference/e-invoice-authentication-api),
    and [E-Way
    Bills](https://developer.sandbox.co.in/reference/e-way-bill-authentication-api).We
    provide these APIs from GSTN-authorised GST Suvidha Providers, handling the
    encryption-decryption and signing so you don't have to handle the
    complexities.
  version: 1.0.0
servers:
  - url: https://api.sandbox.co.in
  - url: https://test-api.sandbox.co.in
security: []
tags:
  - name: Public
  - name: Taxpayer
  - name: Taxpayer Auth
  - name: Returns
  - name: GSTR-1 Documents
  - name: File GSTR-1
  - name: GSTR-2A Documents
  - name: GSTR-2B Document
  - name: File GSTR-3B
  - name: GSTR-4
  - name: File GSTR-9
  - name: Invoice Management System
  - name: GSTR-1A Documents
  - name: File GSTR-1A
  - name: Ledgers
  - name: e-Invoice
  - name: Sales e-Invoices for return period
  - name: Purchase e-Invoices for return period
  - name: Front Office Notices
  - name: Front Office
  - name: AATO
  - name: e-Invoice1
  - name: Authentication
  - name: e-Invoice12
  - name: E-Way Bill
  - name: E-Way Bill1
  - name: Authentication1
  - name: Consignor
  - name: Consolidated E-Way Bill
  - name: Multi-Vehicle Movement
  - name: Consignee
  - name: Transporter
  - name: Consolidated E-Way Bill1
  - name: Multi-vehicle Movement
  - name: Common
paths:
  /gst/compliance/e-way-bill/tax-payer/authenticate:
    post:
      tags:
        - E-Way Bill1
        - Authentication1
      summary: E-Way Bill Authentication
      operationId: eWayBillAuthenticate
      parameters:
        - name: authorization
          in: header
          description: JWT access token
          required: true
          example: ''
          schema:
            type: string
        - name: x-source
          in: header
          description: 'Source. Possible Values: primary, secondary or tertiary'
          required: false
          example: ''
          schema:
            type: string
            default: primary
            example: primary
        - name: x-api-key
          in: header
          description: API key for identification
          required: true
          example: ''
          schema:
            type: string
        - name: x-api-version
          in: header
          description: API version
          required: false
          example: ''
          schema:
            type: string
            default: 1.0.0
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EWayBillAuthenticateRequest'
            examples:
              200 Authenticated:
                value:
                  username: ACME_IND_API_QCK
                  password: QnVzaW5lc3NfQVBJX1FDSw
                  gstin: 29AAACQ3770E000
                summary: 200 Authenticated
              108 Invalid login credentials:
                value:
                  username: ACME_IND_API_QCK
                  password: qnvzaW5lc3NfQV
                  gstin: 29AAACQ3770E000
                summary: 108 Invalid login credentials
      responses:
        '200':
          description: 200 Authenticated / 108 Invalid login credentials
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EWayBillAuthenticateResponse'
              examples:
                200 Authenticated:
                  summary: 200 Authenticated
                  value:
                    code: 200
                    data:
                      Status: 1
                      access_token: >-
                        eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJ0YXhwYXllci1zZXNzaW9uIiwiZ3N0aW4iOiIyNEFCS0NTMjAzM0IxWlYiLCJpYXQiOjE3MTI5NDQxMDAsImV4cCI6MTcxMjk0NzcxMX0.sandbox-signature
                      expiry: 1714157100000
                    timestamp: 1763446641000
                    transaction_id: 2ab9923e-f844-4b6c-8fc7-0bcc767bafc7
                108 Invalid login credentials:
                  summary: 108 Invalid login credentials
                  value:
                    code: 200
                    data:
                      error:
                        errorCodes: '108'
                      info: ''
                      status: '0'
                    timestamp: 1763446641000
                    transaction_id: ca515f62-749d-4037-b4cc-adca5db77cd7
          headers: {}
      deprecated: false
      security: []
components:
  schemas:
    EWayBillAuthenticateRequest:
      type: object
      required:
        - username
        - password
        - gstin
      properties:
        username:
          type: string
          description: API username of taxpayer as set on E-Way Bill portal
        password:
          type: string
          description: API password of taxpayer as set on E-Way Bill portal
        gstin:
          type: string
          description: GSTIN of the taxpayer
      description: E-Way Bill schema.
    EWayBillAuthenticateResponse:
      oneOf:
        - $ref: '#/components/schemas/EWayBillAuthenticateSuccessResponse'
        - $ref: '#/components/schemas/EWayBillBusinessErrorResponse'
      description: >-
        An E-Way Bill success or NIC business-failure response. Both variants
        use HTTP 200.
    EWayBillAuthenticateSuccessResponse:
      allOf:
        - $ref: '#/components/schemas/EWayBillResponseMetadata'
        - type: object
          required:
            - data
          properties:
            data:
              $ref: '#/components/schemas/EWayBillAuthenticateSuccessPayload'
    EWayBillBusinessErrorResponse:
      allOf:
        - $ref: '#/components/schemas/EWayBillResponseMetadata'
        - type: object
          required:
            - data
          properties:
            data:
              type: object
              required:
                - status
                - error
              properties:
                status:
                  type: string
                  enum:
                    - '0'
                  description: NIC business-failure status.
                error:
                  $ref: '#/components/schemas/EWayBillBusinessError'
    EWayBillResponseMetadata:
      type: object
      description: Metadata returned with every E-Way Bill response.
      required:
        - code
        - timestamp
        - transaction_id
      properties:
        code:
          type: integer
          enum:
            - 200
          description: NIC response code.
        timestamp:
          type: integer
          format: int64
          description: Unix timestamp.
        transaction_id:
          type: string
          description: Request transaction identifier.
    EWayBillAuthenticateSuccessPayload:
      type: object
      properties:
        Status:
          type: integer
          example: 1
          description: NIC authentication success status.
          enum:
            - 1
        access_token:
          type: string
          example: >-
            eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJ0YXhwYXllci1zZXNzaW9uIiwiZ3N0aW4iOiIyNEFCS0NTMjAzM0IxWlYiLCJpYXQiOjE3MTI5NDQxMDAsImV4cCI6MTcxMjk0NzcxMX0.sandbox-signature
          description: The access_token value.
        error:
          type: object
          properties:
            errorCodes:
              type: string
              example: '108'
              description: The errorCodes value.
          description: The error value.
        expiry:
          type: number
          example: 1714157100000
          description: The expiry value.
        info:
          type: string
          example: ''
          description: The info value.
        status:
          type: string
          example: '0'
          description: The status value.
      description: E-Way Bill schema.
      required:
        - Status
    EWayBillBusinessError:
      type: object
      description: NIC business-error details.
      required:
        - errorCodes
      properties:
        errorCodes:
          type: string
          description: NIC error code.

````