Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Operations can now be called from the spec by operationId
Intended usage is this:: spec = OpenAPI(spec_yaml) result = spec.call_getLinodeInstances(security={"personalAccessToken": token}) This uses a custom __getattribute__ to convert all attributes started with call_ to an OperationCallable configured with the (first) base_url it finds such that it is immediately called with the given arguments.
- Loading branch information
Showing
2 changed files
with
39 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters