Resolution
- Upgrade to Tableau server version 2022.3 or higher.
Versions of the REST API are made available with releases of Tableau Server and signing in with a JSON Web Token (JWT), from a connected app was introduced in API 3.17
API version can be verified in the XML Schema Definition (XSD) file location in the response body or by checking the Tableau server version.
- Setting the expiration time of the JWT to 15 minutes or lower.
When a JWT expires, it will no longer be accepted by the system that it is used to authenticate with. Setting it to more that 15 minutes will result in sign-in error 401001.
Expiry time can be set in the JSON payload used to generate JWT. If python is used, then below command is used to set the expiry time.
"exp": datetime.datetime.utcnow() + datetime.timedelta(minutes=5)
In both these scenarios, authentication with other methods like username password and PAT will be successful.