Socket
Book a DemoInstallSign in
Socket

dtd-analytics

Package Overview
Dependencies
Maintainers
3
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dtd-analytics

```js const analytics = require('dtd-analytics'); const info = { userType: 'serviceAccount', userId: 32, objectTypeId: 3, objectId: 24, linkObjectTypeId: 1, linkObjectId: 48, action: 'C', message: 'Your custom message', };

latest
Source
npmnpm
Version
1.1.3
Version published
Weekly downloads
6
-14.29%
Maintainers
3
Weekly downloads
 
Created
Source

Purpose

const analytics = require('dtd-analytics');
const info = {
  userType: 'serviceAccount',
  userId: 32,
  objectTypeId: 3,
  objectId: 24,
  linkObjectTypeId: 1,
  linkObjectId: 48,
  action: 'C',
  message: 'Your custom message',
};

analytics.init();
analytics.log(info);

Env configuration setup

해당 패키지에서는 기본적으로 환경변수를 이용하여, Rabbitmq 연결 정보를 받아옵니다.

// RabbitMQ
CORE_MQ_HOST: 'mq_host',
CORE_MQ_PORT: 5672,
CORE_MQ_USER: 'mq_user',
CORE_MQ_PASSWORD: 'mq_password'

환경 변수가 아닌 다른 값으로 config를 통해 접속하고 싶다면,
mqOption 을 init함수에 함께 설정할 수 있습니다.

FAQs

Package last updated on 26 Aug 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts