Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I am reading a MS documentation, it says one can refresh sql endpoint meta data via a http call:
How can I run a http call in notebook? Is it complicated?
Solved! Go to Solution.
Hi Jeanxyz,
You can run HTTP calls directly from a notebook in Microsoft Fabric using Python, and it's straightforward if you use the popular requests library. This approach works in both Spark and non-Spark Python environments.
import requests
url = "https://api.fabric.microsoft.com/v1/workspaces/{workspaceId}/sqlEndpoints/{sqlEndpointId}/refreshMetadata"
headers = {
"Authorization": "Bearer YOUR_ACCESS_TOKEN"
}
response = requests.post(url, headers=headers)
print(response.status_code)
print(response.text)
Replace {workspaceId}, {sqlEndpointId}, and YOUR_ACCESS_TOKEN with your actual values. You must provide a valid Azure AD access token, this usually involves authentication, which can be handled via Azure Identity, MSAL, or other SDKs that you may already use for automation.
Hope that helps
Onur
😊If this post helped you, feel free to give it some Kudos! 👍
✅And if it answered your question, please mark it as the accepted solution.
Hi @Jeanxyz
We would like to confirm whether the issue has been resolved. If it is still outstanding, please share any additional information so we can assist you further.
Thank you.
Hi @Jeanxyz
Thanks for reaching out to the Microsoft fabric community forum.
I would also take a moment to thank @OnurOz , for actively participating in the community forum and for the solutions you’ve been sharing in the community forum. Your contributions make a real difference.
I hope the shared details help you fix the issue. If you still have any questions or need more help, feel free to reach out. We’re always here to support you
Best Regards,
Community Support Team.
Hi Jeanxyz,
You can run HTTP calls directly from a notebook in Microsoft Fabric using Python, and it's straightforward if you use the popular requests library. This approach works in both Spark and non-Spark Python environments.
import requests
url = "https://api.fabric.microsoft.com/v1/workspaces/{workspaceId}/sqlEndpoints/{sqlEndpointId}/refreshMetadata"
headers = {
"Authorization": "Bearer YOUR_ACCESS_TOKEN"
}
response = requests.post(url, headers=headers)
print(response.status_code)
print(response.text)
Replace {workspaceId}, {sqlEndpointId}, and YOUR_ACCESS_TOKEN with your actual values. You must provide a valid Azure AD access token, this usually involves authentication, which can be handled via Azure Identity, MSAL, or other SDKs that you may already use for automation.
Hope that helps
Onur
😊If this post helped you, feel free to give it some Kudos! 👍
✅And if it answered your question, please mark it as the accepted solution.
Check out the November 2025 Fabric update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!