@xyndata/nodejs-connector
TypeScript icon, indicating that this package has built-in type declarations

0.1.19 • Public • Published

Node.js nats connector for nestjs apps

This is ready-made nats connection to nestjs apps with API to internal endpoints.

How to use

const client = new ClientNats({
    url: 'nats://localhost:4222',
});

client.connect().then(async () => {
    console.log('nats has been connected..');

    const notificationNode = new NotificationNode(client, 5000); // 5000 is timeout in ms
    await notificationNode.sendCompanyRegistrationEmail({
        emailTo: "foo@cybernetix.de",
        language: "de", 
        spaceName: "foo", 
        username: "bar"
    });
})

Readme

Keywords

none

Package Sidebar

Install

npm i @xyndata/nodejs-connector

Weekly Downloads

0

Version

0.1.19

License

none

Unpacked Size

113 kB

Total Files

30

Last publish

Collaborators

  • haris-xyndata
  • ptesar