Members on this page
Meshline.Sdk
Meshline.Models.Protocol
ChannelDescriptor Class
Contains a channel's signed identity, metadata, moderation list, and lifecycle state.
public sealed record ChannelDescriptor : Meshline.Models.Protocol.TypedProtocolModel, System.IEquatable<Meshline.Models.Protocol.ChannelDescriptor>
Inheritance System.Object → ProtocolModel → TypedProtocolModel → ChannelDescriptor
Implements System.IEquatable<ChannelDescriptor>
Constructors
ChannelDescriptor() Constructor
Contains a channel's signed identity, metadata, moderation list, and lifecycle state.
public ChannelDescriptor();
Properties
ChannelDescriptor.ChannelId Property
The channel's canonical chan_ identifier.
public string ChannelId { get; init; }
Property Value
ChannelDescriptor.CreatedAt Property
The creation time, in Unix seconds.
public long CreatedAt { get; init; }
Property Value
ChannelDescriptor.Creator Property
The CAIP-10 account identifier of the resource's creator.
public string Creator { get; init; }
Property Value
ChannelDescriptor.Description Property
The optional human-readable description.
public string? Description { get; init; }
Property Value
ChannelDescriptor.DeviceSignature Property
The device signature over the model's device signing input.
public System.Collections.Immutable.ImmutableArray<byte> DeviceSignature { get; init; }
Property Value
System.Collections.Immutable.ImmutableArray<System.Byte>
ChannelDescriptor.Moderators Property
The account identifiers authorized to moderate the channel.
public System.Nullable<System.Collections.Immutable.ImmutableArray<string>> Moderators { get; init; }
Property Value
System.Nullable<System.Collections.Immutable.ImmutableArray<System.String>>
ChannelDescriptor.Name Property
The display name.
public string Name { get; init; }
Property Value
ChannelDescriptor.Nonce Property
The 16-byte creation nonce from which the channel identifier is derived.
public System.Collections.Immutable.ImmutableArray<byte> Nonce { get; init; }
Property Value
System.Collections.Immutable.ImmutableArray<System.Byte>
ChannelDescriptor.RelayId Property
The relay's lowercase Neo script hash, including the 0x prefix.
public string RelayId { get; init; }
Property Value
ChannelDescriptor.Revision Property
The monotonically increasing revision of the document.
public long Revision { get; init; }
Property Value
ChannelDescriptor.Status Property
Whether the channel is active or closed.
public Meshline.Models.Protocol.ChannelStatus Status { get; init; }
Property Value
ChannelDescriptor.UpdatedAt Property
The last update time, in Unix seconds.
public long UpdatedAt { get; init; }
Property Value
Methods
ChannelDescriptor.GetSigningInput(NetworkContext) Method
Builds the canonical, network-bound bytes used to sign or verify this document.
public byte[] GetSigningInput(Meshline.Models.NetworkContext context);
Parameters
context NetworkContext
The network context bound into identifiers or signing input.
Returns
System.Byte[]
The canonical UTF-8 signing input bound to the network context, with the applicable signature fields omitted.
Exceptions
System.Text.Json.JsonException
The signing payload cannot be represented as canonical protocol JSON, contains conflicting extension fields, or already contains a root $context property.
ChannelDescriptor.Validate(NetworkContext) Method
Validates channel metadata, member identifiers, times, status, and signature length.
public override Meshline.Validation.ProtocolViolation? Validate(Meshline.Models.NetworkContext? context);
Parameters
context NetworkContext
The required network context for identity and signature validation.
Returns
ProtocolViolation
The first detected protocol violation, or null if the implemented checks pass.
Exceptions
System.ArgumentNullException
context is null.
Remarks
These checks do not verify the external device signature or establish current signer authorization. Verify the signature and the applicable device-state or resource authorization evidence separately.