I'm trying to autogenerate a Python client from the published OpenAPI specs, but all the different approaches I've tried fail because due to schema validation issues:
Using autorest 3.6.3 gives a pretty comprehensive breakdown of the issues:
error | schema_violation | Schema violation: must be equal to one of the allowed values (paths > /api/analytics/v1/query/ > post > requestBody > content > application/json > schema > properties > metric_filters > properties > conditions > items > properties > condition > properties > value > type)
allowedValues: array, boolean, integer, number, object, string
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:6087
error | schema_violation | Schema violation: must be equal to one of the allowed values (paths > /api/analytics/v1/query/ > post > requestBody > content > application/json > schema > properties > options > properties > sampling > type)
allowedValues: array, boolean, integer, number, object, string
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:7441
fatal | Plugin 'schema-validator-openapi' completed with some error.
error | schema_violation | Schema violation: must have required property 'examples' (paths > /api/analytics/v1/query/ > post > requestBody > content > application/json)
missingProperty: examples
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:1185
error | schema_violation | Schema violation: must match exactly one schema in oneOf (paths > /api/analytics/v1/query/ > post > requestBody > content > application/json)
passingSchemas: null
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:1185
error | schema_violation | Schema violation: must be string (paths > /api/analytics/v1/query/ > post > responses > 200 > content > application/json > schema > properties > data > items > description)
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:8696
error | schema_violation | Schema violation: must have required property 'examples' (paths > /api/analytics/v1/query/ > post > responses > 200 > content > application/json)
missingProperty: examples
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:8526
error | schema_violation | Schema violation: must match exactly one schema in oneOf (paths > /api/analytics/v1/query/ > post > responses > 200 > content > application/json)
passingSchemas: null
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:8526
error | schema_violation | Schema violation: must be string (paths > /api/analytics/v1/sessions/ > post > responses > 200 > content > application/json > schema > properties > data > items > description)
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:16022
error | schema_violation | Schema violation: must be equal to one of the allowed values (paths > /api/analytics/v1/sessions/ > post > responses > 200 > content > application/json > schema > properties > meta > properties > columns > items > type)
allowedValues: array, boolean, integer, number, object, string
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:16234
error | schema_violation | Schema violation: must have required property 'examples' (paths > /api/analytics/v1/sessions/ > post > responses > 200 > content > application/json)
missingProperty: examples
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:15852
error | schema_violation | Schema violation: must match exactly one schema in oneOf (paths > /api/analytics/v1/sessions/ > post > responses > 200 > content > application/json)
passingSchemas: null
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:15852
error | schema_violation | Schema violation: must be equal to one of the allowed values (paths > /api/analytics/v1/events/ > post > responses > 200 > content > application/json > schema > properties > meta > properties > columns > items > type)
allowedValues: array, boolean, integer, number, object, string
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:23621
error | schema_violation | Schema violation: must have required property 'examples' (paths > /api/analytics/v1/events/ > post > responses > 200 > content > application/json)
missingProperty: examples
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:23260
error | schema_violation | Schema violation: must match exactly one schema in oneOf (paths > /api/analytics/v1/events/ > post > responses > 200 > content > application/json)
passingSchemas: null
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:23260
error | schema_violation | Schema violation: must be equal to one of the allowed values (components > schemas > QueryRequest > properties > metric_filters > properties > conditions > items > properties > condition > properties > value > type)
allowedValues: array, boolean, integer, number, object, string
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:30492
error | schema_violation | Schema violation: must be equal to one of the allowed values (components > schemas > QueryRequest > properties > options > properties > sampling > type)
allowedValues: array, boolean, integer, number, object, string
- https://developers.piwik.pro/en/latest/_static/api/custom_reports_http_api.json:1:31846
Hello,
I'm trying to autogenerate a Python client from the published OpenAPI specs, but all the different approaches I've tried fail because due to schema validation issues:
Using
autorest
3.6.3 gives a pretty comprehensive breakdown of the issues: