Hi Hariharan!
You can use external API services for reading text from the image or use the government's services to read from QR code on the KYC.
Example:
For India's Aadhar Card: https://uidai.gov.in/en/ecosystem/authentication-devices-documents/qr-code-reader.html
For generic image to text API: https://www.imagetotext.info (You can browse their plans at https://www.imagetotext.info/api-plans)