Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi,
I have a python program that posts data via requests.post using the Push URL. This works fine.
Is there a way to request.get with a get URL? This would allow me to check what data I already have in the push dataset on Power BI and only post the new data, for example if the program stopped working in the middle of the day.
Thanks for any help
import requests
import msal
app_id = ''
tenant_id = ''
username = ''
password = ''
authority_url = f'https://login.microsoftonline.com/{tenant_id}'
scopes = [r'https://analysis.windows.net/powerbi/api/.default']
client = msal.PublicClientApplication(app_id, authority=authority_url)
response = client.acquire_token_by_username_password(username, password, scopes)
access_id = response.get('access_token')
endpoint = 'https://api.powerbi.com/v1.0/myorg/groups'
headers = {
'Content-Type': 'application/json',
'Authorization': f'Bearer {access_id}'
}
response_request = requests.get(endpoint, headers=headers)
if response_request.status_code == 200:
result = response_request.json()
for item in result['value']:
print(item['name'])
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
8 | |
7 | |
2 | |
2 | |
2 |
User | Count |
---|---|
6 | |
5 | |
4 | |
4 | |
4 |