Closed rahulramm closed 10 months ago
Apologies. This works correctly when array_of: Hash
is used instead of Array, of: Hash
.
Thanks for the report and adding the resolution.
Having the same issue. And array_of: Hash
doesn't work for requests, only for responses. So the issue is still relevant.
I am encountering an issue with the Swagger output when defining an array of hashes inside a hash in the response. The
items
array defined within a hash in response is being represented as an array of strings instead of an array of hashes.Here is the Apipie definition I am using:
Expected Behavior:
The 'items' array should be displayed as an array of hashes with the proper schema. Here is a screenshot of the expected output:
Actual behavior:
The Swagger output is incorrectly representing the
items
array as an array ofstring
. Here is a screenshot of the actual output:Contents in swagger file