hashicorp / terraform-plugin-codegen-openapi

OpenAPI to Terraform Provider Code Generation Specification
Mozilla Public License 2.0
49 stars 6 forks source link

Add support for objects with `properties` that omit the `type` field #80

Closed austinvalle closed 8 months ago

austinvalle commented 9 months ago

Closes #79

JSON schema's specification mentions that the properties keyword applies to object. Some tools like getkin/kin-openapi may omit that type.

If a schema contains properties but doesn't define a type, we can return object as the default.

Notes

I believe based on this specification that additionalProperties aka maps should also behave this way, but we'll wait for an issue before adding that 🙂

github-actions[bot] commented 1 month ago

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.