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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
ngomes
Helper II
Helper II

API

Good afternoon everyone,

I would like to know if anyone has used the BPstat Data API from Banco de Portugal?

 

I appreciate any help you can give me

 

API INFO
https://bpstat.bportugal.pt/data/docs 

2 ACCEPTED SOLUTIONS
Anonymous
Not applicable

Hi @ngomes,

Perhaps you can try to use a web connector to get data from that API, it allows you to send tokens in the request header/body when working with 'anonymous' mode:

Chris Webb's BI Blog: Using The RelativePath And Query Options With Web.Contents() In Power Query An...

let
    authKey = "xxxxx",
    url = "https://bpstat.bportugal.pt/data/v1/",
    body = "xxxxxx",
    GetJson =
        Web.Contents(
            url,
            [
                Headers = [
                    #"Authorization" = authKey,
                    #"Content-Type" = "application/json"
                ],
                RelativePath = "xxxxxx/xxxxx",
                Content = Text.ToBinary(body)
            ]
        ),
    token = Json.Document(GetJson)[access_token],
    series_id = "xxxxxx",
    Result =
        Web.Contents(
            url,
            [
                Headers = [
                    #"Content-Type" = "application/json",
                    Authorization = "Bearer " + token
                ],
                RelativePath = "xxxxxx/xxxxx",
                Query = [
                    lang = "EN",
                    series_ids = series_id
                ]
            ]
        )
in
    Result

Regards,

Moonlight

View solution in original post

Anonymous
Not applicable

Hi @ngomes,

Did the above suggestions help with your scenario? if that is the case, you can consider Kudo or Accept the helpful suggestions to help others who faced similar requirements.

If these also don't help, please share more detailed information to help us clarify your scenario to test.

How to Get Your Question Answered Quickly 

Regards,

Xiaoxin Sheng

View solution in original post

4 REPLIES 4
ichavarria
Solution Specialist
Solution Specialist

Hi @ngomes - Probably you can share more details. However, you can definitely try with the Web connector in Power BI Desktop. Just be careful of the privacy level you are selecting in Power BI Desktop to make sure it is similar to what your dataset will experience in Power BI Service. Here is a helpful link you can visit: Understand Power BI Desktop privacy levels - Power BI | Microsoft Learn.

Anonymous
Not applicable

Hi @ngomes,

Did the above suggestions help with your scenario? if that is the case, you can consider Kudo or Accept the helpful suggestions to help others who faced similar requirements.

If these also don't help, please share more detailed information to help us clarify your scenario to test.

How to Get Your Question Answered Quickly 

Regards,

Xiaoxin Sheng

Anonymous
Not applicable

Hi @ngomes,

Perhaps you can try to use a web connector to get data from that API, it allows you to send tokens in the request header/body when working with 'anonymous' mode:

Chris Webb's BI Blog: Using The RelativePath And Query Options With Web.Contents() In Power Query An...

let
    authKey = "xxxxx",
    url = "https://bpstat.bportugal.pt/data/v1/",
    body = "xxxxxx",
    GetJson =
        Web.Contents(
            url,
            [
                Headers = [
                    #"Authorization" = authKey,
                    #"Content-Type" = "application/json"
                ],
                RelativePath = "xxxxxx/xxxxx",
                Content = Text.ToBinary(body)
            ]
        ),
    token = Json.Document(GetJson)[access_token],
    series_id = "xxxxxx",
    Result =
        Web.Contents(
            url,
            [
                Headers = [
                    #"Content-Type" = "application/json",
                    Authorization = "Bearer " + token
                ],
                RelativePath = "xxxxxx/xxxxx",
                Query = [
                    lang = "EN",
                    series_ids = series_id
                ]
            ]
        )
in
    Result

Regards,

Moonlight

lbendlin
Super User
Super User

looks like a standard anonymous API with load throttling.

Please provide a more detailed explanation of what you are aiming to achieve. What have you tried and where are you stuck?

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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