This is a Spring boot application which can be used to generate OTP on the registered mobile number corresponding to the Staging UID.
- Java 8 (Required)
- Maven 3.6.1
- In application.properties
signatureFile
- Change the path of 'PublicAUAforStagingServices.p12' file according to your local repository folder location.
- Flow starts from
OtpAPIClientMain.java
which takes Staging UID as input in commandline. - A random String (transaction Id) is also generated. You can use any transaction Id.
- Please provide your staging uid as command line args
- The application will then create the signed OTP Request xml and makes call to OTP Request API.
- OTP Response xml (with same transaction Id as in request) will be parsed and result, error (if any) will get printed.
- For a successful response, you will get an OTP on phone linked with staging UID.
If you have any doubts around it, feel free to post those on UIDAI hackathon forum