mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-07-01 07:40:10 +00:00
Fixed missing/inaccurate properties in analytics-node
This commit is contained in:
20
types/analytics-node/index.d.ts
vendored
20
types/analytics-node/index.d.ts
vendored
@@ -22,8 +22,8 @@ declare namespace AnalyticsNode {
|
||||
},
|
||||
timestamp?: Date;
|
||||
messageId?: string;
|
||||
anonymousId: string | number;
|
||||
userId: string | number;
|
||||
anonymousId?: string | number;
|
||||
userId?: string | number;
|
||||
}
|
||||
|
||||
interface Data {
|
||||
@@ -47,7 +47,8 @@ declare namespace AnalyticsNode {
|
||||
/* The identify method lets you tie a user to their actions and record
|
||||
traits about them. */
|
||||
identify(message: {
|
||||
userId: string | number;
|
||||
userId?: string | number;
|
||||
anonymousId?: string | number;
|
||||
traits?: Object;
|
||||
timestamp?: Date;
|
||||
context?: Object;
|
||||
@@ -56,7 +57,8 @@ declare namespace AnalyticsNode {
|
||||
|
||||
/* The track method lets you record the actions your users perform. */
|
||||
track(message: {
|
||||
userId: string | number;
|
||||
userId?: string | number;
|
||||
anonymousId?: string | number;
|
||||
event: string;
|
||||
properties?: Object;
|
||||
timestamp?: Date;
|
||||
@@ -67,7 +69,8 @@ declare namespace AnalyticsNode {
|
||||
/* The page method lets you record page views on your website, along with
|
||||
optional extra information about the page being viewed. */
|
||||
page(message: {
|
||||
userId: string | number;
|
||||
userId?: string | number;
|
||||
anonymousId?: string | number;
|
||||
category?: string;
|
||||
name?: string;
|
||||
properties?: Object;
|
||||
@@ -79,19 +82,20 @@ declare namespace AnalyticsNode {
|
||||
/* alias is how you associate one identity with another. */
|
||||
alias(message: {
|
||||
previousId: string | number;
|
||||
userId: string | number;
|
||||
userId?: string | number;
|
||||
anonymousId?: string | number;
|
||||
integrations?: Integrations;
|
||||
}, callback?: (err: Error, data: Data) => void): Analytics;
|
||||
|
||||
/* Group calls can be used to associate individual users with shared
|
||||
accounts or companies. */
|
||||
group(message: {
|
||||
userId: string | number;
|
||||
userId?: string | number;
|
||||
anonymousId?: string | number;
|
||||
groupId: string | number;
|
||||
traits?: Object;
|
||||
context?: Object;
|
||||
timestamp?: Date;
|
||||
anonymous_id?: string | number;
|
||||
integrations?: Integrations;
|
||||
}, callback?: (err: Error, data: Data) => void): Analytics;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user