Help Center> Optical Character Recognition> FAQ> Error Code> Why Is an Error Message with Error Code "APIG.0307" Displayed When an API Is Called?

Why Is an Error Message with Error Code "APIG.0307" Displayed When an API Is Called?

If the error message "The token must be updated." and error code "APIG.0307" are displayed when an API is called, the token has expired and needs to be updated.

Do the following to rectify the fault:

  • The validity period of a token is 24 hours. Obtain the token again to call the API.
  • Check whether the endpoint in the API URL is correct. For details about endpoints, see Endpoints. Services deployed in different regions cannot be called across regions. If APIs in different regions are called, the token is invalid and error code APIG.0307 is displayed.