iimport cyperf
from cyperf.models.async_operation_response import AsyncOperationResponse
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "https://url_here",
username="user",
password="pass",
refresh_token=None
)
configuration.verify_ssl = False
with cyperf.ApiClient(configuration) as api_client:
api_instance = cyperf.LicensingApi(api_client)
try:
api_response = api_instance.get_counted_feature_stats()
print("The response of LicensingApi->get_counted_feature_stats:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling LicensingApi->get_counted_feature_stats: %s\n" % e)
Issue:
The licensing api method
get_counted_feature_statshas two issues:The method always returns None. This is due to a
200 OKresponse code coming back from API endpoint instead of the202 Acceptedresponse expected by the method. Its of note that the Controllers (v6.0 build 14216) swagger API spec doesn't document a 200 response, (which would explain why the openapi-generator didn't include it in the code).The 200 OK response data doesn't fully match the AsyncOperationResponse schema - it's missing a
result_urlfield. This causes a validation error if the response data is assigned to the AsyncOperationResponse class.Steps to Reproduce:
Versions:
c8e07832bf2befa4f3c1b179a422c0bfb3f2d69c