cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
Ben_Nash
Helper I
Helper I

Automatically refresh JSON feed

Hi

 

I’m looking to automatically refresh a webhose.io JSON feed in Power BI.  

 

Webhose.io gives you an ‘endpoint’ and I’ve managed to feed this into Power BI successfully via the JSON connector, but this only gives you the first 100 articles:

 

http://webhose.io/filterWebContent?token=cea99d95-447a-4aa9-955b-05a55c1a9f32&format=json&sort=crawl...

 

You need to keep adding the ‘next’ code in order to get the next 100 articles:

 

"totalResults": 38544,

"moreResultsAvailable": 38444,

 "next": "/filterWebContent?token=cea99d95-447a-4aa9-955b-05a55c1a9f32&format=json&ts=1510365182000&q=%22donald+trump%22+language%3Aenglish&sort=crawled",

 

Is it possible to write a script in Power Query that allows you to automatically 'cycle' through all articles?

 

Any assistance appreciated!

 

Thanks

 

Ben

3 REPLIES 3
v-huizhn-msft
Microsoft
Microsoft

Hi @Ben_Nash,

After research, there is no "looping" in Power Query, only recursion. And I list some blog and threads below. Hope it it's helpful.

Do … While loop with Power BI (M language)
How to automate/parameterize/loop power query?
Be Fitbit BI Developer in Few Steps: Step 2 Loop Through All CSV Files

In addition, you can also go to the Power Query forum to get dedicated support.

Best Regards,
Angelia

Hi Angelia

 

Thanks - I'll look into options outlined! I'm thinking the other way to incorporate the webhose.io JSON feed into Power BI is via Power BI's REST APIs?

 

Thanks

 

Ben

Hi @Ben_Nash.

More knowloedage about Power BI's REST API, you can post your thread in Power BI develper to get dedicated support.

Thanks,
Angelia

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors