[Python] 5094 followup - Reduce redundancy in docs (#5161)

* Reduce redundancy in python docs

This is a followup to PR #5094, which had a few unresolved comments at
merge time. This reduces the amount of redundant lines in the api
example doc templates, and ensures that referenced Configuration objects
are actually instantiated.

* Regenerate samples
This commit is contained in:
Fabian von Feilitzsch
2020-02-06 13:58:17 -08:00
committed by GitHub
parent 197cea3248
commit c943ecfe28
32 changed files with 133 additions and 68 deletions

View File

@@ -482,6 +482,7 @@ configuration.password = 'YOUR_PASSWORD'
# Defining host is optional and default to http://petstore.swagger.io:80/v2
configuration.host = "http://petstore.swagger.io:80/v2"
# Enter a context with an instance of the API client
with petstore_api.ApiClient(configuration) as api_client:
# Create an instance of the API class