/** * Segment Node - Version 1 * Discriminator: resource=track, operation=event */ interface Credentials { segmentApi: CredentialReference; } /** Track lets you record events */ export type SegmentV1TrackEventParams = { resource: 'track'; operation: 'event'; /** * User ID */ userId?: string | Expression | PlaceholderValue; /** * Name of the action that a user has performed */ event?: string | Expression | PlaceholderValue; /** * Context * @default {} */ context?: { /** Context */ contextUi?: { /** Whether a user is active * @default false */ active?: boolean | Expression; /** Current user’s IP address */ ip?: string | Expression | PlaceholderValue; /** Locale string for the current user, for example en-US */ locate?: string | Expression | PlaceholderValue; /** Dictionary of information about the current page in the browser, containing hash, path, referrer, search, title and URL */ page?: string | Expression | PlaceholderValue; /** Timezones are sent as tzdata strings to add user timezone information which might be stripped from the timestamp, for example America/New_York */ timezone?: string | Expression | PlaceholderValue; /** App * @default {} */ app?: { /** App */ appUi?: { /** Name */ name?: string | Expression | PlaceholderValue; /** Version */ version?: string | Expression | PlaceholderValue; /** Build */ build?: string | Expression | PlaceholderValue; }; }; /** Campaign * @default {} */ campaign?: { /** Campaign */ campaignUi?: { /** Name */ name?: string | Expression | PlaceholderValue; /** Source */ source?: string | Expression | PlaceholderValue; /** Medium */ medium?: string | Expression | PlaceholderValue; /** Term */ term?: string | Expression | PlaceholderValue; /** Content */ content?: string | Expression | PlaceholderValue; }; }; /** Device * @default {} */ device?: { /** Device */ deviceUi?: { /** ID */ id?: string | Expression | PlaceholderValue; /** Manufacturer */ manufacturer?: string | Expression | PlaceholderValue; /** Model */ model?: string | Expression | PlaceholderValue; /** Name */ name?: string | Expression | PlaceholderValue; /** Type */ type?: string | Expression | PlaceholderValue; /** Version */ version?: string | Expression | PlaceholderValue; }; }; }; }; /** * Integration * @default {} */ integrations?: { /** Integration */ integrationsUi?: { /** All * @default true */ all?: boolean | Expression; /** Salesforce * @default false */ salesforce?: boolean | Expression; }; }; /** * Properties * @default {} */ properties?: { /** Property */ propertiesUi?: Array<{ /** Key */ key?: string | Expression | PlaceholderValue; /** Value */ value?: string | Expression | PlaceholderValue; }>; }; }; export type SegmentV1TrackEventOutput = { success?: boolean; }; export type SegmentV1TrackEventNode = { type: 'n8n-nodes-base.segment'; version: 1; credentials?: Credentials; config: NodeConfig; output?: Items; };