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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

API in Power Query using this script and link

Hello people

I am new to Power Query and I am trying to get data using an api. 

The source is this:

https://api.statbank.dk/v1/data

The script is this:

{
"table": "FOLK1a",
"format": "BULK",
"valuePresentation": "Code",
"delimiter": "Semicolon",
"variables": [
{
"code": "OMRÅDE",
"values": [
"084"
]
},
{
"code": "Tid",
"values": [
"2010K1",
"2015K1",
"2020K1"
]
},
{
"code": "CIVILSTAND",
"values": [
"U"
]
},
{
"code": "KØN",
"values": [
"1",
"2"
]
},
{
"code": "ALDER",
"values": [
"25",
"45",
"65"
]
}
]
}

 

The expected output is this:

OMRÅDE;TID;CIVILSTAND;KØN;ALDER;INDHOLD
084;2010K1;U;1;25;10281
084;2010K1;U;1;45;3806
084;2010K1;U;1;65;872
084;2010K1;U;2;25;10290
084;2010K1;U;2;45;2823
084;2010K1;U;2;65;688
084;2015K1;U;1;25;13072
084;2015K1;U;1;45;3586
084;2015K1;U;1;65;1102
084;2015K1;U;2;25;13162
084;2015K1;U;2;45;2687
084;2015K1;U;2;65;829
084;2020K1;U;1;25;14604
084;2020K1;U;1;45;4066
084;2020K1;U;1;65;1405
084;2020K1;U;2;25;14848
084;2020K1;U;2;45;3300
084;2020K1;U;2;65;1171

 

I hope you can help me by creating the total script in power query based on the information above!

Kind regards

2 REPLIES 2
v-juanli-msft
Community Support
Community Support

Hi @Anonymous 

It is possible to connect to the api followed by the second url from amitchandak.

But it would need a proper authentication type.

 

Best Regards

Maggie

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors