hellotimi
(David Kalu (Formula PRO - Advanced Automations for native monday formula columns, Mirror Columns & Subitems!))
1
Is there a way to get a new shortLivedToken after one expires after the allotted 5 minutes window?
When my integration recipe action endpoint is called with a lot of items, I first place them on a queue with their respective shortLivedToken before executing each. Sometimes, for requests that are handled after their shortLivedToken has expired, I get a NOT_AUTHENTICATED error back from the monday graphql api.
Is there a way to request a new shortLivedToken or run a long running request with an authenticated token?
@Matias We’re facing the same issue as @hellotimi where users sometimes trigger our integration recipes on hundreds of items simultaneously.
From an end-user perspective, how does OAuth work? For example, does each user need to go through the OAuth every time they initiate an integration recipe? How do we initiate the OAuth flow when we can’t control the monday.com UI?
Sorry if my questions are stupid, but we’re desperate for a solution …
hellotimi
(David Kalu (Formula PRO - Advanced Automations for native monday formula columns, Mirror Columns & Subitems!))
8
User does not need to go through oAuth every time. You can use this option that comes on the integration recipes setup page in your app.
When the user adds the automation for the first time, they will be navigated to oAuth flow, using the url you provide here. When a token is fetched, you can save that in the storage. After that, every time the automation runs, you can use to the shortLivedToken to access the storage and fetch the oAuth token.
In this case, the shortLivedToken will be that of the user who created the integration recipe. How about if we need to run the integration as the user who triggered the recipe (say, by updating a status column)? Can we use the OAuth authorization of the user who created the recipe to fetch the shortLivedToken of the user who triggered the recipe? The triggering user may not necessarily have gone through the OAuth process.
Hello @samicaracand , ShortLivedToken will be generated for the triggering user irrespective of if they go through oAuth or not. You can then use this shortLivedToken to access the storage and fetch the previously stored token.
However, I am not entirely sure if this OAuth token (generated by user who has set up the recipe) , can be used by the triggering user to successfully complete the automation. That needs to be tested. Hope that helps.