forked from microsoft/OpenAPI.NET
-
Notifications
You must be signed in to change notification settings - Fork 0
Add deprecated field to SecurityScheme for OpenAPI 3.2.0 #27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
baywet
merged 6 commits into
feat/oai-3-2-support
from
copilot/fix-b37e3c64-4c57-4b84-a718-452893b94d3f
Sep 30, 2025
Merged
Add deprecated field to SecurityScheme for OpenAPI 3.2.0 #27
baywet
merged 6 commits into
feat/oai-3-2-support
from
copilot/fix-b37e3c64-4c57-4b84-a718-452893b94d3f
Sep 30, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ization Co-authored-by: baywet <[email protected]>
Co-authored-by: baywet <[email protected]>
Copilot finished work on behalf of
baywet
September 30, 2025 01:27
kilifu
approved these changes
Sep 30, 2025
baywet
requested changes
Sep 30, 2025
.../Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiSecuritySchemeReferenceDeserializerTests.cs
Outdated
Show resolved
Hide resolved
src/Microsoft.OpenApi/Reader/V31/OpenApiSecuritySchemeDeserializer.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.OpenApi.Tests/Models/OpenApiSecuritySchemeTests.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.OpenApi.Tests/Models/OpenApiSecuritySchemeTests.cs
Outdated
Show resolved
Hide resolved
test/Microsoft.OpenApi.Tests/Models/OpenApiSecuritySchemeTests.cs
Outdated
Show resolved
Hide resolved
baywet
approved these changes
Sep 30, 2025
@copilot run the following commands |
Copilot finished work on behalf of
baywet
September 30, 2025 13:42
baywet
approved these changes
Sep 30, 2025
2e42719
to
269181b
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Successfully implemented the
deprecated
field for OpenAPI SecurityScheme as specified in OpenAPI 3.2.0 specification.Changes Made
✅ Core Implementation
Deprecated
property toIOpenApiSecurityScheme
interfaceDeprecated
property toOpenApiSecurityScheme
classDeprecated
property toOpenApiSecuritySchemeReference
classOpenApiSecurityScheme
copy constructor to includeDeprecated
✅ Serialization
deprecated: true
fieldx-oai-deprecated: true
extensionx-oai-deprecated: true
extension✅ Deserialization
deprecated
fieldx-oai-deprecated
extension ANDdeprecated
field (forward compatibility)x-oai-deprecated
extension✅ Testing
JsonNode.DeepEquals
for better comparison✅ Public API
✅ Performance
Verified Behavior
The implementation correctly handles:
deprecated
field per specx-oai-
prefix extension for backward compatibilityfalse
(only serialized whentrue
)Original prompt
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.