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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
Anonymous
Not applicable

Not able to connect REST API link in Linux while pushing data

Able to push data to a streaming dataset through Python script from my local. But, not able to connect to API URL with the same script from Linux.  Can you please help me on this.

2 REPLIES 2
v-yalanwu-msft
Community Support
Community Support

Hi, @Anonymous ;

The main reason for the failure is probably a port problem. Power BI verifies only the word fields and information in the request.

 

https://realpython.com/api-integration-in-python/

https://docs.microsoft.com/en-us/power-bi/admin/power-bi-allow-list-urls

Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Thanks much @v-yalanwu-msft for the response!

 

https://realpython.com/api-integration-in-python/

https://docs.microsoft.com/en-us/power-bi/admin/power-bi-allow-list-urls

 

I have gone through above two links those you have provided. I tried to post some sample data to the streaming dataset. Below is the script I have used,

 

import requests
api_url = "https://api.powerbi.com/my dataset url"
todo = {"userId": 1, "title": "Buy milk", "completed": False}
response = requests.post(api_url, json=todo)
print(response.json())
{'userId': 1, 'title': 'Buy milk', 'completed': False, 'id': 201}
print(response.status_code)

This is working fine and I'm able to post data from my local machine. But, when I execute the same script in my Linux I'm getting below error.

 

requests.exceptions.ConnectionError: HTTPSConnectionPool(host='api.powerbi.com', port=443): Max retries exceeded with url: my dataset url (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f7cf678f640>: Failed to establish a new connection: [Errno 110] Connection timed out'))

 

Do I need to add this api url in AllowList? If yes, how can I add it. Can you please share any link or process to add it. Otherwise, do I need to ask my Linux/Azure admin to add this api link to AllowList?

 

Thanks!

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.

Top Solution Authors