Closed Kingdutch closed 4 years ago
Thanks @Kingdutch !
For a 'quick test to the API' you might be interested in
platform api:curl /regions
docs:
Command: api:curl
Description: Run an authenticated cURL request on the Platform.sh API
Usage:
platform api:curl [-X|--request REQUEST] [-d|--data DATA] [-i|--include] [-I|--head] [--disable-compression] [-H|--header HEADER] [--] [<path>]
Arguments:
path The API path
Options:
-X, --request=REQUEST The request method to use
-d, --data=DATA Data to send
-i, --include Include headers in the output
-I, --head Fetch headers only
--disable-compression Do not use the curl --compressed flag
-H, --header=HEADER Extra header(s) (multiple values allowed)
-h, --help Display this help message
-q, --quiet Do not output any message
-V, --version Display this application version
-y, --yes Answer "yes" to any yes/no questions; disable interaction
-n, --no Answer "no" to any yes/no questions; disable interaction
-v|vv|vvv, --verbose Increase the verbosity of messages
The
Region::$id
property was documented to be anint
. However according to the docs (https://api.platform.sh/docs/#tag/Regions and https://api.platform.sh/docs/#operation/RestfulEntityBlimpPlatformRegion::view) it's actually astring
.A quick test call the the API confirms that the documentation is correct and the client is incorrect. Below is a
var_dump
of a singleRegion
returned by$this->platformClient->getRegions()
.