osc api
Perform direct REST API requests with authorization
This command enables direct REST API call with the authorization and version discovery handled transparently. This may be used when required operation is not implemented by the osc
or some of the parameters require special handling.
Example:
console osc --os-cloud devstack api compute flavors/detail | jq
Usage: osc api [OPTIONS] <SERVICE_TYPE> <URL>
Arguments:
<SERVICE_TYPE>
— Service type as used in the service catalog<URL>
— Rest URL (relative to the endpoint information from the service catalog). Do not start URL with the "/" to respect endpoint version information
Options:
-
-m
,--method <METHOD>
— HTTP MethodDefault value:
get
Possible values:
head
: HEADget
: GETpatch
: PATCHput
: PUTpost
: POSTdelete
: DELETE
-
-H
,--header <key=value>
— Additional headers -
--body <BODY>
— Request body to be used