A network packet class representing a refused connection response. It defines the Command string "ConnectionRefused" and carries an array of error messages serialized as JSON under the "errors" property.
using System.Text.Json.Serialization;
namespace APLib.Protocol.Packets;
public sealed class ConnectionRefusedPacket : APPacket
{
public override string Command => "ConnectionRefused";
[JsonPropertyName( "errors" )]
public string[] Errors { get; set; }
}