Skip to main content
Version: v1.1.1

Node

Table of contents

Constructors

Properties

Accessors

Methods

Constructors

constructor

new Node(lavashark, options)

Create a new LavaShark instance

Parameters

NameTypeDescription
lavasharkLavaSharkThe LavaShark instance
optionsNodeOptionsThe node options

Defined in

lib/Node.ts:113

Properties

options

Readonly options: NodeOptions

Defined in

lib/Node.ts:35


rest

Readonly rest: RESTManager

Defined in

lib/Node.ts:42


retryAttempts

retryAttempts: number

Defined in

lib/Node.ts:44


state

state: NodeState

Defined in

lib/Node.ts:46


stats

stats: NodeStats

Defined in

lib/Node.ts:47


version

Optional version: string

Defined in

lib/Node.ts:49

Accessors

identifier

get identifier(): string

Returns

string

Defined in

lib/Node.ts:156


totalPenalties

get totalPenalties(): number

Returns

number

Defined in

lib/Node.ts:150

Methods

connect

connect(): void

Returns

void

Defined in

lib/Node.ts:176


disconnect

disconnect(): void

Returns

void

Defined in

lib/Node.ts:205


getInfo

getInfo(): Promise<Info>

Get the Lavalink Node information

Returns

Promise<Info>

Defined in

lib/Node.ts:225


getRoutePlannerStatus

getRoutePlannerStatus(): Promise<RoutePlannerStatus>

Gets the route planner status

Returns

Promise<RoutePlannerStatus>

Defined in

lib/Node.ts:244


getStats

getStats(): Promise<NodeStats>

Get the Lavalink Node stats

Returns

Promise<NodeStats>

Defined in

lib/Node.ts:234


getVersion

getVersion(): Promise<string>

Get the Lavalink Node version

Returns

Promise<string>

Defined in

lib/Node.ts:215


unmarkAllFailedAddress

unmarkAllFailedAddress(): Promise<void>

Unmarks all failed address

Returns

Promise<void>

Defined in

lib/Node.ts:259


unmarkFailedAddress

unmarkFailedAddress(address): Promise<void>

Unmarks a failed address

Parameters

NameTypeDescription
addressstringThe address to unmark

Returns

Promise<void>

Defined in

lib/Node.ts:252


checkOptions

Static checkOptions(options): void

Parameters

NameType
optionsNodeOptions

Returns

void

Defined in

lib/Node.ts:51