The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hello how are you?
I need to consume data from an API as follows:
API url: ws.com.br/data/2020-01-20
user: abcd
password: 1234
However, I need to consume from the same API and simultaneously connect to the same url with a different user:
user: efgh
password: 5678
Is it possible in a single query to consolidate the data for both users? Hou can i write this in the power query?
Thank you very much!
Here are two ways you could do this
1. Hard code the credentials in two separate queries and then append them together. Since the web calls likely return the same data (column names, etc.), the append should work smoothly.
2. Make a table with two columns to hold the username and passwords for both users. Then add a custom column that concatenates the userid and password into the web call. Then expand the resulting tables to have all the data in one table.
To get a more detailed response, more info on the authentication for that API is likely needed. Have you already worked out how to make a single web call one with set of credentials? If so, either approach above should work.
Pat
To learn more about Power BI, follow me on Twitter or subscribe on YouTube.