Adding Google Authenticator token along with username and password in login

How to integrate google authenticator app as in login page, where along with username and password. we can take an extra input for token and this token will e authenticated by an already available api.