n8n-nodes-mautic-advanced 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +103 -0
- package/dist/credentials/MauticAdvancedApi.credentials.js +50 -0
- package/dist/credentials/MauticAdvancedOAuth2Api.credentials.js +59 -0
- package/dist/nodes/MauticAdvanced/CampaignContactDescription.js +66 -0
- package/dist/nodes/MauticAdvanced/CampaignDescription.js +422 -0
- package/dist/nodes/MauticAdvanced/CategoryDescription.js +308 -0
- package/dist/nodes/MauticAdvanced/CompanyContactDescription.js +62 -0
- package/dist/nodes/MauticAdvanced/CompanyDescription.js +609 -0
- package/dist/nodes/MauticAdvanced/ContactDescription.js +1656 -0
- package/dist/nodes/MauticAdvanced/ContactSegmentDescription.js +66 -0
- package/dist/nodes/MauticAdvanced/GenericFunctions.js +71 -0
- package/dist/nodes/MauticAdvanced/MauticAdvanced.node.js +1074 -0
- package/dist/nodes/MauticAdvanced/MauticAdvanced.svg +1 -0
- package/dist/nodes/MauticAdvanced/MauticAdvancedTrigger.node.js +171 -0
- package/dist/nodes/MauticAdvanced/SegmentEmailDescription.js +46 -0
- package/dist/nodes/MauticAdvanced/TagDescription.js +260 -0
- package/package.json +67 -0
package/README.md
ADDED
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
# n8n Mautic Advanced Node
|
|
2
|
+
|
|
3
|
+
[](https://buymeacoffee.com/msoukhomlinov)
|
|
4
|
+
|
|
5
|
+
This project is an enhanced Mautic node for n8n, designed to provide more comprehensive support for the Mautic API. It builds upon the standard Mautic node by adding new resources and operations.
|
|
6
|
+
|
|
7
|
+
## What Makes This "Advanced"?
|
|
8
|
+
|
|
9
|
+
This enhanced version extends the standard n8n Mautic node with:
|
|
10
|
+
|
|
11
|
+
- **🏷️ Complete Tag Management**: Full CRUD operations for tags (missing in the standard node)
|
|
12
|
+
- **📊 Campaign Operations**: Create, clone, update, and manage campaigns
|
|
13
|
+
- **📁 Category Management**: Handle categories with bundle and color support
|
|
14
|
+
- **🔗 Advanced Relationship Management**: Sophisticated contact-to-campaign and contact-to-company associations
|
|
15
|
+
- **📧 Enhanced Email Operations**: Segment-based email sending capabilities
|
|
16
|
+
- **👥 Extended Contact Operations**: UTM tag management, activity tracking, device information, and notes
|
|
17
|
+
- **🏢 Complete Company Management**: Full company lifecycle with custom fields and address support
|
|
18
|
+
|
|
19
|
+
All resources support comprehensive filtering, pagination, and custom field management where applicable.
|
|
20
|
+
|
|
21
|
+
## Supported Resources and Operations
|
|
22
|
+
|
|
23
|
+
This enhanced Mautic node provides comprehensive support for the following Mautic API resources:
|
|
24
|
+
|
|
25
|
+
### 🏢 Companies
|
|
26
|
+
- **Create** a new company with full address and custom field support
|
|
27
|
+
- **Get** a company by ID
|
|
28
|
+
- **Get Many** companies with filtering and pagination
|
|
29
|
+
- **Update** company details
|
|
30
|
+
- **Delete** a company
|
|
31
|
+
|
|
32
|
+
### 👥 Contacts (Enhanced)
|
|
33
|
+
- **Create** a new contact with extensive field options
|
|
34
|
+
- **Get** a contact by ID
|
|
35
|
+
- **Get Many** contacts with advanced filtering
|
|
36
|
+
- **Update** contact details
|
|
37
|
+
- **Delete** a contact
|
|
38
|
+
- **Send Email** to a contact
|
|
39
|
+
- **Edit Contact Points** (add/subtract points)
|
|
40
|
+
- **Edit Do Not Contact List** (add/remove from DNC)
|
|
41
|
+
- **Add/Remove UTM Tags** for tracking
|
|
42
|
+
- **Get Notes** associated with a contact
|
|
43
|
+
- **Get Activity** history for a contact
|
|
44
|
+
- **Get Companies** associated with a contact
|
|
45
|
+
- **Get Devices** used by a contact
|
|
46
|
+
|
|
47
|
+
### 🏷️ Tags
|
|
48
|
+
- **Create** a new tag with description
|
|
49
|
+
- **Get** a tag by ID
|
|
50
|
+
- **Get Many** tags with search capabilities
|
|
51
|
+
- **Update** tag name and description
|
|
52
|
+
- **Delete** a tag
|
|
53
|
+
|
|
54
|
+
### 📊 Campaigns
|
|
55
|
+
- **Create** a new campaign
|
|
56
|
+
- **Get** a campaign by ID
|
|
57
|
+
- **Get All** campaigns
|
|
58
|
+
- **Update** campaign details
|
|
59
|
+
- **Delete** a campaign
|
|
60
|
+
- **Clone** an existing campaign
|
|
61
|
+
- **Get Contacts** in a campaign
|
|
62
|
+
|
|
63
|
+
### 📁 Categories
|
|
64
|
+
- **Create** a new category with bundle and color settings
|
|
65
|
+
- **Get** a category by ID
|
|
66
|
+
- **Get Many** categories
|
|
67
|
+
- **Update** category details
|
|
68
|
+
- **Delete** a category
|
|
69
|
+
|
|
70
|
+
### 🔗 Relationship Management
|
|
71
|
+
- **Campaign Contact**: Add/remove contacts to/from campaigns
|
|
72
|
+
- **Company Contact**: Add/remove contacts to/from companies
|
|
73
|
+
- **Contact Segment**: Add/remove contacts to/from segments
|
|
74
|
+
|
|
75
|
+
### 📧 Email Operations
|
|
76
|
+
- **Segment Email**: Send emails to segments
|
|
77
|
+
|
|
78
|
+
## Installation
|
|
79
|
+
|
|
80
|
+
To use this node, you will need to clone this repository and link it to your n8n instance.
|
|
81
|
+
|
|
82
|
+
1. Clone this repository.
|
|
83
|
+
2. Run `npm install` in the project root.
|
|
84
|
+
3. Run `npm run build` to compile the TypeScript code.
|
|
85
|
+
4. Link the node to your n8n installation by running `npm link` in the project root, and then `npm link n8n-nodes-mautic-advanced` in your n8n installation directory.
|
|
86
|
+
|
|
87
|
+
## Development
|
|
88
|
+
|
|
89
|
+
- `npm run dev`: To watch for changes and automatically recompile.
|
|
90
|
+
- `npm run lint`: To check for linting errors.
|
|
91
|
+
- `npm run format`: To format the code with Prettier.
|
|
92
|
+
|
|
93
|
+
## Support
|
|
94
|
+
|
|
95
|
+
If you find this node helpful and want to support its ongoing development, you can buy me a coffee:
|
|
96
|
+
|
|
97
|
+
[](https://buymeacoffee.com/msoukhomlinov)
|
|
98
|
+
|
|
99
|
+
Your support helps maintain this project and develop new features.
|
|
100
|
+
|
|
101
|
+
## License
|
|
102
|
+
|
|
103
|
+
MIT License
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MauticAdvancedApi = void 0;
|
|
4
|
+
class MauticAdvancedApi {
|
|
5
|
+
constructor() {
|
|
6
|
+
this.name = 'mauticAdvancedApi';
|
|
7
|
+
this.displayName = 'Mautic Advanced API';
|
|
8
|
+
this.documentationUrl = 'mautic';
|
|
9
|
+
this.properties = [
|
|
10
|
+
{
|
|
11
|
+
displayName: 'URL',
|
|
12
|
+
name: 'url',
|
|
13
|
+
type: 'string',
|
|
14
|
+
default: '',
|
|
15
|
+
placeholder: 'https://name.mautic.net',
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
displayName: 'Username',
|
|
19
|
+
name: 'username',
|
|
20
|
+
type: 'string',
|
|
21
|
+
default: '',
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
displayName: 'Password',
|
|
25
|
+
name: 'password',
|
|
26
|
+
type: 'string',
|
|
27
|
+
typeOptions: {
|
|
28
|
+
password: true,
|
|
29
|
+
},
|
|
30
|
+
default: '',
|
|
31
|
+
},
|
|
32
|
+
];
|
|
33
|
+
this.authenticate = {
|
|
34
|
+
type: 'generic',
|
|
35
|
+
properties: {
|
|
36
|
+
auth: {
|
|
37
|
+
username: '={{$credentials.username}}',
|
|
38
|
+
password: '={{$credentials.password}}',
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
};
|
|
42
|
+
this.test = {
|
|
43
|
+
request: {
|
|
44
|
+
baseURL: '={{$credentials.url.replace(new RegExp("/$"), "")}}',
|
|
45
|
+
url: '/api/users/self',
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
exports.MauticAdvancedApi = MauticAdvancedApi;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MauticAdvancedOAuth2Api = void 0;
|
|
4
|
+
class MauticAdvancedOAuth2Api {
|
|
5
|
+
constructor() {
|
|
6
|
+
this.name = 'mauticAdvancedOAuth2Api';
|
|
7
|
+
this.extends = ['oAuth2Api'];
|
|
8
|
+
this.displayName = 'Mautic Advanced OAuth2 API';
|
|
9
|
+
this.documentationUrl = 'mautic';
|
|
10
|
+
this.properties = [
|
|
11
|
+
{
|
|
12
|
+
displayName: 'Grant Type',
|
|
13
|
+
name: 'grantType',
|
|
14
|
+
type: 'hidden',
|
|
15
|
+
default: 'authorizationCode',
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
displayName: 'URL',
|
|
19
|
+
name: 'url',
|
|
20
|
+
type: 'string',
|
|
21
|
+
default: '',
|
|
22
|
+
placeholder: 'https://name.mautic.net',
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
displayName: 'Authorization URL',
|
|
26
|
+
name: 'authUrl',
|
|
27
|
+
type: 'hidden',
|
|
28
|
+
default: '={{$self["url"].endsWith("/") ? $self["url"].slice(0, -1) : $self["url"]}}/oauth/v2/authorize',
|
|
29
|
+
required: true,
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
displayName: 'Access Token URL',
|
|
33
|
+
name: 'accessTokenUrl',
|
|
34
|
+
type: 'hidden',
|
|
35
|
+
default: '={{$self["url"].endsWith("/") ? $self["url"].slice(0, -1) : $self["url"]}}/oauth/v2/token',
|
|
36
|
+
required: true,
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
displayName: 'Scope',
|
|
40
|
+
name: 'scope',
|
|
41
|
+
type: 'hidden',
|
|
42
|
+
default: '',
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
displayName: 'Auth URI Query Parameters',
|
|
46
|
+
name: 'authQueryParameters',
|
|
47
|
+
type: 'hidden',
|
|
48
|
+
default: '',
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
displayName: 'Authentication',
|
|
52
|
+
name: 'authentication',
|
|
53
|
+
type: 'hidden',
|
|
54
|
+
default: 'body',
|
|
55
|
+
},
|
|
56
|
+
];
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
exports.MauticAdvancedOAuth2Api = MauticAdvancedOAuth2Api;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.campaignContactFields = exports.campaignContactOperations = void 0;
|
|
4
|
+
exports.campaignContactOperations = [
|
|
5
|
+
{
|
|
6
|
+
displayName: 'Operation',
|
|
7
|
+
name: 'operation',
|
|
8
|
+
type: 'options',
|
|
9
|
+
noDataExpression: true,
|
|
10
|
+
displayOptions: {
|
|
11
|
+
show: {
|
|
12
|
+
resource: ['campaignContact'],
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
options: [
|
|
16
|
+
{
|
|
17
|
+
name: 'Add',
|
|
18
|
+
value: 'add',
|
|
19
|
+
description: 'Add contact to a campaign',
|
|
20
|
+
action: 'Add a campaign contact',
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
name: 'Remove',
|
|
24
|
+
value: 'remove',
|
|
25
|
+
description: 'Remove contact from a campaign',
|
|
26
|
+
action: 'Remove a campaign contact',
|
|
27
|
+
},
|
|
28
|
+
],
|
|
29
|
+
default: 'add',
|
|
30
|
+
},
|
|
31
|
+
];
|
|
32
|
+
exports.campaignContactFields = [
|
|
33
|
+
/* -------------------------------------------------------------------------- */
|
|
34
|
+
/* campaignContact:add */
|
|
35
|
+
/* -------------------------------------------------------------------------- */
|
|
36
|
+
{
|
|
37
|
+
displayName: 'Contact ID',
|
|
38
|
+
name: 'contactId',
|
|
39
|
+
type: 'string',
|
|
40
|
+
required: true,
|
|
41
|
+
displayOptions: {
|
|
42
|
+
show: {
|
|
43
|
+
resource: ['campaignContact'],
|
|
44
|
+
operation: ['add', 'remove'],
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
default: '',
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
displayName: 'Campaign Name or ID',
|
|
51
|
+
name: 'campaignId',
|
|
52
|
+
type: 'options',
|
|
53
|
+
description: 'Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code/expressions/">expression</a>',
|
|
54
|
+
required: true,
|
|
55
|
+
displayOptions: {
|
|
56
|
+
show: {
|
|
57
|
+
resource: ['campaignContact'],
|
|
58
|
+
operation: ['add', 'remove'],
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
typeOptions: {
|
|
62
|
+
loadOptionsMethod: 'getCampaigns',
|
|
63
|
+
},
|
|
64
|
+
default: '',
|
|
65
|
+
},
|
|
66
|
+
];
|
|
@@ -0,0 +1,422 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.campaignFields = exports.campaignOperations = void 0;
|
|
4
|
+
exports.campaignOperations = [
|
|
5
|
+
{
|
|
6
|
+
displayName: 'Operation',
|
|
7
|
+
name: 'operation',
|
|
8
|
+
type: 'options',
|
|
9
|
+
noDataExpression: true,
|
|
10
|
+
displayOptions: {
|
|
11
|
+
show: {
|
|
12
|
+
resource: ['campaign'],
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
options: [
|
|
16
|
+
{
|
|
17
|
+
name: 'Clone',
|
|
18
|
+
value: 'clone',
|
|
19
|
+
description: 'Clone a campaign',
|
|
20
|
+
action: 'Clone a campaign',
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
name: 'Create',
|
|
24
|
+
value: 'create',
|
|
25
|
+
description: 'Create a new campaign',
|
|
26
|
+
action: 'Create a campaign',
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
name: 'Delete',
|
|
30
|
+
value: 'delete',
|
|
31
|
+
description: 'Delete a campaign',
|
|
32
|
+
action: 'Delete a campaign',
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
name: 'Get',
|
|
36
|
+
value: 'get',
|
|
37
|
+
description: 'Get a campaign',
|
|
38
|
+
action: 'Get a campaign',
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
name: 'Get All',
|
|
42
|
+
value: 'getAll',
|
|
43
|
+
description: 'Get all campaigns',
|
|
44
|
+
action: 'Get all campaigns',
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
name: 'Get Contacts',
|
|
48
|
+
value: 'getContacts',
|
|
49
|
+
description: "Get a campaign's contacts",
|
|
50
|
+
action: 'Get a campaigns contacts',
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
name: 'Update',
|
|
54
|
+
value: 'update',
|
|
55
|
+
description: 'Update a campaign',
|
|
56
|
+
action: 'Update a campaign',
|
|
57
|
+
},
|
|
58
|
+
],
|
|
59
|
+
default: 'getAll',
|
|
60
|
+
},
|
|
61
|
+
];
|
|
62
|
+
exports.campaignFields = [
|
|
63
|
+
/* -------------------------------------------------------------------------- */
|
|
64
|
+
/* campaign:create */
|
|
65
|
+
/* -------------------------------------------------------------------------- */
|
|
66
|
+
{
|
|
67
|
+
displayName: 'Name',
|
|
68
|
+
name: 'name',
|
|
69
|
+
type: 'string',
|
|
70
|
+
required: true,
|
|
71
|
+
displayOptions: {
|
|
72
|
+
show: {
|
|
73
|
+
resource: ['campaign'],
|
|
74
|
+
operation: ['create'],
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
default: '',
|
|
78
|
+
description: 'Name of the campaign',
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
displayName: 'Additional Fields',
|
|
82
|
+
name: 'additionalFields',
|
|
83
|
+
type: 'collection',
|
|
84
|
+
displayOptions: {
|
|
85
|
+
show: {
|
|
86
|
+
resource: ['campaign'],
|
|
87
|
+
operation: ['create'],
|
|
88
|
+
},
|
|
89
|
+
},
|
|
90
|
+
default: {},
|
|
91
|
+
placeholder: 'Add Field',
|
|
92
|
+
options: [
|
|
93
|
+
{
|
|
94
|
+
displayName: 'Description',
|
|
95
|
+
name: 'description',
|
|
96
|
+
type: 'string',
|
|
97
|
+
default: '',
|
|
98
|
+
description: 'Description of the campaign',
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
displayName: 'Is Published',
|
|
102
|
+
name: 'isPublished',
|
|
103
|
+
type: 'boolean',
|
|
104
|
+
default: false,
|
|
105
|
+
description: 'Whether the campaign is published',
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
displayName: 'Publish Down',
|
|
109
|
+
name: 'publishDown',
|
|
110
|
+
type: 'dateTime',
|
|
111
|
+
default: '',
|
|
112
|
+
description: 'Date/time the campaign should be unpublished',
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
displayName: 'Publish Up',
|
|
116
|
+
name: 'publishUp',
|
|
117
|
+
type: 'dateTime',
|
|
118
|
+
default: '',
|
|
119
|
+
description: 'Date/time when the campaign should be published',
|
|
120
|
+
},
|
|
121
|
+
],
|
|
122
|
+
},
|
|
123
|
+
/* -------------------------------------------------------------------------- */
|
|
124
|
+
/* campaign:update */
|
|
125
|
+
/* -------------------------------------------------------------------------- */
|
|
126
|
+
{
|
|
127
|
+
displayName: 'Campaign ID',
|
|
128
|
+
name: 'campaignId',
|
|
129
|
+
type: 'string',
|
|
130
|
+
required: true,
|
|
131
|
+
displayOptions: {
|
|
132
|
+
show: {
|
|
133
|
+
resource: ['campaign'],
|
|
134
|
+
operation: ['update'],
|
|
135
|
+
},
|
|
136
|
+
},
|
|
137
|
+
default: '',
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
displayName: 'Update Fields',
|
|
141
|
+
name: 'updateFields',
|
|
142
|
+
type: 'collection',
|
|
143
|
+
displayOptions: {
|
|
144
|
+
show: {
|
|
145
|
+
resource: ['campaign'],
|
|
146
|
+
operation: ['update'],
|
|
147
|
+
},
|
|
148
|
+
},
|
|
149
|
+
default: {},
|
|
150
|
+
placeholder: 'Add Field',
|
|
151
|
+
options: [
|
|
152
|
+
{
|
|
153
|
+
displayName: 'Description',
|
|
154
|
+
name: 'description',
|
|
155
|
+
type: 'string',
|
|
156
|
+
default: '',
|
|
157
|
+
description: 'Description of the campaign',
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
displayName: 'Name',
|
|
161
|
+
name: 'name',
|
|
162
|
+
type: 'string',
|
|
163
|
+
default: '',
|
|
164
|
+
description: 'Name of the campaign',
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
displayName: 'Is Published',
|
|
168
|
+
name: 'isPublished',
|
|
169
|
+
type: 'boolean',
|
|
170
|
+
default: false,
|
|
171
|
+
description: 'Whether the campaign is published',
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
displayName: 'Publish Down',
|
|
175
|
+
name: 'publishDown',
|
|
176
|
+
type: 'dateTime',
|
|
177
|
+
default: '',
|
|
178
|
+
description: 'Date/time the campaign should be unpublished',
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
displayName: 'Publish Up',
|
|
182
|
+
name: 'publishUp',
|
|
183
|
+
type: 'dateTime',
|
|
184
|
+
default: '',
|
|
185
|
+
description: 'Date/time when the campaign should be published',
|
|
186
|
+
},
|
|
187
|
+
],
|
|
188
|
+
},
|
|
189
|
+
/* -------------------------------------------------------------------------- */
|
|
190
|
+
/* campaign:clone */
|
|
191
|
+
/* -------------------------------------------------------------------------- */
|
|
192
|
+
{
|
|
193
|
+
displayName: 'Campaign ID',
|
|
194
|
+
name: 'campaignId',
|
|
195
|
+
type: 'string',
|
|
196
|
+
required: true,
|
|
197
|
+
displayOptions: {
|
|
198
|
+
show: {
|
|
199
|
+
resource: ['campaign'],
|
|
200
|
+
operation: ['clone'],
|
|
201
|
+
},
|
|
202
|
+
},
|
|
203
|
+
default: '',
|
|
204
|
+
},
|
|
205
|
+
/* -------------------------------------------------------------------------- */
|
|
206
|
+
/* campaign:get */
|
|
207
|
+
/* -------------------------------------------------------------------------- */
|
|
208
|
+
{
|
|
209
|
+
displayName: 'Campaign ID',
|
|
210
|
+
name: 'campaignId',
|
|
211
|
+
type: 'string',
|
|
212
|
+
required: true,
|
|
213
|
+
displayOptions: {
|
|
214
|
+
show: {
|
|
215
|
+
resource: ['campaign'],
|
|
216
|
+
operation: ['get'],
|
|
217
|
+
},
|
|
218
|
+
},
|
|
219
|
+
default: '',
|
|
220
|
+
},
|
|
221
|
+
/* -------------------------------------------------------------------------- */
|
|
222
|
+
/* campaign:delete */
|
|
223
|
+
/* -------------------------------------------------------------------------- */
|
|
224
|
+
{
|
|
225
|
+
displayName: 'Campaign ID',
|
|
226
|
+
name: 'campaignId',
|
|
227
|
+
type: 'string',
|
|
228
|
+
required: true,
|
|
229
|
+
displayOptions: {
|
|
230
|
+
show: {
|
|
231
|
+
resource: ['campaign'],
|
|
232
|
+
operation: ['delete'],
|
|
233
|
+
},
|
|
234
|
+
},
|
|
235
|
+
default: '',
|
|
236
|
+
},
|
|
237
|
+
/* -------------------------------------------------------------------------- */
|
|
238
|
+
/* campaign:getAll */
|
|
239
|
+
/* -------------------------------------------------------------------------- */
|
|
240
|
+
{
|
|
241
|
+
displayName: 'Return All',
|
|
242
|
+
name: 'returnAll',
|
|
243
|
+
type: 'boolean',
|
|
244
|
+
displayOptions: {
|
|
245
|
+
show: {
|
|
246
|
+
resource: ['campaign'],
|
|
247
|
+
operation: ['getAll'],
|
|
248
|
+
},
|
|
249
|
+
},
|
|
250
|
+
default: false,
|
|
251
|
+
description: 'Whether to return all results or only up to a given limit',
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
displayName: 'Limit',
|
|
255
|
+
name: 'limit',
|
|
256
|
+
type: 'number',
|
|
257
|
+
displayOptions: {
|
|
258
|
+
show: {
|
|
259
|
+
resource: ['campaign'],
|
|
260
|
+
operation: ['getAll'],
|
|
261
|
+
returnAll: [false],
|
|
262
|
+
},
|
|
263
|
+
},
|
|
264
|
+
typeOptions: {
|
|
265
|
+
minValue: 1,
|
|
266
|
+
},
|
|
267
|
+
default: 50,
|
|
268
|
+
description: 'Max number of results to return',
|
|
269
|
+
},
|
|
270
|
+
{
|
|
271
|
+
displayName: 'Options',
|
|
272
|
+
name: 'options',
|
|
273
|
+
type: 'collection',
|
|
274
|
+
displayOptions: {
|
|
275
|
+
show: {
|
|
276
|
+
resource: ['campaign'],
|
|
277
|
+
operation: ['getAll'],
|
|
278
|
+
},
|
|
279
|
+
},
|
|
280
|
+
default: {},
|
|
281
|
+
placeholder: 'Add Field',
|
|
282
|
+
options: [
|
|
283
|
+
{
|
|
284
|
+
displayName: 'Minimal',
|
|
285
|
+
name: 'minimal',
|
|
286
|
+
type: 'boolean',
|
|
287
|
+
default: false,
|
|
288
|
+
description: 'Return only array of entities without additional lists in it',
|
|
289
|
+
},
|
|
290
|
+
{
|
|
291
|
+
displayName: 'Order By',
|
|
292
|
+
name: 'orderBy',
|
|
293
|
+
type: 'string',
|
|
294
|
+
default: '',
|
|
295
|
+
description: 'Column to sort by. Can use any column listed in the response.',
|
|
296
|
+
},
|
|
297
|
+
{
|
|
298
|
+
displayName: 'Order By Dir',
|
|
299
|
+
name: 'orderByDir',
|
|
300
|
+
type: 'options',
|
|
301
|
+
options: [
|
|
302
|
+
{
|
|
303
|
+
name: 'ASC',
|
|
304
|
+
value: 'asc',
|
|
305
|
+
},
|
|
306
|
+
{
|
|
307
|
+
name: 'DESC',
|
|
308
|
+
value: 'desc',
|
|
309
|
+
},
|
|
310
|
+
],
|
|
311
|
+
default: 'asc',
|
|
312
|
+
description: 'Sort direction',
|
|
313
|
+
},
|
|
314
|
+
{
|
|
315
|
+
displayName: 'Published Only',
|
|
316
|
+
name: 'publishedOnly',
|
|
317
|
+
type: 'boolean',
|
|
318
|
+
default: false,
|
|
319
|
+
description: 'Only return currently published entities',
|
|
320
|
+
},
|
|
321
|
+
{
|
|
322
|
+
displayName: 'Search',
|
|
323
|
+
name: 'search',
|
|
324
|
+
type: 'string',
|
|
325
|
+
default: '',
|
|
326
|
+
description: 'String or search command to filter entities by',
|
|
327
|
+
},
|
|
328
|
+
],
|
|
329
|
+
},
|
|
330
|
+
/* -------------------------------------------------------------------------- */
|
|
331
|
+
/* campaign:getContacts */
|
|
332
|
+
/* -------------------------------------------------------------------------- */
|
|
333
|
+
{
|
|
334
|
+
displayName: 'Campaign ID',
|
|
335
|
+
name: 'campaignId',
|
|
336
|
+
type: 'string',
|
|
337
|
+
required: true,
|
|
338
|
+
displayOptions: {
|
|
339
|
+
show: {
|
|
340
|
+
resource: ['campaign'],
|
|
341
|
+
operation: ['getContacts'],
|
|
342
|
+
},
|
|
343
|
+
},
|
|
344
|
+
default: '',
|
|
345
|
+
},
|
|
346
|
+
{
|
|
347
|
+
displayName: 'Return All',
|
|
348
|
+
name: 'returnAll',
|
|
349
|
+
type: 'boolean',
|
|
350
|
+
displayOptions: {
|
|
351
|
+
show: {
|
|
352
|
+
resource: ['campaign'],
|
|
353
|
+
operation: ['getContacts'],
|
|
354
|
+
},
|
|
355
|
+
},
|
|
356
|
+
default: false,
|
|
357
|
+
description: 'Whether to return all results or only up to a given limit',
|
|
358
|
+
},
|
|
359
|
+
{
|
|
360
|
+
displayName: 'Limit',
|
|
361
|
+
name: 'limit',
|
|
362
|
+
type: 'number',
|
|
363
|
+
displayOptions: {
|
|
364
|
+
show: {
|
|
365
|
+
resource: ['campaign'],
|
|
366
|
+
operation: ['getContacts'],
|
|
367
|
+
returnAll: [false],
|
|
368
|
+
},
|
|
369
|
+
},
|
|
370
|
+
typeOptions: {
|
|
371
|
+
minValue: 1,
|
|
372
|
+
},
|
|
373
|
+
default: 50,
|
|
374
|
+
description: 'Max number of results to return',
|
|
375
|
+
},
|
|
376
|
+
{
|
|
377
|
+
displayName: 'Options',
|
|
378
|
+
name: 'options',
|
|
379
|
+
type: 'collection',
|
|
380
|
+
displayOptions: {
|
|
381
|
+
show: {
|
|
382
|
+
resource: ['campaign'],
|
|
383
|
+
operation: ['getContacts'],
|
|
384
|
+
},
|
|
385
|
+
},
|
|
386
|
+
default: {},
|
|
387
|
+
placeholder: 'Add Field',
|
|
388
|
+
options: [
|
|
389
|
+
{
|
|
390
|
+
displayName: 'Order By',
|
|
391
|
+
name: 'orderBy',
|
|
392
|
+
type: 'string',
|
|
393
|
+
default: '',
|
|
394
|
+
description: 'Column to sort by. Can use any column listed in the response.',
|
|
395
|
+
},
|
|
396
|
+
{
|
|
397
|
+
displayName: 'Order By Dir',
|
|
398
|
+
name: 'orderByDir',
|
|
399
|
+
type: 'options',
|
|
400
|
+
options: [
|
|
401
|
+
{
|
|
402
|
+
name: 'ASC',
|
|
403
|
+
value: 'asc',
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
name: 'DESC',
|
|
407
|
+
value: 'desc',
|
|
408
|
+
},
|
|
409
|
+
],
|
|
410
|
+
default: 'asc',
|
|
411
|
+
description: 'Sort direction',
|
|
412
|
+
},
|
|
413
|
+
{
|
|
414
|
+
displayName: 'Search',
|
|
415
|
+
name: 'search',
|
|
416
|
+
type: 'string',
|
|
417
|
+
default: '',
|
|
418
|
+
description: 'String or search command to filter entities by',
|
|
419
|
+
},
|
|
420
|
+
],
|
|
421
|
+
},
|
|
422
|
+
];
|