This is best Fabric, Power BI, SQL and AI community event. How do we know? The last event sold out! Save €200 with code FABCMTY200.
Register nowA new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.
Dear all,
Apologies, as i know this question has been asked before and their are several blogs regarding it, but not seem to match my exact scenario and after spending several dats researching i've not been able to solve.
Basically, i have an API that uses two parameters (Base_ID and Table_ID) to extract all records. To do this i followed this brilliant video and method https://www.youtube.com/watch?v=iiNDq2VrZPY. This works perfectly in PowerBI Desktop, but when it comes to scheduling a refresh it says Dynamic Data Sources aren't supported.
I have read that there is a work around, whereby you convert this to a web.contents, but honestly i'm very lost as tow where this can be applied and how, so any help would be greatly appreciated.
Below is the code behind the function, where i 'think' the changes are needed.
let
Source = (BASE_ID as text, TABLE_ID as text) => let
apiUrl = "https://api.airtable.com/v0/"&[BASE_ID]&"/"&[TABLE_ID]&"?Api_key=", token="xxxxxxxxx", options = [Headers=[#"Authorization"="Bearer " & token ]], result = Json.Document(Web.Contents(apiUrl , options)), records = result[records],
#"Converted to Table" = Table.FromList(records, Splitter.SplitByNothing(), null, null, ExtraValues.Error),
#"Expanded Column1" = Table.ExpandRecordColumn(#"Converted to Table", "Column1", {"id", "createdTime", "fields"}, {"Column1.id", "Column1.createdTime", "Column1.fields"}),
#"Expanded Column1.fields" = Table.ExpandRecordColumn(#"Expanded Column1", "Column1.fields", {"Start Date", "Progress", "Status", "Categories", "End Date", "Priority", "Leader", "All projects - Gantt"}, {"Column1.fields.Start Date", "Column1.fields.Progress", "Column1.fields.Status", "Column1.fields.Categories", "Column1.fields.End Date", "Column1.fields.Priority", "Column1.fields.Leader", "Column1.fields.All projects - Gantt"}),
#"Extracted Values" = Table.TransformColumns(#"Expanded Column1.fields", {"Column1.fields.Leader", each Text.Combine(List.Transform(_, Text.From), ","), type text}),
#"Extracted Values1" = Table.TransformColumns(#"Extracted Values", {"Column1.fields.All projects - Gantt", each Text.Combine(List.Transform(_, Text.From), ","), type text})
in
#"Extracted Values1"
in
Source
Thanks
sdg
Hi @Sdg8481 ,
Please check out this article:
Chris Webb's BI Blog: Web.Contents(), M Functions And Dataset Refresh Errors In Power BI Chris Webb'...
You have to create a query record with for the function parameters.
Imke Feldmann (The BIccountant)
If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!
How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 1 |