@n0tify/client
v0.0.10
Published
- connects to `socket`, `RabbitMQ`, `Kafka`, `redis` or other exchange service - dispatches message to multiple channels
Downloads
11
Readme
@n0tify/client
- connects to
socket
,RabbitMQ
,Kafka
,redis
or other exchange service - dispatches message to multiple channels
Client usage
import { Client } from '@n0tify/client';
...
const transport = ...;
const emailChannel = ...;
const client = new Client({
transport,
channels: [
emailChannel
]
});
await client.connect();
await client.send({
pattern: 'user.create',
channels: [
{
channel: 'email',
data: ...
}
],
context: {
username: 'Random username'
}
});
Further information
CLICK HERE for information about channels and transports