Refresh Auth0 Management API token

We're using Retool for user management of our app via Auth0. In order to create and edit users we're using the Auth0 management API and our management API token expires every 30 days.
We can call an API to get a new token but I don't want to do that on every request. Is there a way to cache an API key somewhere in the retool app?

@Dominic1
An idea I had that could work is that you could setup a workflow that goes to the API and gets the new auth token, and then hits the retool API (see Retool Developer API | Retool Docs) to update the token in that specified resource.

1 Like

I'll give that a try. Thanks, @ben-salesi !

Unless I'm missing something, based on the docs, there are no APIs to update resources only to GET or DELETE.

Hello @Dominic1!

Looking at the docs it appears there is a PATCH route to update users here

Also if you are storing the API token as a user's attribute, you can do so with a POST request as outlined by the docs here

Hope this helps and let me know which of those works for your use case!