Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello all,
I got a problem with my scrolling POST REST API request.
Description of what I want to do:
1. At the moment I´m doing a call against the first API where I get back an "ExportID".
2. With that "ExportID" I request the second APi called "ExportAPI".
3. Now I do a scrolling export (with a loop) against that second API that puts all data per request in one table - the amount of calls vary based on the request (input parameters) I do against the first API (e.g. 20 calls)
fyi:
Usual behaviour of the scrolling export when you do it for example over Postman:
The call against the second (exportAPI) is always the same with the same "ExportID". But with every request you will get other data back. Therefore, the "ExportAPI" will know that for this specfic "ExportID" a request was made and will get you the second scroll.
Description of the problem:
I have no problems setting up the code or the loop (done with list.generate). I`m at the point where I get the expected results for the first scroll.
But now if I look at the second scroll, the data I´m getting back is exactly the same as in the first scroll.
I have the guess that PowerBI knows that I do the the same request with the same "ExportID" for each scroll and is caching the the first scroll and puts the results of the first scroll also in the sceond and third one and so one.
Therefore, I get the same data for each scroll.
Is there a way to bypass that cache?
I already tried to create a own function for both requests that are called within every loop, but with the same result.
I´m trying now for a long time with no solution to that problem.
Any suggestions?
@amitchandak I saw you repsonded in quite a lot of forum posts regarding REST API calls maybe you can help here.
Thank you in advance,
Pascal
Solved! Go to Solution.
To prevent the cache from playing with you you can add a random query parameter to each request
<url>?ExportID=123456&r=<current UTC timestamp>
That parameter will be ignored by the API but it throws the cache off.
To prevent the cache from playing with you you can add a random query parameter to each request
<url>?ExportID=123456&r=<current UTC timestamp>
That parameter will be ignored by the API but it throws the cache off.