@mimik/event-helper

1.4.5 • Public • Published

Functions

validate()Promise

Topic inititialization and validation

sendEvent(eventType, event, ids, body, correlationId, options)Promise

Sending a event to a topic

sendEvents(eventType, event, ids, body, correlationId, options)Promise

Sending events to a topic in batch request

validate() ⇒ Promise

Topic inititialization and validation

Kind: global function
Returns: Promise - .
Category: async
Throws:

  • Promise Will throw an error if the topic is not configured.

Requires: module:@mimik/sumologic-winston-logger
Fulfil: Return null if config.topic is set to off.
Fulfil: object Return eventProcessor is config.topic is set to off or mock.

sendEvent(eventType, event, ids, body, correlationId, options) ⇒ Promise

Sending a event to a topic

Kind: global function
Returns: Promise - .
Category: async
Requires: module:@mimik/sumologic-winston-logger
Fulfil: Return null.

Param Type Description
eventType string Type of event to be sent.
event string Event to be sent.
ids object object containing id of the user.
body object body to add to the event to be sent.
correlationId string Correlation id associated with the event to be sent.
options object Options associated with the call. Use to apply metrics. Can use messageDeduplicationId, messageGroupId for fifo sns.

sendEvents(eventType, event, ids, body, correlationId, options) ⇒ Promise

Sending events to a topic in batch request

Kind: global function
Returns: Promise - .
Category: async
Requires: module:@mimik/sumologic-winston-logger
Fulfil: Return null.

Param Type Description
eventType string Type of event to be sent.
event string Event to be sent.
ids object array of id objects containing id of the users associated with the events.
body object body to add to the event to be sent.
correlationId string Correlation id associated with the events to be sent.
options object Options associated with the call. Use to apply metrics. Can use messageDeduplicationIds, messageGroupIds for fifo sns.

Readme

Keywords

Package Sidebar

Install

npm i @mimik/event-helper

Weekly Downloads

0

Version

1.4.5

License

MIT

Unpacked Size

15.6 kB

Total Files

9

Last publish

Collaborators

  • sasan.raisdana
  • miburger
  • hofachiang
  • mimik-npm-editor
  • mimikopensource