Client API Reference

The main class for managing nodes. side note: to make connection must be use Lavalink.create_node() or Lavalink.destroy_node().

create_node(host: str, port: int, password: str, user_id: int, *, name: Optional[str] = None, shard_count: Optional[int] = None, ssl: bool = False, resume_key: Optional[str] = None, resume_timeout: Optional[int] = None, loop: Optional[AbstractEventLoop] = None) Node[source]

Create a node for lavalink.

Parameters

host: str

ip address for lavalink server, default ip address for lavalink is `

port: int

The port to use for websocket and REST connections.

password: str

The password used for authentication.

name: str

The name for the node.

shard_count: int

The shard count for the node.

ssl: bool

Is server using ssl

resume_key: str

The resume key for the node.

resume_timeout: int

The resume timeout for the node.

loop: asyncio.AbstractEventLoop

The event loop for the node.

destroy_node(node: Node)[source]

Destroy a node for lavalink.

Parameters

node: Node

The node to destroy.

property nodes: List[Node]

A list of nodes.

property default_node: Node

The default node.