Table of Contents

Namespace NATS.Client.Core

Classes

NatsAuthOpts
NatsBufferWriter<T>

Represents a heap-based, array-backed output sink into which T data can be written.

NatsConnection
NatsConnectionFailedException
NatsConnectionPool
NatsDefaultSerializerRegistry
NatsDefaultSerializer<T>

Default serializer for NATS messages.

NatsDeserializeException
NatsEventArgs
NatsException
NatsHeaderParseException
NatsHeaderParser
NatsHeaders

Represents a wrapper for RequestHeaders and ResponseHeaders.

NatsInstrumentationOptions

Options for the OpenTelemetry instrumentation.

NatsJsonContextSerializerRegistry
NatsJsonContextSerializer<T>

Serializer with support for JsonSerializerContext.

NatsLameDuckModeActivatedEventArgs
NatsLogEvents
NatsMessageDroppedEventArgs
NatsMsgBuilder<T>

Builder class for creating NatsMsg<T>

NatsMsgTelemetryExtensions
NatsNoReplyException
NatsNoRespondersException
NatsOpts

Immutable options for NatsConnection, you can configure via with operator.

NatsOptsExtensions
NatsPayloadTooLargeException
NatsProtocolViolationException
NatsPubOpts
NatsRawSerializer<T>

Serializer for binary data.

NatsRequestExtensions
NatsRequestManyExtensions
NatsSerializationExtensions

Extension methods to support context-aware serialization with fallback to standard serialization.

NatsSerializerBuilder<T>

Represents a builder for creating a chain of serializers for NATS messages.

NatsServerErrorEventArgs
NatsServerException
NatsSlowConsumerEventArgs
NatsSubBase

The base class for NATS subscriptions.

NatsSubChannelOpts

Options For setting the FullMode and Capacity for a the Channel created for Subscriptions

NatsSubException
NatsSubOpts
NatsSub<T>
NatsTelemetry

Telemetry identifiers for NATS .NET. Use these when configuring OpenTelemetry or any other listener directly. The same name is used for both the ActivitySource and the Meter.

NatsTimeoutException
NatsTlsOpts

Immutable options for TlsOptions, you can configure via with operator. These options are ignored in WebSocket connections

NatsUtf8PrimitivesSerializer<T>

UTF8 serializer for strings and all the primitives.

NatsWebSocketOpts

Options for ClientWebSocketOptions

Nuid

Represents a unique identifier generator.

SslClientAuthenticationOptions

Structs

NatsAuthCred
NatsHeaders.Enumerator

Enumerates a NatsHeaders.

NatsInstrumentationContext
NatsMemoryOwner<T>

An IMemoryOwner<T> implementation with an embedded length and a fast Span<T> accessor.

NatsMsgContext

Provides message envelope metadata available during serialization and deserialization.

NatsMsg<T>

NATS message structure as defined by the protocol.

NatsResult
NatsResult<T>
NatsStats

Interfaces

INatsClient
INatsConnection
INatsConnectionPool
INatsDeserializeWithContext<T>

Extended deserializer interface with access to message context during deserialization.

INatsDeserialize<T>

Deserializer interface for NATS messages.

INatsHeaders

Represents NATS message headers as a dictionary of string keys and StringValues values.

INatsMsg

Shared contract for all NATS message types.

INatsMsg<T>

This interface provides an optional contract when passing messages to processing methods which is usually helpful in creating test doubles in unit testing.

INatsSerializeWithContext<T>

Extended serializer interface with access to message context during serialization.

INatsSerialize<T>

Serializer interface for NATS messages.

INatsSerializerRegistry

Registry for serializers and deserializers.

INatsSerializerWithContext<T>

Combined context-aware serializer interface that supports both serialization and deserialization with access to message context.

INatsSerializer<T>

Serializer interface for NATS messages.

INatsServerInfo
INatsSocketConnection

Represents a socket connection to a NATS server.

INatsSocketConnectionFactory

Factory interface for creating socket connections to NATS servers.

INatsSub<T>
INatsSubscriptionManager

Subscription manager interface.

INatsTlsUpgradeableSocketConnection

Represents a NATS socket connection that can be upgraded to use TLS.

ISocketConnection

Obsolete, use INatsSocketConnection instead

Enums

NatsConnectionState
NatsHeaders.Messages
NatsMemoryOwnerAllocationMode

An enum that indicates a mode to use when allocating buffers.

NatsMsgFlags
NatsRequestReplyMode

Specifies the modes for handling request-reply interactions in NATS.

NatsServerErrorKind
NatsSubEndReason
TlsMode

TLS mode to use during connection.

Delegates

AsyncEventHandler

An asynchronous event handler.

AsyncEventHandler<TEventArgs>

An asynchronous event handler.