From b0564d18cb66707b512521b3c5b4c8acef4a059f Mon Sep 17 00:00:00 2001 From: Arkadiusz Biel - bielu <2244074+bielu@users.noreply.github.com> Date: Sat, 10 Oct 2026 14:25:08 +0100 Subject: [PATCH] fix: use 'ws' as the WebSockets binding key The bindings spec and schema name the WebSockets binding 'ws', not 'websockets'. Co-Authored-By: Claude Sonnet 5.5 --- .../WebSockets/WebSocketsChannelBinding.cs | 2 +- .../Bindings/WebSockets/WebSocketBindings_Should.cs | 2 +- test/ByteBard.AsyncAPI.Tests/Models/AsyncApiChannel_Should.cs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ByteBard.AsyncAPI.Bindings/WebSockets/WebSocketsChannelBinding.cs b/src/ByteBard.AsyncAPI.Bindings/WebSockets/WebSocketsChannelBinding.cs index 7055634..0121d4b 100644 --- a/src/ByteBard.AsyncAPI.Bindings/WebSockets/WebSocketsChannelBinding.cs +++ b/src/ByteBard.AsyncAPI.Bindings/WebSockets/WebSocketsChannelBinding.cs @@ -23,7 +23,7 @@ public class WebSocketsChannelBinding : ChannelBinding /// public AsyncApiJsonSchema Headers { get; set; } - public override string BindingKey => "websockets"; + public override string BindingKey => "ws"; protected override FixedFieldMap FixedFieldMap => new() { diff --git a/test/ByteBard.AsyncAPI.Tests/Bindings/WebSockets/WebSocketBindings_Should.cs b/test/ByteBard.AsyncAPI.Tests/Bindings/WebSockets/WebSocketBindings_Should.cs index 1daf0d0..ef341df 100644 --- a/test/ByteBard.AsyncAPI.Tests/Bindings/WebSockets/WebSocketBindings_Should.cs +++ b/test/ByteBard.AsyncAPI.Tests/Bindings/WebSockets/WebSocketBindings_Should.cs @@ -16,7 +16,7 @@ public void V2_WebSocketChannelBinding_WithFilledObject_SerializesAndDeserialize var expected = """ bindings: - websockets: + ws: method: POST query: description: this mah query diff --git a/test/ByteBard.AsyncAPI.Tests/Models/AsyncApiChannel_Should.cs b/test/ByteBard.AsyncAPI.Tests/Models/AsyncApiChannel_Should.cs index 0e09214..24314e8 100644 --- a/test/ByteBard.AsyncAPI.Tests/Models/AsyncApiChannel_Should.cs +++ b/test/ByteBard.AsyncAPI.Tests/Models/AsyncApiChannel_Should.cs @@ -36,7 +36,7 @@ public void V2_AsyncApiChannel_WithWebSocketsBinding_Serializes() { var expected = """ bindings: - websockets: + ws: method: POST query: properties: