n8n-nodes-agentmesh 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 +121 -0
- package/dist/credentials/AgentMeshApi.credentials.d.ts +8 -0
- package/dist/credentials/AgentMeshApi.credentials.js +43 -0
- package/dist/credentials/AgentMeshApi.credentials.js.map +1 -0
- package/dist/nodes/AgentMesh/AgentMesh.node.d.ts +5 -0
- package/dist/nodes/AgentMesh/AgentMesh.node.js +216 -0
- package/dist/nodes/AgentMesh/AgentMesh.node.js.map +1 -0
- package/package.json +43 -0
package/README.md
ADDED
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
# n8n-nodes-agentmesh
|
|
2
|
+
|
|
3
|
+
This is an n8n community node that integrates with the [AgentMesh](https://agentmesh.cc) API to search Reddit posts using async task processing.
|
|
4
|
+
|
|
5
|
+
## Features
|
|
6
|
+
|
|
7
|
+
- Search Reddit posts with keyword queries
|
|
8
|
+
- Support multiple sort types: **Best**, **Hot**, **New**, **Top**, **Rising**
|
|
9
|
+
- Target specific subreddits or search across all
|
|
10
|
+
- Async task processing with automatic polling
|
|
11
|
+
- Each post returned as a separate n8n item for easy downstream processing
|
|
12
|
+
|
|
13
|
+
## Installation
|
|
14
|
+
|
|
15
|
+
### Community Node (Recommended)
|
|
16
|
+
|
|
17
|
+
1. Go to **Settings > Community Nodes** in your n8n instance
|
|
18
|
+
2. Select **Install a community node**
|
|
19
|
+
3. Enter `n8n-nodes-agentmesh`
|
|
20
|
+
4. Agree to the risks and click **Install**
|
|
21
|
+
|
|
22
|
+
### Manual Installation
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
cd ~/.n8n/custom
|
|
26
|
+
npm install n8n-nodes-agentmesh
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
Or link locally for development:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
cd /path/to/n8n-nodes-agentmesh
|
|
33
|
+
npm install
|
|
34
|
+
npm run build
|
|
35
|
+
npm link
|
|
36
|
+
|
|
37
|
+
cd ~/.n8n
|
|
38
|
+
npm link n8n-nodes-agentmesh
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Then restart n8n.
|
|
42
|
+
|
|
43
|
+
## Credentials
|
|
44
|
+
|
|
45
|
+
You need to configure an **AgentMesh API** credential with:
|
|
46
|
+
|
|
47
|
+
| Field | Description | Default |
|
|
48
|
+
|---|---|---|
|
|
49
|
+
| **API Key** | Your AgentMesh API key (`sk_xxx...`) | — |
|
|
50
|
+
| **Base URL** | The API server base URL | `https://agentmesh.cc` |
|
|
51
|
+
|
|
52
|
+
## Node Parameters
|
|
53
|
+
|
|
54
|
+
| Parameter | Type | Required | Default | Description |
|
|
55
|
+
|---|---|---|---|---|
|
|
56
|
+
| **Sort Type** | Options | Yes | `hot` | Sort order: Best, Hot, New, Top, Rising |
|
|
57
|
+
| **Query** | String | Yes | — | Search keyword (e.g. `AI Agents`) |
|
|
58
|
+
| **Subreddit** | String | No | `all` | Target subreddit. Use `all` for global search |
|
|
59
|
+
| **Limit** | Number | No | `10` | Max results to return (1–100) |
|
|
60
|
+
|
|
61
|
+
## How It Works
|
|
62
|
+
|
|
63
|
+
The node uses an **async task pattern** with three steps:
|
|
64
|
+
|
|
65
|
+
1. **Create Task** — Sends a `POST /api/v1/tasks` request to create a search task
|
|
66
|
+
2. **Poll for Results** — Polls `GET /api/v1/tasks/{taskId}` every 2 seconds (up to 30 attempts, ~60s timeout)
|
|
67
|
+
3. **Output Results** — Returns each post as a separate n8n item with metadata
|
|
68
|
+
|
|
69
|
+
## Output
|
|
70
|
+
|
|
71
|
+
Each output item contains the post data along with a `_meta` field:
|
|
72
|
+
|
|
73
|
+
```json
|
|
74
|
+
{
|
|
75
|
+
"title": "Post title",
|
|
76
|
+
"url": "https://reddit.com/...",
|
|
77
|
+
"score": 42,
|
|
78
|
+
"_meta": {
|
|
79
|
+
"task_id": "abc-123",
|
|
80
|
+
"sort": "hot",
|
|
81
|
+
"query": "AI Agents",
|
|
82
|
+
"subreddit": "all",
|
|
83
|
+
"total_count": 10
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
## Project Structure
|
|
89
|
+
|
|
90
|
+
```
|
|
91
|
+
n8n-nodes-agentmesh/
|
|
92
|
+
├── credentials/
|
|
93
|
+
│ └── AgentMeshApi.credentials.ts # API credential definition
|
|
94
|
+
├── nodes/
|
|
95
|
+
│ └── AgentMesh/
|
|
96
|
+
│ └── AgentMesh.node.ts # Main node logic
|
|
97
|
+
├── package.json
|
|
98
|
+
├── tsconfig.json
|
|
99
|
+
└── README.md
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
## Development
|
|
103
|
+
|
|
104
|
+
```bash
|
|
105
|
+
# Install dependencies
|
|
106
|
+
npm install
|
|
107
|
+
|
|
108
|
+
# Build
|
|
109
|
+
npm run build
|
|
110
|
+
|
|
111
|
+
# Watch mode
|
|
112
|
+
npm run build:watch
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
## License
|
|
116
|
+
|
|
117
|
+
[MIT](LICENSE)
|
|
118
|
+
|
|
119
|
+
## Author
|
|
120
|
+
|
|
121
|
+
**shwanShare**
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { IAuthenticateGeneric, ICredentialType, INodeProperties } from 'n8n-workflow';
|
|
2
|
+
export declare class AgentMeshApi implements ICredentialType {
|
|
3
|
+
name: string;
|
|
4
|
+
displayName: string;
|
|
5
|
+
documentationUrl: string;
|
|
6
|
+
properties: INodeProperties[];
|
|
7
|
+
authenticate: IAuthenticateGeneric;
|
|
8
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AgentMeshApi = void 0;
|
|
4
|
+
class AgentMeshApi {
|
|
5
|
+
constructor() {
|
|
6
|
+
this.name = 'agentMeshApi';
|
|
7
|
+
this.displayName = 'AgentMesh API';
|
|
8
|
+
this.documentationUrl = 'https://agentmesh.cc';
|
|
9
|
+
this.properties = [
|
|
10
|
+
{
|
|
11
|
+
displayName: 'API Key',
|
|
12
|
+
name: 'apiKey',
|
|
13
|
+
type: 'string',
|
|
14
|
+
typeOptions: {
|
|
15
|
+
password: true,
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
required: true,
|
|
19
|
+
placeholder: 'sk_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
|
|
20
|
+
description: 'Your AgentMesh API Key',
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
displayName: 'Base URL',
|
|
24
|
+
name: 'baseUrl',
|
|
25
|
+
type: 'string',
|
|
26
|
+
default: 'https://agentmesh.cc',
|
|
27
|
+
required: true,
|
|
28
|
+
placeholder: 'https://agentmesh.cc',
|
|
29
|
+
description: 'The base URL of the AgentMesh API server',
|
|
30
|
+
},
|
|
31
|
+
];
|
|
32
|
+
this.authenticate = {
|
|
33
|
+
type: 'generic',
|
|
34
|
+
properties: {
|
|
35
|
+
headers: {
|
|
36
|
+
Authorization: '=Bearer {{$credentials.apiKey}}',
|
|
37
|
+
},
|
|
38
|
+
},
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
exports.AgentMeshApi = AgentMeshApi;
|
|
43
|
+
//# sourceMappingURL=AgentMeshApi.credentials.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AgentMeshApi.credentials.js","sourceRoot":"","sources":["../../credentials/AgentMeshApi.credentials.ts"],"names":[],"mappings":";;;AAMA,MAAa,YAAY;IAAzB;QACC,SAAI,GAAG,cAAc,CAAC;QACtB,gBAAW,GAAG,eAAe,CAAC;QAC9B,qBAAgB,GAAG,sBAAsB,CAAC;QAE1C,eAAU,GAAsB;YAC/B;gBACC,WAAW,EAAE,SAAS;gBACtB,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE;oBACZ,QAAQ,EAAE,IAAI;iBACd;gBACD,OAAO,EAAE,EAAE;gBACX,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,qCAAqC;gBAClD,WAAW,EAAE,wBAAwB;aACrC;YACD;gBACC,WAAW,EAAE,UAAU;gBACvB,IAAI,EAAE,SAAS;gBACf,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,sBAAsB;gBAC/B,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,sBAAsB;gBACnC,WAAW,EAAE,0CAA0C;aACvD;SACD,CAAC;QAEF,iBAAY,GAAyB;YACpC,IAAI,EAAE,SAAS;YACf,UAAU,EAAE;gBACX,OAAO,EAAE;oBACR,aAAa,EAAE,iCAAiC;iBAChD;aACD;SACD,CAAC;IACH,CAAC;CAAA;AArCD,oCAqCC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { IExecuteFunctions, INodeExecutionData, INodeType, INodeTypeDescription } from 'n8n-workflow';
|
|
2
|
+
export declare class AgentMesh implements INodeType {
|
|
3
|
+
description: INodeTypeDescription;
|
|
4
|
+
execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]>;
|
|
5
|
+
}
|
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AgentMesh = void 0;
|
|
4
|
+
const n8n_workflow_1 = require("n8n-workflow");
|
|
5
|
+
class AgentMesh {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.description = {
|
|
8
|
+
displayName: 'AgentMesh',
|
|
9
|
+
name: 'agentMesh',
|
|
10
|
+
icon: 'fa:search',
|
|
11
|
+
group: ['transform'],
|
|
12
|
+
version: 1,
|
|
13
|
+
subtitle: '=Search Posts ({{$parameter["resource"]}})',
|
|
14
|
+
description: 'Search Reddit posts via AgentMesh API with async task processing',
|
|
15
|
+
defaults: {
|
|
16
|
+
name: 'AgentMesh',
|
|
17
|
+
},
|
|
18
|
+
inputs: [n8n_workflow_1.NodeConnectionTypes.Main],
|
|
19
|
+
outputs: [n8n_workflow_1.NodeConnectionTypes.Main],
|
|
20
|
+
credentials: [
|
|
21
|
+
{
|
|
22
|
+
name: 'agentMeshApi',
|
|
23
|
+
required: true,
|
|
24
|
+
},
|
|
25
|
+
],
|
|
26
|
+
properties: [
|
|
27
|
+
// ============ Resource Selection (Sort Type) ============
|
|
28
|
+
{
|
|
29
|
+
displayName: 'Sort Type',
|
|
30
|
+
name: 'resource',
|
|
31
|
+
type: 'options',
|
|
32
|
+
noDataExpression: true,
|
|
33
|
+
options: [
|
|
34
|
+
{
|
|
35
|
+
name: 'Best',
|
|
36
|
+
value: 'best',
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
name: 'Hot',
|
|
40
|
+
value: 'hot',
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
name: 'New',
|
|
44
|
+
value: 'new',
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
name: 'Top',
|
|
48
|
+
value: 'top',
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
name: 'Rising',
|
|
52
|
+
value: 'rising',
|
|
53
|
+
},
|
|
54
|
+
],
|
|
55
|
+
default: 'hot',
|
|
56
|
+
description: 'Sort type for Reddit posts',
|
|
57
|
+
},
|
|
58
|
+
// ============ Search Parameters ============
|
|
59
|
+
{
|
|
60
|
+
displayName: 'Query',
|
|
61
|
+
name: 'query',
|
|
62
|
+
type: 'string',
|
|
63
|
+
default: '',
|
|
64
|
+
required: true,
|
|
65
|
+
placeholder: 'e.g. AI Agents',
|
|
66
|
+
description: 'Search query keyword',
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
displayName: 'Subreddit',
|
|
70
|
+
name: 'subreddit',
|
|
71
|
+
type: 'string',
|
|
72
|
+
default: 'all',
|
|
73
|
+
placeholder: 'e.g. AI_Agents',
|
|
74
|
+
description: 'Target subreddit to search in. Use "all" to search across all subreddits.',
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
displayName: 'Limit',
|
|
78
|
+
name: 'limit',
|
|
79
|
+
type: 'number',
|
|
80
|
+
typeOptions: {
|
|
81
|
+
minValue: 1,
|
|
82
|
+
maxValue: 100,
|
|
83
|
+
},
|
|
84
|
+
default: 10,
|
|
85
|
+
description: 'Maximum number of results to return',
|
|
86
|
+
},
|
|
87
|
+
],
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
async execute() {
|
|
91
|
+
var _a, _b;
|
|
92
|
+
const items = this.getInputData();
|
|
93
|
+
const returnData = [];
|
|
94
|
+
for (let i = 0; i < items.length; i++) {
|
|
95
|
+
try {
|
|
96
|
+
const resource = this.getNodeParameter('resource', i);
|
|
97
|
+
const credentials = await this.getCredentials('agentMeshApi');
|
|
98
|
+
const baseUrl = credentials.baseUrl.replace(/\/+$/, '');
|
|
99
|
+
const apiKey = credentials.apiKey;
|
|
100
|
+
const query = this.getNodeParameter('query', i);
|
|
101
|
+
const subreddit = this.getNodeParameter('subreddit', i, 'all');
|
|
102
|
+
const limit = this.getNodeParameter('limit', i, 10);
|
|
103
|
+
// Polling config: max 30 attempts, 2s interval (~60s timeout)
|
|
104
|
+
const maxAttempts = 30;
|
|
105
|
+
const pollingInterval = 2;
|
|
106
|
+
// ========== Step 1: Create Task ==========
|
|
107
|
+
const createResponse = await this.helpers.httpRequest({
|
|
108
|
+
method: 'POST',
|
|
109
|
+
url: `${baseUrl}/api/v1/tasks`,
|
|
110
|
+
headers: {
|
|
111
|
+
'Authorization': `Bearer ${apiKey}`,
|
|
112
|
+
'Content-Type': 'application/json',
|
|
113
|
+
},
|
|
114
|
+
body: {
|
|
115
|
+
platform: 'reddit',
|
|
116
|
+
task_type: 'search_posts',
|
|
117
|
+
params: {
|
|
118
|
+
query,
|
|
119
|
+
subreddit: subreddit || 'all',
|
|
120
|
+
sort: resource,
|
|
121
|
+
limit,
|
|
122
|
+
},
|
|
123
|
+
},
|
|
124
|
+
json: true,
|
|
125
|
+
});
|
|
126
|
+
const taskId = createResponse.task_id;
|
|
127
|
+
if (!taskId) {
|
|
128
|
+
throw new Error('Failed to create task: No task_id returned from API');
|
|
129
|
+
}
|
|
130
|
+
// ========== Step 2: Poll for Results ==========
|
|
131
|
+
let attempts = 0;
|
|
132
|
+
let taskResult = null;
|
|
133
|
+
while (attempts < maxAttempts) {
|
|
134
|
+
// Wait before polling
|
|
135
|
+
await new Promise((resolve) => setTimeout(resolve, pollingInterval * 1000));
|
|
136
|
+
attempts++;
|
|
137
|
+
taskResult = await this.helpers.httpRequest({
|
|
138
|
+
method: 'GET',
|
|
139
|
+
url: `${baseUrl}/api/v1/tasks/${taskId}`,
|
|
140
|
+
headers: {
|
|
141
|
+
'Authorization': `Bearer ${apiKey}`,
|
|
142
|
+
},
|
|
143
|
+
json: true,
|
|
144
|
+
});
|
|
145
|
+
if (taskResult.status === 'SUCCEEDED') {
|
|
146
|
+
break;
|
|
147
|
+
}
|
|
148
|
+
if (taskResult.status === 'FAILED') {
|
|
149
|
+
throw new Error(`Task ${taskId} execution failed. Status: FAILED`);
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
// Check if we timed out
|
|
153
|
+
if (!taskResult || taskResult.status !== 'SUCCEEDED') {
|
|
154
|
+
throw new Error(`Task ${taskId} timed out after ${attempts} polling attempts ` +
|
|
155
|
+
`(~${attempts * pollingInterval}s). Last status: ${(taskResult === null || taskResult === void 0 ? void 0 : taskResult.status) || 'unknown'}`);
|
|
156
|
+
}
|
|
157
|
+
// ========== Step 3: Output Results ==========
|
|
158
|
+
if (((_a = taskResult.result) === null || _a === void 0 ? void 0 : _a.items) && Array.isArray(taskResult.result.items)) {
|
|
159
|
+
// Output each post as a separate n8n item for easy downstream processing
|
|
160
|
+
for (const item of taskResult.result.items) {
|
|
161
|
+
returnData.push({
|
|
162
|
+
json: {
|
|
163
|
+
...item,
|
|
164
|
+
_meta: {
|
|
165
|
+
task_id: taskId,
|
|
166
|
+
sort: resource,
|
|
167
|
+
query,
|
|
168
|
+
subreddit,
|
|
169
|
+
total_count: (_b = taskResult.result.meta) === null || _b === void 0 ? void 0 : _b.count,
|
|
170
|
+
},
|
|
171
|
+
},
|
|
172
|
+
});
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
else {
|
|
176
|
+
// Fallback: return the full task result as a single item
|
|
177
|
+
returnData.push({
|
|
178
|
+
json: {
|
|
179
|
+
task_id: taskId,
|
|
180
|
+
status: taskResult.status,
|
|
181
|
+
result: taskResult.result,
|
|
182
|
+
},
|
|
183
|
+
});
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
catch (error) {
|
|
187
|
+
let errorMessage = error.message || 'Unknown error';
|
|
188
|
+
let errorDetails = {};
|
|
189
|
+
if (error.response) {
|
|
190
|
+
errorDetails = {
|
|
191
|
+
statusCode: error.response.status || error.response.statusCode,
|
|
192
|
+
body: error.response.data || error.response.body,
|
|
193
|
+
};
|
|
194
|
+
errorMessage = `API Error ${errorDetails.statusCode}: ${JSON.stringify(errorDetails.body)}`;
|
|
195
|
+
}
|
|
196
|
+
if (this.continueOnFail()) {
|
|
197
|
+
returnData.push({
|
|
198
|
+
json: {
|
|
199
|
+
success: false,
|
|
200
|
+
error: errorMessage,
|
|
201
|
+
details: errorDetails,
|
|
202
|
+
},
|
|
203
|
+
});
|
|
204
|
+
continue;
|
|
205
|
+
}
|
|
206
|
+
throw new n8n_workflow_1.NodeApiError(this.getNode(), error, {
|
|
207
|
+
message: errorMessage,
|
|
208
|
+
description: `Request failed. Details: ${JSON.stringify(errorDetails)}`,
|
|
209
|
+
});
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
return [returnData];
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
exports.AgentMesh = AgentMesh;
|
|
216
|
+
//# sourceMappingURL=AgentMesh.node.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AgentMesh.node.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
4
|
+
"description": "n8n community node for AgentMesh - Search Reddit posts via async task processing",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"keywords": [
|
|
7
|
+
"n8n-community-node-package",
|
|
8
|
+
"n8n",
|
|
9
|
+
"agentmesh",
|
|
10
|
+
"reddit",
|
|
11
|
+
"search",
|
|
12
|
+
"social-media"
|
|
13
|
+
],
|
|
14
|
+
"author": {
|
|
15
|
+
"name": "shwanShare"
|
|
16
|
+
},
|
|
17
|
+
"scripts": {
|
|
18
|
+
"build": "tsc && cp nodes/**/*.json dist/nodes/ 2>/dev/null || true",
|
|
19
|
+
"build:watch": "tsc --watch",
|
|
20
|
+
"lint": "eslint . --ext .ts",
|
|
21
|
+
"lint:fix": "eslint . --ext .ts --fix",
|
|
22
|
+
"prepublishOnly": "npm run build"
|
|
23
|
+
},
|
|
24
|
+
"files": [
|
|
25
|
+
"dist"
|
|
26
|
+
],
|
|
27
|
+
"n8n": {
|
|
28
|
+
"n8nNodesApiVersion": 1,
|
|
29
|
+
"credentials": [
|
|
30
|
+
"dist/credentials/AgentMeshApi.credentials.js"
|
|
31
|
+
],
|
|
32
|
+
"nodes": [
|
|
33
|
+
"dist/nodes/AgentMesh/AgentMesh.node.js"
|
|
34
|
+
]
|
|
35
|
+
},
|
|
36
|
+
"devDependencies": {
|
|
37
|
+
"@types/node": "^20.0.0",
|
|
38
|
+
"typescript": "^5.0.0"
|
|
39
|
+
},
|
|
40
|
+
"peerDependencies": {
|
|
41
|
+
"n8n-workflow": "*"
|
|
42
|
+
}
|
|
43
|
+
}
|