Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
bartus1
Helper I
Helper I

Loop Through Several Values, Change API Call URL and Insert Into Table

Hi,

 

Have seen this thread, but I am still unclear what to do...

 

1.  API call - gets IDs wchih are stored in table1 - works great.  Table is neat and ready to go.

2.  Need to make another API call FOR EACH ID stored previously (table1), which will return items for each ID.

 

Eventually, will do 3rd call to get all detaisl for each item ID from #2.

 

Thanks.

1 ACCEPTED SOLUTION

Thanks a bunch v-ljerr-msf.

 

The 2nd article did help a lot.  Now, it seems very easy LOL.  I did run cirles around this.

 

Very much appreciated.

 

Bart

View solution in original post

2 REPLIES 2
v-ljerr-msft
Microsoft Employee
Microsoft Employee

Hi @bartus1,

 

Have you managed to create a function like below.

let functionName = (param1 as datatype) =>
let
 Source = Json.Document(Web.Contents("URL" & param1 & "/summary").
in
 Source
in functionName

If yes, then what you need to do next is adding a custom column in table1 that calls/invokes the function above. You should be able to find the detailed steps in following two articles. Smiley Happy

 

http://datachix.com/2014/05/22/power-query-functions-some-scenarios/

http://satalyst.com/power-query-creating-a-parameterized-function-in-m/

 

Regards

Thanks a bunch v-ljerr-msf.

 

The 2nd article did help a lot.  Now, it seems very easy LOL.  I did run cirles around this.

 

Very much appreciated.

 

Bart

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors