Azure / autorest.python

Extension for AutoRest (https://github.com/Azure/autorest) that generates Python code
MIT License
81 stars 57 forks source link

Support SDK examples for DPG to be shown in Rest API document on Docs #1284

Open lirenhe opened 2 years ago

lirenhe commented 2 years ago

The samples section we have today on the REST API reference docs isn't something that customers can easily use and run within their code. It's usually the case that we want customers viewing REST API documentation to not make the request using the REST API itself but through some sort of client library that is native to their programming language.

Solution: On REST API document on Docs, show SDK code samples corresponding to REST API examples from Azure REST API Specifications. (Example: Create Event - Microsoft Graph v1.0 | Microsoft Docs).

We could follow the same approach of mgmt SDK to store DPG code samples in Azure/azure-rest-api-specs-examples: SDK examples for azure-rest-api-specs (github.com).

REST API document and SDK code samples should be of the same version.

iscai-msft commented 1 year ago

@lirenhe is this something we're still looking to do? cc @msyyc

lirenhe commented 12 months ago

I would like to have the feature to be enabled into DPG as this would be very helpful for end users. But this is low priority compared with other work we have.