When parsing an OpenAPI 3.1.0 document with extensions in the info.contact object, the library removes the extensions under info.contact. This results in loss of custom metadata that is intended to be retained for various use cases.
Expected Behavior
According to the OpenAPI 3.1.0 specification, it is valid to use extensions (properties starting with x-) within the info.contact object. The library should correctly parse and retain these extensions.
Example of a valid OpenAPI 3.1 document:
openapi: 3.1.0
info:
title: Sample API
version: 1.0.0
contact:
name: API Support
x-custom-extension: "Custom Extension Value"
paths: {}
Steps to Reproduce
Create an OpenAPI 3.1.0 document that includes extensions within the info.contact object.
Use the library to parse the OpenAPI document.
Observe that the extensions are missing in the parsed output.
Current Behavior
When parsing an OpenAPI 3.1.0 document with extensions in the
info.contact
object, the library removes the extensions underinfo.contact
. This results in loss of custom metadata that is intended to be retained for various use cases.Expected Behavior
According to the OpenAPI 3.1.0 specification, it is valid to use extensions (properties starting with
x-
) within theinfo.contact
object. The library should correctly parse and retain these extensions.Example of a valid OpenAPI 3.1 document:
Steps to Reproduce
info.contact
object.Example Code
The output.yaml does not contain
x-
properties underinfo.contact
Environment