Azure-Samples / azure-samples-python-management

This repo contains sample code for management libraries of Azure SDK for Python
MIT License
154 stars 131 forks source link

Recommendation to use REST API in Python #144

Open hammad93 opened 7 months ago

hammad93 commented 7 months ago

With the necessity of installing multiple dependencies and then the overhead of managing and updating them, utilizing the REST API instead of the Python SDK has been easier. There are no dependencies as requests is bulit-in and there's no updates required. While I think the Python SDK is still necessary, I wanted to provide this perspective for developers to just use requests and make the REST API call is also a good solution.

It also looks like the samples have the sample JSON data structures that the REST API expects too.

msyyc commented 7 months ago

Comparing with REST API call with requests, Python SDK can provide other function (e.g. authentication/customized policy/unified exception/...). Each way has pros/cons, and developers can choose any way they like to use Azure service.