To create news based power BI dashbaord

Dear All,

I wish to create a Power Bi dashboard regarding publically available news - say using google api or any api which can pull out news which is as per my company list on few keywords like compliance, forced labour.

I saw this link - https://community.powerbi.com/t5/Community-Blog/Make-your-own-News-Dashboard-in-Power-BI/ba-p/836657

To create the same but problem is its not filtering using specific keywords, I wish results to be like make a table with Column A - Company name like microsoft, column B - display news as per back end keywords like - forced labour, anti-competition, bribe and lawsuits.

My keywords can change but news I should get as per keywords, any help in this will be highly appreciated
Regards,
AK

Hi @AbhinavKumar,

Warm welcome to the forum. You can achieve this easily using Power BI. Please note following things:

  1. You will have to use your own API key. You will have to replace your API key in the Advanced editor of News function.
  2. Create a table with all your required search words in the column. Go to “Add column–>Invoke custom function” and then invoke “News function” and you will get the result.

I have used Google,Facebook,Microsoft etc as a query and got output as attached from the source you mentioned.

EDNA_Dynamic_News.pbix (29.7 KB)

Please feel free to get in touch in case of any issue.

Kind Regards,
Hafiz

2 Likes

Dear Hafiz,

It will be helpful, if you can explain with some screenshot as I couldn’t follow through on using own API, there is 1 way to get API from source and I got it, but can I use google API in general to pull out news.

Also - say we use API then how can we create a column with news on following keywords “anti-competition”, “bribery” etc., I saw few tables in the PBI report but couldn’t follow through.

Thanks again for the effort.
Regards,
AbhinavKr

Hi @AbhinavKumar,

No problem, if you have any specific API that you want to use, please let me know with the credential in PM and I can help you to integrate with this solution. I have simplified it and you just need to change below:

  1. Change the path of source file in Query editor. Source file is attached.

  1. Change the API key or API if you wish in the “News” query.

  1. update you file with the keywords you want to search and save excel file. Come to Power BI and use Refresh and it will refresh you data.

Final file and sample sheet is attached. In case of any issue, please don’t hesitate to contact.

Kind Regards,
Hafiz

Search File.xlsx (7.9 KB) EDNA_Dynamic_News V2.pbix (32.7 KB)

2 Likes

Dear Hafiz ,

Many thanks man for the solution, while I kept your api and changed the keywords seems the news that is coming is not very exact and relevant and there is also duplicates. How can we make news relevant , or remove duplicates here.

I assume google news API will be best - is there any way we can use it as news API is free but is seems its giving more USA related news

For example see this below, I used keyword Siemens to pull out news related to “Siemens” company and its giving politics related news:

@AbhinavKumar,

Here you go!!, it is based on google news and you need to take same steps mentioned previously. It is based on google, so you just need to update excel file to run it as per your keywords.

Kind Regards,
Hafiz
EDNA_Dynamic_News V2.pbix (96.2 KB)

1 Like

Dear Hafiz,

Massive thanks indeed man, just few things please don’t get bothered as I asked lot of question, can i add weblink in this google news format which is working good.

No worries at all @AbhinavKumar, this forum is all about learning and helping each other. Which weblink do you want to add?

1 Like

just the column symbol and URL as we see here in this visualisation , this column name was coming when we used api news source

HI @AbhinavKumar,

Symbol and source is available and it will bring only information which will be visible on google news webiste.

Following information is from website:

image

If you have some other API or sample, please share. Cheers!

1 Like

Dear Hafiz,

Many thanks for the code and file, I assume in google based search we cant use security setting as none - I was asked this prompt and I did it to avoid any issue.

I have the made the file like this:

image

The only thing if i may add is to have a column on source like like this

www.abc.com, which is where from news is getting picked up - is it possible to add in the m code of news section blank query which we ran.

I hope we don’t need any api for this google based search its easy and we can do without any license required - am I correct ?

Many thanks again - Kudos to you for help here