KubeMQ
Client SDKsNode.jsReference

Client

Factory, connection lifecycle — KubeMQ Node.js SDK reference.

The Node.js SDK centers on KubeMQClient, created through an async factory. Connections are Promise-based and pair with TypeScript definitions for every public method.

Package

npm install kubemq-js

Requires Node.js 20+. Ships compiled JavaScript with .d.ts declarations.

Factory

create

const client = await KubeMQClient.create(options: ClientOptions): Promise<KubeMQClient>

Parameters:

NameTypeRequiredDescription
optionsClientOptionsYesAddress, TLS, auth token, timeouts, client ID

Returns: Promise<KubeMQClient> — connected client.

Throws: KubeMQError — connection, TLS, or validation failures.

Close

await client.close(): Promise<void>

Gracefully shuts down streams and the gRPC channel.

Quick Usage

client.ts
import { KubeMQClient } from "kubemq-js";

const client = await KubeMQClient.create({
  address: "localhost:50000",
  clientId: "node-demo",
});

await client.close();

See Also

Was this page helpful?

On this page