Skip to content

Commit 542c93f

Browse files
committed
fix: use SegmentIndetifyParams directly
1 parent 03d85fe commit 542c93f

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

packages/logging/src/analytics-helpers.ts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,15 @@ import fs from 'fs';
22
import path from 'path';
33
import type { IdentifyParams as SegmentIndetifyParams } from '@segment/analytics-node';
44

5-
export type MongoshAnalyticsIdentity = Pick<
6-
SegmentIndetifyParams,
7-
'userId' | 'anonymousId'
8-
>;
5+
export type MongoshAnalyticsIdentity = SegmentIndetifyParams;
96

107
export type AnalyticsIdentifyMessage = MongoshAnalyticsIdentity & {
118
traits: {
129
platform: string;
1310
session_id: string;
1411
device_id: string;
15-
};
16-
timestamp?: Date;
12+
} & SegmentIndetifyParams['traits'];
13+
timestamp?: Date & SegmentIndetifyParams['timestamp'];
1714
};
1815

1916
export type AnalyticsTrackMessage = MongoshAnalyticsIdentity & {

0 commit comments

Comments
 (0)