Interface: ConnectOptions<E>
Defined in: netconf/src/client.ts:97
What connect takes: the transport, plus options that shape the session. Only transport is required. See Session options.
Extended by
Type Parameters
E
E extends readonly Extension[] = readonly Extension[]
Properties
capabilities?
readonly capabilities?: readonly string[];Defined in: netconf/src/client.ts:101
Capabilities to advertise in addition to base:1.0 and base:1.1.
capabilityCheck?
readonly capabilityCheck?: CapabilityCheck;Defined in: netconf/src/client.ts:123
How operations are checked against the server's capabilities before sending. Default 'strict'.
extensionCheck?
readonly extensionCheck?: CapabilityCheck;Defined in: netconf/src/client.ts:130
How each enabled extension's required capabilities are checked after the hello. Default: the same as capabilityCheck. 'off' enables every module whatever the server advertises, so tools can list them all, while each operation is still checked under capabilityCheck.
extensions?
readonly extensions?: E;Defined in: netconf/src/client.ts:172
Extensions to enable, such as withDefaults from @node-net/netconf/operations/with-defaults. Each is reached as client.ops.<id> and/or client.content.<id>, for the layers it contributes to, and its required capabilities are checked after the hello (extensionCheck).
logger?
readonly logger?: Logger;Defined in: netconf/src/client.ts:136
Where the client logs: anything with some of trace, debug, info, warn and error methods, such as console. Default: no logging. Change it later with client.setLogger(). See Logging and tracing.
logLevel?
readonly logLevel?: "trace" | "debug" | "info" | "warn" | "error" | "silent";Defined in: netconf/src/client.ts:142
Least severe level passed to the logger: 'trace', 'debug', 'info', 'warn', 'error' or 'silent'. Default 'trace': everything the logger has a method for. Change it later with client.setLogLevel().
maxInFlight?
readonly maxInFlight?: number;Defined in: netconf/src/client.ts:105
Most RPCs awaiting a reply at once; later ones queue. Default 32.
maxMessageBytes?
readonly maxMessageBytes?: number;Defined in: netconf/src/client.ts:114
Largest message accepted from the server, in bytes of the message itself (not counting chunk headers or the end-of-message delimiter). A larger message is refused as soon as the limit is passed, and closes the session with a FramingError. However the message is chunked, the client holds at most about twice this for it while it arrives, plus one copy when it is handed on. Default 64 MiB.
namespaces?
readonly namespaces?: Readonly<Record<string, string>>;Defined in: netconf/src/client.ts:158
Module name → namespace, for modules the server doesn't advertise or advertises wrongly. Beats the device profile's namespaces, which beat the server's hello and YANG library.
parseLimits?
readonly parseLimits?: XmlParseLimits;Defined in: netconf/src/client.ts:121
Depth and node limits applied to every message received, checked before the message is parsed; see XmlParseLimits for what they bound. A message over a limit closes the session with an XmlError. Default DEFAULT_PARSE_LIMITS: depth 256, 1,000,000 nodes.
profile?
readonly profile?: DeviceProfile | AutoDetect;Defined in: netconf/src/client.ts:152
The device profile to use: a profile, or autoDetect([...]) to choose one from the server's hello. client.profile is the profile in use. Quirks that affect the hello (forceBaseVersion) need an explicit profile.
redact?
readonly redact?: (xml) => string;Defined in: netconf/src/client.ts:144
Applied to message bodies before trace logging and the session's message event. Default: mask password-like elements.
Parameters
xml
string
Returns
string
signal?
readonly signal?: AbortSignal;Defined in: netconf/src/client.ts:146
Aborts connecting (connection and hello).
timeouts?
readonly timeouts?: Timeouts;Defined in: netconf/src/client.ts:103
Timeouts for connecting, the hello, each RPC and closing, in ms. Defaults: DEFAULT_TIMEOUTS.
transport
readonly transport: ConnectionFactory;Defined in: netconf/src/client.ts:99
How to reach the server: a ConnectionFactory such as ssh({ ... }) or tls({ ... }).
yang?
readonly yang?: YangOptions;Defined in: netconf/src/client.ts:164
YANG schemas for RFC 7951 JSON output (format: 'json' on reads): modules to use before the bundled IETF ones and <get-schema>, whether to refuse a schema-less conversion, and a cache to share between clients.