mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-26 05:04:05 -08:00
63b6c9f128
* ✏️ Alphabetize rules * 🔖 Update version * ⚡ Update lintfix command * ⚡ Run baseline lintfix * 📦 Update package-lock.json * 👕 Apply `node-param-description-untrimmed` (#3200) * Removing unneeded backticks (#3249) * 👕 Apply node-param-description-wrong-for-return-all (#3253) * 👕 Apply node-param-description-missing-limit (#3252) Co-authored-by: Iván Ovejero <ivov.src@gmail.com> * 👕 Apply node-param-description-excess-final-period (#3250) Co-authored-by: Iván Ovejero <ivov.src@gmail.com> * 👕 Apply node-param-description-unencoded-angle-brackets (#3256) Co-authored-by: Iván Ovejero <ivov.src@gmail.com> * 👕 Apply node-param-description-url-missing-protocol (#3258) * 👕 Apply `node-param-description-miscased-id` (#3254) Co-authored-by: Iván Ovejero <ivov.src@gmail.com> * 👕 Apply node-param-description-wrong-for-limit (#3257) Co-authored-by: Iván Ovejero <ivov.src@gmail.com> * 👕 Apply node-param-description-wrong-for-ignore-ssl-issues (#3261) * 👕 Apply rule * ⚡ Restore lintfix script * ⚡ Restore lintfix script Co-authored-by: agobrech <45268029+agobrech@users.noreply.github.com> Co-authored-by: Omar Ajoue <krynble@gmail.com> Co-authored-by: Michael Kret <88898367+michael-radency@users.noreply.github.com>
241 lines
4.2 KiB
TypeScript
241 lines
4.2 KiB
TypeScript
import { INodeProperties } from 'n8n-workflow';
|
|
|
|
export const eventOperations: INodeProperties[] = [
|
|
{
|
|
displayName: 'Operation',
|
|
name: 'operation',
|
|
type: 'options',
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
},
|
|
},
|
|
options: [
|
|
{
|
|
name: 'Track',
|
|
value: 'track',
|
|
description: 'Track an event for a specific customer',
|
|
},
|
|
],
|
|
default: 'track',
|
|
description: 'The operation to perform.',
|
|
},
|
|
];
|
|
|
|
export const eventFields: INodeProperties[] = [
|
|
|
|
/* -------------------------------------------------------------------------- */
|
|
/* event:track */
|
|
/* -------------------------------------------------------------------------- */
|
|
|
|
{
|
|
displayName: 'ID',
|
|
name: 'id',
|
|
type: 'string',
|
|
required: true,
|
|
default: '',
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
operation: [
|
|
'track',
|
|
],
|
|
},
|
|
},
|
|
description: 'The unique identifier of the customer',
|
|
},
|
|
{
|
|
displayName: 'Email',
|
|
name: 'email',
|
|
type: 'string',
|
|
default: '',
|
|
required: true,
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
operation: [
|
|
'track',
|
|
],
|
|
},
|
|
},
|
|
},
|
|
{
|
|
displayName: 'Event Name',
|
|
name: 'eventName',
|
|
type: 'string',
|
|
default: '',
|
|
required: true,
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
operation: [
|
|
'track',
|
|
],
|
|
},
|
|
},
|
|
description: 'The name of the event tracked',
|
|
},
|
|
{
|
|
displayName: 'JSON Parameters',
|
|
name: 'jsonParameters',
|
|
type: 'boolean',
|
|
default: false,
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
operation: [
|
|
'track',
|
|
],
|
|
},
|
|
},
|
|
},
|
|
{
|
|
displayName: 'Data',
|
|
name: 'dataAttributesUi',
|
|
placeholder: 'Add Data',
|
|
description: 'key value pairs that represent any properties you want to track with this event',
|
|
type: 'fixedCollection',
|
|
typeOptions: {
|
|
multipleValues: true,
|
|
},
|
|
default: {},
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
operation: [
|
|
'track',
|
|
],
|
|
jsonParameters: [
|
|
false,
|
|
],
|
|
},
|
|
},
|
|
options: [
|
|
{
|
|
name: 'dataAttributesValues',
|
|
displayName: 'Data',
|
|
values: [
|
|
{
|
|
displayName: 'Key',
|
|
name: 'key',
|
|
type: 'string',
|
|
default: '',
|
|
description: 'Name of the property to set',
|
|
},
|
|
{
|
|
displayName: 'Value',
|
|
name: 'value',
|
|
type: 'string',
|
|
default: '',
|
|
description: 'Value of the property to set',
|
|
},
|
|
],
|
|
},
|
|
],
|
|
},
|
|
{
|
|
displayName: 'Extra',
|
|
name: 'extraAttributesUi',
|
|
placeholder: 'Add Extra',
|
|
description: 'Key value pairs that represent reserved, Vero-specific operators. Refer to the note on “deduplication” below.',
|
|
type: 'fixedCollection',
|
|
typeOptions: {
|
|
multipleValues: true,
|
|
},
|
|
default: {},
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
operation: [
|
|
'track',
|
|
],
|
|
jsonParameters: [
|
|
false,
|
|
],
|
|
},
|
|
},
|
|
options: [
|
|
{
|
|
name: 'extraAttributesValues',
|
|
displayName: 'Extra',
|
|
values: [
|
|
{
|
|
displayName: 'Key',
|
|
name: 'key',
|
|
type: 'string',
|
|
default: '',
|
|
description: 'Name of the property to set',
|
|
},
|
|
{
|
|
displayName: 'Value',
|
|
name: 'value',
|
|
type: 'string',
|
|
default: '',
|
|
description: 'Value of the property to set',
|
|
},
|
|
],
|
|
},
|
|
],
|
|
},
|
|
{
|
|
displayName: 'Data',
|
|
name: 'dataAttributesJson',
|
|
type: 'json',
|
|
default: '',
|
|
typeOptions: {
|
|
alwaysOpenEditWindow: true,
|
|
},
|
|
description: 'key value pairs that represent the custom user properties you want to update',
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
operation: [
|
|
'track',
|
|
],
|
|
jsonParameters: [
|
|
true,
|
|
],
|
|
},
|
|
},
|
|
},
|
|
{
|
|
displayName: 'Extra',
|
|
name: 'extraAttributesJson',
|
|
type: 'json',
|
|
default: '',
|
|
typeOptions: {
|
|
alwaysOpenEditWindow: true,
|
|
},
|
|
description: 'Key value pairs that represent reserved, Vero-specific operators. Refer to the note on “deduplication” below.',
|
|
displayOptions: {
|
|
show: {
|
|
resource: [
|
|
'event',
|
|
],
|
|
operation: [
|
|
'track',
|
|
],
|
|
jsonParameters: [
|
|
true,
|
|
],
|
|
},
|
|
},
|
|
},
|
|
];
|