Using the API

Using the API

Hello, 
I'm struggling to find an answer to this.
the steps for contacting the API seem to be:
Create an application in https://api-console.zoho.com/ in my case Self Client
copy the client id and secret
and when i make a request I then need to manually go to this application, create a OTP generated code thats valid between 3-10 minutes, enter that code and then I will be able to request an auth token, which I can use to make API calls and refresh th token.

My question is, is there a way of programmatically generating or getting this OTP generated code? my concern is if i have an application that is running in an unattended mode and its restarted for an OS update the token will no longer be valid and won't be able to refresh, as such I will have to go back and manually do another OTP generated code to then re-establish the communication.

is this correct or is there a method of using the client_id and secret to request the generated code?

                New to ADManager Plus?

                  New to ADSelfService Plus?