> ## Documentation Index
> Fetch the complete documentation index at: https://ekacare-consent-url-fix.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Generate OTP

> Generates an OTP for login. Supports login via Aadhaar number, mobile number, ABHA number, and ABHA address.



## OpenAPI

````yaml post /abdm/na/v1/profile/login/init
openapi: 3.1.0
info:
  description: ABHA Registration and login APIs
  title: Registration
  version: 1.0.0
servers:
  - description: Production
    url: https://api.eka.care
  - description: Stage/Sandbox
    url: https://api.dev.eka.care
security: []
paths:
  /abdm/na/v1/profile/login/init:
    post:
      summary: Generate OTP
      description: >-
        Generates an OTP for login. Supports login via Aadhaar number, mobile
        number, ABHA number, and ABHA address.
      parameters:
        - description: Eka User ID (OID)
          in: header
          name: X-Pt-Id
          schema:
            type: string
        - description: Partner User ID
          in: header
          name: X-Partner-Pt-Id
          schema:
            type: string
        - description: Partner HIP ID
          in: header
          name: X-Hip-Id
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PhrLoginOTPRequest'
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PhrLoginOTPResponse'
          description: OK
        4XX:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenericError'
          description: ''
        5XX:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenericError'
          description: ''
      security:
        - authApiKey: []
components:
  schemas:
    PhrLoginOTPRequest:
      properties:
        identifier:
          description: The identifier for the selected login method.
          examples:
            - '9876543210'
          type: string
        method:
          description: The method used for login.
          enum:
            - phr_address
            - abha_number
            - mobile
            - aadhaar_number
          examples:
            - mobile
          type: string
      type: object
    PhrLoginOTPResponse:
      properties:
        hint:
          type: string
        txn_id:
          description: Transaction ID for the next API call.
          type: string
      type: object
    GenericError:
      properties:
        code:
          type: integer
        error:
          type: string
        source_error:
          $ref: '#/components/schemas/SourceErr'
      type: object
    SourceErr:
      properties:
        code:
          type: string
        message:
          type: string
      type: object
  securitySchemes:
    authApiKey:
      description: The API requires a Bearer token (JWT) for authentication.
      scheme: bearer
      type: http

````