We come across a problem regarding FastAPI app deployed in a private space. The problem is a JWT token, which is issued by HuggingFace, last for only 24 hours. This token is used to authenticate our access to HuggingFace account in either on-site access or API call. Following is a token sample that token is assigned to a parameter (__sign)
We’re wondering if there is a way for us to modify this token expiration length, or there is a way to retrieve the refresh token through an API call in client side script?
We tried to set FastAPI user authentication and JWT token in our app, but it didn’t work because this token from __sign is for HuggingFace user login purpose.
We also tried to use the HF access token that is available to copy in the account setting. It didn’t work as well
Looking forward to hearing your thoughts and advice. Thanks in advance!!