A golang version of simple OTP server.
Reference: Google Authenticator
POST /totp/authurl
Request
{
"issuer":"My Company",
"accountName":"foo@bar.com",
"secret":"WgQacDUV24W4myXP"
}
Response
{
"authURL": "otpauth://totp/My%20Company:foo@bar.com?issuer=My+Company&secret=K5TVCYLDIRKVMMRUK42G26KYKA"
}
Scan the QRCode below with Google Authenticator:
POST /totp/verify
Request
{
"token": "123456",
"secret": "WgQacDUV24W4myXP"
}
Response
{
"isValid": true
}