Mermade / oas-kit

Convert Swagger 2.0 definitions to OpenAPI 3.0 and resolve/validate/lint
https://mermade.org.uk/openapi-converter
BSD 3-Clause "New" or "Revised" License
707 stars 129 forks source link

What does this error mean? > #/paths/~1v1~1action~1amend/post/parameters/3/schema, expected 'string' to be 'number' #583

Open lanxin11 opened 2 years ago

lanxin11 commented 2 years ago

Hey,

After I convert a swagger file, I wanted to use oas-validate --lint option to lint the definition. But I keep getting this error:

/paths/~1v1~1action~1amend/post/parameters/3/schema

expected 'string' to be 'number' API Reference: Billing 2022-04-21 https://rest.zuora.com

But in the corresponding parameters definition part (#/paths/~1v1~1action~1amend/post/parameters), there is no "3" in this section. Can anyone suggest what this error means?

MikeRalphson commented 2 years ago

The 3 refers to the position in the parameters array, it is 0 based, so it is the 4th parameter. Without access to the input document, I can't debug the error message further I'm afraid.