<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: 15.0.0 -",
    "macOS: 12.0.0 -",
    "tvOS: 15.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 8.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Network",
  "identifier" : "/documentation/Network/NWProtocolQUIC/Metadata",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "Network"
    ],
    "preciseIdentifier" : "s:7Network14NWProtocolQUICC8MetadataC"
  },
  "title" : "NWProtocolQUIC.Metadata"
}
-->

# NWProtocolQUIC.Metadata

A handle you can use to inspect a connection’s QUIC state.

```
class Metadata
```

## Topics

### Inspecting Connection State

[`var negotiatedALPN: String?`](/documentation/Network/NWProtocolQUIC/Metadata/negotiatedALPN)

The Application-Layer Protocol Negotiation value used when establishing the connection.

[`var localMaxStreamsBidirectional: Int`](/documentation/Network/NWProtocolQUIC/Metadata/localMaxStreamsBidirectional)

The maximum number of bidirectional streams that the peer can create on a QUIC connection.

[`var localMaxStreamsUnidirectional: Int`](/documentation/Network/NWProtocolQUIC/Metadata/localMaxStreamsUnidirectional)

The maximum number of unidirectional streams that the peer can create on a QUIC connection.

[`var remoteMaxStreamsBidirectional: Int`](/documentation/Network/NWProtocolQUIC/Metadata/remoteMaxStreamsBidirectional)

The maximum number of bidirectional streams advertised by peer that the connection is allowed to create.

[`var remoteMaxStreamsUnidirectional: Int`](/documentation/Network/NWProtocolQUIC/Metadata/remoteMaxStreamsUnidirectional)

The maximum number of unidirectional streams advertised by peer that the connection is allowed to create.

[`var remoteIdleTimeout: Int`](/documentation/Network/NWProtocolQUIC/Metadata/remoteIdleTimeout)

The idle timeout value from the peer’s transport parameters, in milliseconds.

[`var securityProtocolMetadata: sec_protocol_metadata_t`](/documentation/Network/NWProtocolQUIC/Metadata/securityProtocolMetadata)

The result of the QUIC handshake.

### Inspecting Stream State

[`var streamIdentifier: UInt64`](/documentation/Network/NWProtocolQUIC/Metadata/streamIdentifier)

The QUIC stream identifier.

[`var usableDatagramFrameSize: Int`](/documentation/Network/NWProtocolQUIC/Metadata/usableDatagramFrameSize)

The maximum usable size of a datagram frame on a QUIC datagram flow.

### Handling Errors

[`var applicationError: NWProtocolQUIC.ApplicationError`](/documentation/Network/NWProtocolQUIC/Metadata/applicationError)

The QUIC application error code to send for the connection, or received from the peer.

[`struct ApplicationError`](/documentation/Network/NWProtocolQUIC/ApplicationError)

A QUIC application error code.

[`var streamApplicationErrorCode: UInt64`](/documentation/Network/NWProtocolQUIC/Metadata/streamApplicationErrorCode)

The QUIC application error code to send for the stream, or received from the peer.

### Configuring Keepalives

[`var keepAlive: NWProtocolQUIC.Metadata.KeepAliveBehavior`](/documentation/Network/NWProtocolQUIC/Metadata/keepAlive)

The QUIC connection keepalive behavior.

[`enum KeepAliveBehavior`](/documentation/Network/NWProtocolQUIC/Metadata/KeepAliveBehavior)

A QUIC connection keepalive behavior.

## Relationships

### Conforms To

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`Sendable`](/documentation/Swift/Sendable)

### Inherits From

[`NWProtocolMetadata`](/documentation/Network/NWProtocolMetadata)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)