n8n-nodes-base 1.94.0 → 1.95.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/dist/credentials/GithubOAuth2Api.credentials.js +2 -2
- package/dist/credentials/GithubOAuth2Api.credentials.js.map +1 -1
- package/dist/credentials/MicrosoftSharePointOAuth2Api.credentials.js +9 -0
- package/dist/credentials/MicrosoftSharePointOAuth2Api.credentials.js.map +1 -1
- package/dist/credentials/PerplexityApi.credentials.js +70 -0
- package/dist/credentials/PerplexityApi.credentials.js.map +1 -0
- package/dist/credentials/icons/microsoftSharePoint.svg +59 -0
- package/dist/known/credentials.json +7 -0
- package/dist/known/nodes.json +4 -0
- package/dist/nodes/Evaluation/EvaluationTrigger/EvaluationTrigger.node.ee.js +12 -22
- package/dist/nodes/Evaluation/EvaluationTrigger/EvaluationTrigger.node.ee.js.map +1 -1
- package/dist/nodes/JinaAI/JinaAi.node.js +1 -1
- package/dist/nodes/JinaAI/JinaAi.node.js.map +1 -1
- package/dist/nodes/Perplexity/GenericFunctions.js +49 -0
- package/dist/nodes/Perplexity/GenericFunctions.js.map +1 -0
- package/dist/nodes/Perplexity/Perplexity.node.js +78 -0
- package/dist/nodes/Perplexity/Perplexity.node.js.map +1 -0
- package/dist/nodes/Perplexity/Perplexity.node.json +18 -0
- package/dist/nodes/Perplexity/descriptions/chat/Chat.resource.js +72 -0
- package/dist/nodes/Perplexity/descriptions/chat/Chat.resource.js.map +1 -0
- package/dist/nodes/Perplexity/descriptions/chat/complete.operation.js +328 -0
- package/dist/nodes/Perplexity/descriptions/chat/complete.operation.js.map +1 -0
- package/dist/nodes/Perplexity/descriptions/index.js +39 -0
- package/dist/nodes/Perplexity/descriptions/index.js.map +1 -0
- package/dist/nodes/Perplexity/perplexity.svg +35 -0
- package/dist/nodes/RespondToWebhook/RespondToWebhook.node.js +14 -3
- package/dist/nodes/RespondToWebhook/RespondToWebhook.node.js.map +1 -1
- package/dist/nodes/RespondToWebhook/utils.js +3 -2
- package/dist/nodes/RespondToWebhook/utils.js.map +1 -1
- package/dist/nodes/Telegram/Telegram.node.js +1 -1
- package/dist/nodes/Telegram/Telegram.node.js.map +1 -1
- package/dist/nodes/Transform/Sort/Sort.node.js +2 -2
- package/dist/nodes/Transform/Sort/Sort.node.js.map +1 -1
- package/dist/types/credentials.json +3 -2
- package/dist/types/nodes.json +7 -6
- package/package.json +12 -9
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var Perplexity_node_exports = {};
|
|
20
|
+
__export(Perplexity_node_exports, {
|
|
21
|
+
Perplexity: () => Perplexity
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(Perplexity_node_exports);
|
|
24
|
+
var import_n8n_workflow = require("n8n-workflow");
|
|
25
|
+
var import_descriptions = require("./descriptions");
|
|
26
|
+
class Perplexity {
|
|
27
|
+
constructor() {
|
|
28
|
+
this.description = {
|
|
29
|
+
displayName: "Perplexity",
|
|
30
|
+
name: "perplexity",
|
|
31
|
+
icon: {
|
|
32
|
+
light: "file:perplexity.svg",
|
|
33
|
+
dark: "file:perplexity.dark.svg"
|
|
34
|
+
},
|
|
35
|
+
group: ["transform"],
|
|
36
|
+
version: 1,
|
|
37
|
+
subtitle: '={{ $parameter["operation"] + ": " + $parameter["resource"] }}',
|
|
38
|
+
description: "Interact with the Perplexity API to generate AI responses with citations",
|
|
39
|
+
defaults: {
|
|
40
|
+
name: "Perplexity"
|
|
41
|
+
},
|
|
42
|
+
inputs: [import_n8n_workflow.NodeConnectionTypes.Main],
|
|
43
|
+
outputs: [import_n8n_workflow.NodeConnectionTypes.Main],
|
|
44
|
+
usableAsTool: true,
|
|
45
|
+
credentials: [
|
|
46
|
+
{
|
|
47
|
+
name: "perplexityApi",
|
|
48
|
+
required: true
|
|
49
|
+
}
|
|
50
|
+
],
|
|
51
|
+
requestDefaults: {
|
|
52
|
+
baseURL: "https://api.perplexity.ai",
|
|
53
|
+
ignoreHttpStatusErrors: true
|
|
54
|
+
},
|
|
55
|
+
properties: [
|
|
56
|
+
{
|
|
57
|
+
displayName: "Resource",
|
|
58
|
+
name: "resource",
|
|
59
|
+
type: "hidden",
|
|
60
|
+
noDataExpression: true,
|
|
61
|
+
options: [
|
|
62
|
+
{
|
|
63
|
+
name: "Chat",
|
|
64
|
+
value: "chat"
|
|
65
|
+
}
|
|
66
|
+
],
|
|
67
|
+
default: "chat"
|
|
68
|
+
},
|
|
69
|
+
...import_descriptions.chat.description
|
|
70
|
+
]
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
75
|
+
0 && (module.exports = {
|
|
76
|
+
Perplexity
|
|
77
|
+
});
|
|
78
|
+
//# sourceMappingURL=Perplexity.node.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../nodes/Perplexity/Perplexity.node.ts"],"sourcesContent":["import type { INodeType, INodeTypeDescription } from 'n8n-workflow';\nimport { NodeConnectionTypes } from 'n8n-workflow';\n\nimport { chat } from './descriptions';\n\nexport class Perplexity implements INodeType {\n\tdescription: INodeTypeDescription = {\n\t\tdisplayName: 'Perplexity',\n\t\tname: 'perplexity',\n\t\ticon: {\n\t\t\tlight: 'file:perplexity.svg',\n\t\t\tdark: 'file:perplexity.dark.svg',\n\t\t},\n\t\tgroup: ['transform'],\n\t\tversion: 1,\n\t\tsubtitle: '={{ $parameter[\"operation\"] + \": \" + $parameter[\"resource\"] }}',\n\t\tdescription: 'Interact with the Perplexity API to generate AI responses with citations',\n\t\tdefaults: {\n\t\t\tname: 'Perplexity',\n\t\t},\n\t\tinputs: [NodeConnectionTypes.Main],\n\t\toutputs: [NodeConnectionTypes.Main],\n\t\tusableAsTool: true,\n\t\tcredentials: [\n\t\t\t{\n\t\t\t\tname: 'perplexityApi',\n\t\t\t\trequired: true,\n\t\t\t},\n\t\t],\n\t\trequestDefaults: {\n\t\t\tbaseURL: 'https://api.perplexity.ai',\n\t\t\tignoreHttpStatusErrors: true,\n\t\t},\n\t\tproperties: [\n\t\t\t{\n\t\t\t\tdisplayName: 'Resource',\n\t\t\t\tname: 'resource',\n\t\t\t\ttype: 'hidden',\n\t\t\t\tnoDataExpression: true,\n\t\t\t\toptions: [\n\t\t\t\t\t{\n\t\t\t\t\t\tname: 'Chat',\n\t\t\t\t\t\tvalue: 'chat',\n\t\t\t\t\t},\n\t\t\t\t],\n\t\t\t\tdefault: 'chat',\n\t\t\t},\n\t\t\t...chat.description,\n\t\t],\n\t};\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,0BAAoC;AAEpC,0BAAqB;AAEd,MAAM,WAAgC;AAAA,EAAtC;AACN,uBAAoC;AAAA,MACnC,aAAa;AAAA,MACb,MAAM;AAAA,MACN,MAAM;AAAA,QACL,OAAO;AAAA,QACP,MAAM;AAAA,MACP;AAAA,MACA,OAAO,CAAC,WAAW;AAAA,MACnB,SAAS;AAAA,MACT,UAAU;AAAA,MACV,aAAa;AAAA,MACb,UAAU;AAAA,QACT,MAAM;AAAA,MACP;AAAA,MACA,QAAQ,CAAC,wCAAoB,IAAI;AAAA,MACjC,SAAS,CAAC,wCAAoB,IAAI;AAAA,MAClC,cAAc;AAAA,MACd,aAAa;AAAA,QACZ;AAAA,UACC,MAAM;AAAA,UACN,UAAU;AAAA,QACX;AAAA,MACD;AAAA,MACA,iBAAiB;AAAA,QAChB,SAAS;AAAA,QACT,wBAAwB;AAAA,MACzB;AAAA,MACA,YAAY;AAAA,QACX;AAAA,UACC,aAAa;AAAA,UACb,MAAM;AAAA,UACN,MAAM;AAAA,UACN,kBAAkB;AAAA,UAClB,SAAS;AAAA,YACR;AAAA,cACC,MAAM;AAAA,cACN,OAAO;AAAA,YACR;AAAA,UACD;AAAA,UACA,SAAS;AAAA,QACV;AAAA,QACA,GAAG,yBAAK;AAAA,MACT;AAAA,IACD;AAAA;AACD;","names":[]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
{
|
|
2
|
+
"node": "n8n-nodes-base.perplexity",
|
|
3
|
+
"nodeVersion": "1.0",
|
|
4
|
+
"codexVersion": "1.0",
|
|
5
|
+
"categories": ["Utility"],
|
|
6
|
+
"resources": {
|
|
7
|
+
"credentialDocumentation": [
|
|
8
|
+
{
|
|
9
|
+
"url": "https://docs.n8n.io/integrations/builtin/credentials/perplexity/"
|
|
10
|
+
}
|
|
11
|
+
],
|
|
12
|
+
"primaryDocumentation": [
|
|
13
|
+
{
|
|
14
|
+
"url": "https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-langchain.perplexity/"
|
|
15
|
+
}
|
|
16
|
+
]
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var Chat_resource_exports = {};
|
|
30
|
+
__export(Chat_resource_exports, {
|
|
31
|
+
description: () => description
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(Chat_resource_exports);
|
|
34
|
+
var complete = __toESM(require("./complete.operation"));
|
|
35
|
+
var import_GenericFunctions = require("../../GenericFunctions");
|
|
36
|
+
const description = [
|
|
37
|
+
{
|
|
38
|
+
displayName: "Operation",
|
|
39
|
+
name: "operation",
|
|
40
|
+
type: "options",
|
|
41
|
+
noDataExpression: true,
|
|
42
|
+
displayOptions: {
|
|
43
|
+
show: {
|
|
44
|
+
resource: ["chat"]
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
options: [
|
|
48
|
+
{
|
|
49
|
+
name: "Message a Model",
|
|
50
|
+
value: "complete",
|
|
51
|
+
action: "Message a model",
|
|
52
|
+
description: "Create one or more completions for a given text",
|
|
53
|
+
routing: {
|
|
54
|
+
request: {
|
|
55
|
+
method: "POST",
|
|
56
|
+
url: "/chat/completions"
|
|
57
|
+
},
|
|
58
|
+
output: {
|
|
59
|
+
postReceive: [import_GenericFunctions.sendErrorPostReceive]
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
default: "complete"
|
|
65
|
+
},
|
|
66
|
+
...complete.description
|
|
67
|
+
];
|
|
68
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
69
|
+
0 && (module.exports = {
|
|
70
|
+
description
|
|
71
|
+
});
|
|
72
|
+
//# sourceMappingURL=Chat.resource.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../nodes/Perplexity/descriptions/chat/Chat.resource.ts"],"sourcesContent":["import type { INodeProperties } from 'n8n-workflow';\n\nimport * as complete from './complete.operation';\nimport { sendErrorPostReceive } from '../../GenericFunctions';\n\nexport const description: INodeProperties[] = [\n\t{\n\t\tdisplayName: 'Operation',\n\t\tname: 'operation',\n\t\ttype: 'options',\n\t\tnoDataExpression: true,\n\t\tdisplayOptions: {\n\t\t\tshow: {\n\t\t\t\tresource: ['chat'],\n\t\t\t},\n\t\t},\n\t\toptions: [\n\t\t\t{\n\t\t\t\tname: 'Message a Model',\n\t\t\t\tvalue: 'complete',\n\t\t\t\taction: 'Message a model',\n\t\t\t\tdescription: 'Create one or more completions for a given text',\n\t\t\t\trouting: {\n\t\t\t\t\trequest: {\n\t\t\t\t\t\tmethod: 'POST',\n\t\t\t\t\t\turl: '/chat/completions',\n\t\t\t\t\t},\n\t\t\t\t\toutput: {\n\t\t\t\t\t\tpostReceive: [sendErrorPostReceive],\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t],\n\t\tdefault: 'complete',\n\t},\n\n\t...complete.description,\n];\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAEA,eAA0B;AAC1B,8BAAqC;AAE9B,MAAM,cAAiC;AAAA,EAC7C;AAAA,IACC,aAAa;AAAA,IACb,MAAM;AAAA,IACN,MAAM;AAAA,IACN,kBAAkB;AAAA,IAClB,gBAAgB;AAAA,MACf,MAAM;AAAA,QACL,UAAU,CAAC,MAAM;AAAA,MAClB;AAAA,IACD;AAAA,IACA,SAAS;AAAA,MACR;AAAA,QACC,MAAM;AAAA,QACN,OAAO;AAAA,QACP,QAAQ;AAAA,QACR,aAAa;AAAA,QACb,SAAS;AAAA,UACR,SAAS;AAAA,YACR,QAAQ;AAAA,YACR,KAAK;AAAA,UACN;AAAA,UACA,QAAQ;AAAA,YACP,aAAa,CAAC,4CAAoB;AAAA,UACnC;AAAA,QACD;AAAA,MACD;AAAA,IACD;AAAA,IACA,SAAS;AAAA,EACV;AAAA,EAEA,GAAG,SAAS;AACb;","names":[]}
|
|
@@ -0,0 +1,328 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var complete_operation_exports = {};
|
|
20
|
+
__export(complete_operation_exports, {
|
|
21
|
+
description: () => description
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(complete_operation_exports);
|
|
24
|
+
var import_n8n_workflow = require("n8n-workflow");
|
|
25
|
+
const properties = [
|
|
26
|
+
{
|
|
27
|
+
displayName: "Model",
|
|
28
|
+
name: "model",
|
|
29
|
+
type: "options",
|
|
30
|
+
default: "r1-1776",
|
|
31
|
+
required: true,
|
|
32
|
+
options: [
|
|
33
|
+
{ name: "R1-1776", value: "r1-1776" },
|
|
34
|
+
{ name: "Sonar", value: "sonar" },
|
|
35
|
+
{ name: "Sonar Deep Research", value: "sonar-deep-research" },
|
|
36
|
+
{ name: "Sonar Pro", value: "sonar-pro" },
|
|
37
|
+
{ name: "Sonar Reasoning", value: "sonar-reasoning" },
|
|
38
|
+
{ name: "Sonar Reasoning Pro", value: "sonar-reasoning-pro" }
|
|
39
|
+
],
|
|
40
|
+
description: "The model which will generate the completion",
|
|
41
|
+
routing: {
|
|
42
|
+
send: {
|
|
43
|
+
type: "body",
|
|
44
|
+
property: "model"
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
displayName: "Messages",
|
|
50
|
+
name: "messages",
|
|
51
|
+
type: "fixedCollection",
|
|
52
|
+
description: "Any optional system messages must be sent first, followed by alternating user and assistant messages",
|
|
53
|
+
required: true,
|
|
54
|
+
typeOptions: {
|
|
55
|
+
multipleValues: true,
|
|
56
|
+
sortable: true
|
|
57
|
+
},
|
|
58
|
+
placeholder: "Add Message",
|
|
59
|
+
default: {
|
|
60
|
+
message: [
|
|
61
|
+
{
|
|
62
|
+
role: "user",
|
|
63
|
+
content: ""
|
|
64
|
+
}
|
|
65
|
+
]
|
|
66
|
+
},
|
|
67
|
+
options: [
|
|
68
|
+
{
|
|
69
|
+
displayName: "Message",
|
|
70
|
+
name: "message",
|
|
71
|
+
values: [
|
|
72
|
+
{
|
|
73
|
+
displayName: "Text",
|
|
74
|
+
name: "content",
|
|
75
|
+
type: "string",
|
|
76
|
+
default: "",
|
|
77
|
+
description: "The content of the message to be sent",
|
|
78
|
+
typeOptions: {
|
|
79
|
+
rows: 2
|
|
80
|
+
}
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
displayName: "Role",
|
|
84
|
+
name: "role",
|
|
85
|
+
required: true,
|
|
86
|
+
type: "options",
|
|
87
|
+
options: [
|
|
88
|
+
{
|
|
89
|
+
name: "Assistant",
|
|
90
|
+
value: "assistant",
|
|
91
|
+
description: "Tell the model to adopt a specific tone or personality. Must alternate with user messages."
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
name: "System",
|
|
95
|
+
value: "system",
|
|
96
|
+
description: "Set the models behavior or context. Must come before user and assistant messages."
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
name: "User",
|
|
100
|
+
value: "user",
|
|
101
|
+
description: "Send a message as a user and get a response from the model"
|
|
102
|
+
}
|
|
103
|
+
],
|
|
104
|
+
default: "user",
|
|
105
|
+
description: "Role in shaping the model's response, it tells the model how it should behave and interact with the user"
|
|
106
|
+
}
|
|
107
|
+
]
|
|
108
|
+
}
|
|
109
|
+
],
|
|
110
|
+
routing: {
|
|
111
|
+
send: {
|
|
112
|
+
type: "body",
|
|
113
|
+
property: "messages",
|
|
114
|
+
value: "={{ $value.message }}"
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
displayName: "Simplify Output",
|
|
120
|
+
name: "simplify",
|
|
121
|
+
type: "boolean",
|
|
122
|
+
default: false,
|
|
123
|
+
description: "Whether to return only essential fields (ID, citations, message)",
|
|
124
|
+
routing: {
|
|
125
|
+
output: {
|
|
126
|
+
postReceive: [
|
|
127
|
+
{
|
|
128
|
+
type: "set",
|
|
129
|
+
enabled: "={{ $value }}",
|
|
130
|
+
properties: {
|
|
131
|
+
value: '={{ { "id": $response.body?.id, "created": $response.body?.created, "citations": $response.body?.citations, "message": $response.body?.choices?.[0]?.message?.content } }}'
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
]
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
displayName: "Options",
|
|
140
|
+
name: "options",
|
|
141
|
+
type: "collection",
|
|
142
|
+
placeholder: "Add Option",
|
|
143
|
+
default: {},
|
|
144
|
+
options: [
|
|
145
|
+
{
|
|
146
|
+
displayName: "Frequency Penalty",
|
|
147
|
+
name: "frequencyPenalty",
|
|
148
|
+
type: "number",
|
|
149
|
+
default: 1,
|
|
150
|
+
typeOptions: {
|
|
151
|
+
minValue: 1
|
|
152
|
+
},
|
|
153
|
+
description: "Values greater than 1.0 penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim",
|
|
154
|
+
routing: {
|
|
155
|
+
send: {
|
|
156
|
+
type: "body",
|
|
157
|
+
property: "frequency_penalty"
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
displayName: "Maximum Number of Tokens",
|
|
163
|
+
name: "maxTokens",
|
|
164
|
+
type: "number",
|
|
165
|
+
default: 1,
|
|
166
|
+
description: "The maximum number of tokens to generate in the completion. The number of tokens requested plus the number of prompt tokens sent in messages must not exceed the context window token limit of model requested.",
|
|
167
|
+
routing: {
|
|
168
|
+
send: {
|
|
169
|
+
type: "body",
|
|
170
|
+
property: "max_tokens"
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
displayName: "Output Randomness (Temperature)",
|
|
176
|
+
name: "temperature",
|
|
177
|
+
type: "number",
|
|
178
|
+
default: 0.2,
|
|
179
|
+
description: "The amount of randomness in the response, valued between 0 inclusive and 2 exclusive. Higher values are more random, and lower values are more deterministic.",
|
|
180
|
+
typeOptions: {
|
|
181
|
+
minValue: 0,
|
|
182
|
+
maxValue: 1.99
|
|
183
|
+
},
|
|
184
|
+
routing: {
|
|
185
|
+
send: {
|
|
186
|
+
type: "body",
|
|
187
|
+
property: "temperature"
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
displayName: "Top K",
|
|
193
|
+
name: "topK",
|
|
194
|
+
type: "number",
|
|
195
|
+
default: 0,
|
|
196
|
+
description: "The number of tokens to keep for highest Top K filtering, specified as an integer between 0 and 2048 inclusive. If set to 0, Top K filtering is disabled. We recommend either altering Top K or Top P, but not both.",
|
|
197
|
+
typeOptions: {
|
|
198
|
+
minValue: 0,
|
|
199
|
+
maxValue: 2048
|
|
200
|
+
},
|
|
201
|
+
routing: {
|
|
202
|
+
send: {
|
|
203
|
+
type: "body",
|
|
204
|
+
property: "top_k"
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
displayName: "Top P",
|
|
210
|
+
name: "topP",
|
|
211
|
+
type: "number",
|
|
212
|
+
default: 0.9,
|
|
213
|
+
description: "The nucleus sampling threshold, valued between 0 and 1 inclusive. For each subsequent token, the model considers the results of the tokens with Top P probability mass. We recommend either altering Top K or Top P, but not both.",
|
|
214
|
+
typeOptions: {
|
|
215
|
+
minValue: 0,
|
|
216
|
+
maxValue: 1
|
|
217
|
+
},
|
|
218
|
+
routing: {
|
|
219
|
+
send: {
|
|
220
|
+
type: "body",
|
|
221
|
+
property: "top_p"
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
},
|
|
225
|
+
{
|
|
226
|
+
displayName: "Presence Penalty",
|
|
227
|
+
name: "presencePenalty",
|
|
228
|
+
type: "number",
|
|
229
|
+
default: 0,
|
|
230
|
+
description: "A value between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics.",
|
|
231
|
+
typeOptions: {
|
|
232
|
+
minValue: -2,
|
|
233
|
+
maxValue: 2
|
|
234
|
+
},
|
|
235
|
+
routing: {
|
|
236
|
+
send: {
|
|
237
|
+
type: "body",
|
|
238
|
+
property: "presence_penalty"
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
},
|
|
242
|
+
{
|
|
243
|
+
displayName: "Return Images",
|
|
244
|
+
name: "returnImages",
|
|
245
|
+
type: "boolean",
|
|
246
|
+
default: false,
|
|
247
|
+
description: "Whether or not a request to an online model should return images. Requires Perplexity API usage Tier-2.",
|
|
248
|
+
routing: {
|
|
249
|
+
send: {
|
|
250
|
+
type: "body",
|
|
251
|
+
property: "return_images"
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
},
|
|
255
|
+
{
|
|
256
|
+
displayName: "Return Related Questions",
|
|
257
|
+
name: "returnRelatedQuestions",
|
|
258
|
+
type: "boolean",
|
|
259
|
+
default: false,
|
|
260
|
+
description: "Whether or not a request to an online model should return related questions. Requires Perplexity API usage Tier-2.",
|
|
261
|
+
routing: {
|
|
262
|
+
send: {
|
|
263
|
+
type: "body",
|
|
264
|
+
property: "return_related_questions"
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
displayName: "Search Domain Filter",
|
|
270
|
+
name: "searchDomainFilter",
|
|
271
|
+
type: "string",
|
|
272
|
+
default: "",
|
|
273
|
+
description: "Limit the citations used by the online model to URLs from the specified domains. For blacklisting, add a <code>-</code> to the beginning of the domain string (e.g., <code>-domain1</code>). Currently limited to 3 domains. Requires Perplexity API usage Tier-3.",
|
|
274
|
+
placeholder: "e.g. domain1,domain2,-domain3",
|
|
275
|
+
routing: {
|
|
276
|
+
send: {
|
|
277
|
+
type: "body",
|
|
278
|
+
property: "search_domain_filter",
|
|
279
|
+
value: '={{ $value.split(",").map(domain => domain.trim()) }}'
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
displayName: "Search Recency Filter",
|
|
285
|
+
name: "searchRecency",
|
|
286
|
+
type: "options",
|
|
287
|
+
options: [
|
|
288
|
+
{
|
|
289
|
+
name: "Day",
|
|
290
|
+
value: "day"
|
|
291
|
+
},
|
|
292
|
+
{
|
|
293
|
+
name: "Hour",
|
|
294
|
+
value: "hour"
|
|
295
|
+
},
|
|
296
|
+
{
|
|
297
|
+
name: "Month",
|
|
298
|
+
value: "month"
|
|
299
|
+
},
|
|
300
|
+
{
|
|
301
|
+
name: "Week",
|
|
302
|
+
value: "week"
|
|
303
|
+
}
|
|
304
|
+
],
|
|
305
|
+
default: "month",
|
|
306
|
+
description: "Returns search results within the specified time interval",
|
|
307
|
+
routing: {
|
|
308
|
+
send: {
|
|
309
|
+
type: "body",
|
|
310
|
+
property: "search_recency"
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
}
|
|
314
|
+
]
|
|
315
|
+
}
|
|
316
|
+
];
|
|
317
|
+
const displayOptions = {
|
|
318
|
+
show: {
|
|
319
|
+
resource: ["chat"],
|
|
320
|
+
operation: ["complete"]
|
|
321
|
+
}
|
|
322
|
+
};
|
|
323
|
+
const description = (0, import_n8n_workflow.updateDisplayOptions)(displayOptions, properties);
|
|
324
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
325
|
+
0 && (module.exports = {
|
|
326
|
+
description
|
|
327
|
+
});
|
|
328
|
+
//# sourceMappingURL=complete.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../nodes/Perplexity/descriptions/chat/complete.operation.ts"],"sourcesContent":["import type { INodeProperties } from 'n8n-workflow';\nimport { updateDisplayOptions } from 'n8n-workflow';\n\nconst properties: INodeProperties[] = [\n\t{\n\t\tdisplayName: 'Model',\n\t\tname: 'model',\n\t\ttype: 'options',\n\t\tdefault: 'r1-1776',\n\t\trequired: true,\n\t\toptions: [\n\t\t\t{ name: 'R1-1776', value: 'r1-1776' },\n\t\t\t{ name: 'Sonar', value: 'sonar' },\n\t\t\t{ name: 'Sonar Deep Research', value: 'sonar-deep-research' },\n\t\t\t{ name: 'Sonar Pro', value: 'sonar-pro' },\n\t\t\t{ name: 'Sonar Reasoning', value: 'sonar-reasoning' },\n\t\t\t{ name: 'Sonar Reasoning Pro', value: 'sonar-reasoning-pro' },\n\t\t],\n\t\tdescription: 'The model which will generate the completion',\n\t\trouting: {\n\t\t\tsend: {\n\t\t\t\ttype: 'body',\n\t\t\t\tproperty: 'model',\n\t\t\t},\n\t\t},\n\t},\n\t{\n\t\tdisplayName: 'Messages',\n\t\tname: 'messages',\n\t\ttype: 'fixedCollection',\n\t\tdescription:\n\t\t\t'Any optional system messages must be sent first, followed by alternating user and assistant messages',\n\t\trequired: true,\n\t\ttypeOptions: {\n\t\t\tmultipleValues: true,\n\t\t\tsortable: true,\n\t\t},\n\t\tplaceholder: 'Add Message',\n\t\tdefault: {\n\t\t\tmessage: [\n\t\t\t\t{\n\t\t\t\t\trole: 'user',\n\t\t\t\t\tcontent: '',\n\t\t\t\t},\n\t\t\t],\n\t\t},\n\t\toptions: [\n\t\t\t{\n\t\t\t\tdisplayName: 'Message',\n\t\t\t\tname: 'message',\n\t\t\t\tvalues: [\n\t\t\t\t\t{\n\t\t\t\t\t\tdisplayName: 'Text',\n\t\t\t\t\t\tname: 'content',\n\t\t\t\t\t\ttype: 'string',\n\t\t\t\t\t\tdefault: '',\n\t\t\t\t\t\tdescription: 'The content of the message to be sent',\n\t\t\t\t\t\ttypeOptions: {\n\t\t\t\t\t\t\trows: 2,\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\tdisplayName: 'Role',\n\t\t\t\t\t\tname: 'role',\n\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\ttype: 'options',\n\t\t\t\t\t\toptions: [\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tname: 'Assistant',\n\t\t\t\t\t\t\t\tvalue: 'assistant',\n\t\t\t\t\t\t\t\tdescription:\n\t\t\t\t\t\t\t\t\t'Tell the model to adopt a specific tone or personality. Must alternate with user messages.',\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tname: 'System',\n\t\t\t\t\t\t\t\tvalue: 'system',\n\t\t\t\t\t\t\t\tdescription:\n\t\t\t\t\t\t\t\t\t'Set the models behavior or context. Must come before user and assistant messages.',\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tname: 'User',\n\t\t\t\t\t\t\t\tvalue: 'user',\n\t\t\t\t\t\t\t\tdescription: 'Send a message as a user and get a response from the model',\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t],\n\t\t\t\t\t\tdefault: 'user',\n\t\t\t\t\t\tdescription:\n\t\t\t\t\t\t\t\"Role in shaping the model's response, it tells the model how it should behave and interact with the user\",\n\t\t\t\t\t},\n\t\t\t\t],\n\t\t\t},\n\t\t],\n\t\trouting: {\n\t\t\tsend: {\n\t\t\t\ttype: 'body',\n\t\t\t\tproperty: 'messages',\n\t\t\t\tvalue: '={{ $value.message }}',\n\t\t\t},\n\t\t},\n\t},\n\t{\n\t\tdisplayName: 'Simplify Output',\n\t\tname: 'simplify',\n\t\ttype: 'boolean',\n\t\tdefault: false,\n\t\tdescription: 'Whether to return only essential fields (ID, citations, message)',\n\t\trouting: {\n\t\t\toutput: {\n\t\t\t\tpostReceive: [\n\t\t\t\t\t{\n\t\t\t\t\t\ttype: 'set',\n\t\t\t\t\t\tenabled: '={{ $value }}',\n\t\t\t\t\t\tproperties: {\n\t\t\t\t\t\t\tvalue:\n\t\t\t\t\t\t\t\t'={{ { \"id\": $response.body?.id, \"created\": $response.body?.created, \"citations\": $response.body?.citations, \"message\": $response.body?.choices?.[0]?.message?.content } }}',\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t],\n\t\t\t},\n\t\t},\n\t},\n\t{\n\t\tdisplayName: 'Options',\n\t\tname: 'options',\n\t\ttype: 'collection',\n\t\tplaceholder: 'Add Option',\n\t\tdefault: {},\n\t\toptions: [\n\t\t\t{\n\t\t\t\tdisplayName: 'Frequency Penalty',\n\t\t\t\tname: 'frequencyPenalty',\n\t\t\t\ttype: 'number',\n\t\t\t\tdefault: 1,\n\t\t\t\ttypeOptions: {\n\t\t\t\t\tminValue: 1,\n\t\t\t\t},\n\t\t\t\tdescription:\n\t\t\t\t\t\"Values greater than 1.0 penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim\",\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'frequency_penalty',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Maximum Number of Tokens',\n\t\t\t\tname: 'maxTokens',\n\t\t\t\ttype: 'number',\n\t\t\t\tdefault: 1,\n\t\t\t\tdescription:\n\t\t\t\t\t'The maximum number of tokens to generate in the completion. The number of tokens requested plus the number of prompt tokens sent in messages must not exceed the context window token limit of model requested.',\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'max_tokens',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Output Randomness (Temperature)',\n\t\t\t\tname: 'temperature',\n\t\t\t\ttype: 'number',\n\t\t\t\tdefault: 0.2,\n\t\t\t\tdescription:\n\t\t\t\t\t'The amount of randomness in the response, valued between 0 inclusive and 2 exclusive. Higher values are more random, and lower values are more deterministic.',\n\t\t\t\ttypeOptions: {\n\t\t\t\t\tminValue: 0,\n\t\t\t\t\tmaxValue: 1.99,\n\t\t\t\t},\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'temperature',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Top K',\n\t\t\t\tname: 'topK',\n\t\t\t\ttype: 'number',\n\t\t\t\tdefault: 0,\n\t\t\t\tdescription:\n\t\t\t\t\t'The number of tokens to keep for highest Top K filtering, specified as an integer between 0 and 2048 inclusive. If set to 0, Top K filtering is disabled. We recommend either altering Top K or Top P, but not both.',\n\t\t\t\ttypeOptions: {\n\t\t\t\t\tminValue: 0,\n\t\t\t\t\tmaxValue: 2048,\n\t\t\t\t},\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'top_k',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Top P',\n\t\t\t\tname: 'topP',\n\t\t\t\ttype: 'number',\n\t\t\t\tdefault: 0.9,\n\t\t\t\tdescription:\n\t\t\t\t\t'The nucleus sampling threshold, valued between 0 and 1 inclusive. For each subsequent token, the model considers the results of the tokens with Top P probability mass. We recommend either altering Top K or Top P, but not both.',\n\t\t\t\ttypeOptions: {\n\t\t\t\t\tminValue: 0,\n\t\t\t\t\tmaxValue: 1,\n\t\t\t\t},\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'top_p',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Presence Penalty',\n\t\t\t\tname: 'presencePenalty',\n\t\t\t\ttype: 'number',\n\t\t\t\tdefault: 0,\n\t\t\t\tdescription:\n\t\t\t\t\t\"A value between -2.0 and 2.0. Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics.\",\n\t\t\t\ttypeOptions: {\n\t\t\t\t\tminValue: -2.0,\n\t\t\t\t\tmaxValue: 2.0,\n\t\t\t\t},\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'presence_penalty',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Return Images',\n\t\t\t\tname: 'returnImages',\n\t\t\t\ttype: 'boolean',\n\t\t\t\tdefault: false,\n\t\t\t\tdescription:\n\t\t\t\t\t'Whether or not a request to an online model should return images. Requires Perplexity API usage Tier-2.',\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'return_images',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Return Related Questions',\n\t\t\t\tname: 'returnRelatedQuestions',\n\t\t\t\ttype: 'boolean',\n\t\t\t\tdefault: false,\n\t\t\t\tdescription:\n\t\t\t\t\t'Whether or not a request to an online model should return related questions. Requires Perplexity API usage Tier-2.',\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'return_related_questions',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Search Domain Filter',\n\t\t\t\tname: 'searchDomainFilter',\n\t\t\t\ttype: 'string',\n\t\t\t\tdefault: '',\n\t\t\t\tdescription:\n\t\t\t\t\t'Limit the citations used by the online model to URLs from the specified domains. For blacklisting, add a <code>-</code> to the beginning of the domain string (e.g., <code>-domain1</code>). Currently limited to 3 domains. Requires Perplexity API usage Tier-3.',\n\t\t\t\tplaceholder: 'e.g. domain1,domain2,-domain3',\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'search_domain_filter',\n\t\t\t\t\t\tvalue: '={{ $value.split(\",\").map(domain => domain.trim()) }}',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdisplayName: 'Search Recency Filter',\n\t\t\t\tname: 'searchRecency',\n\t\t\t\ttype: 'options',\n\t\t\t\toptions: [\n\t\t\t\t\t{\n\t\t\t\t\t\tname: 'Day',\n\t\t\t\t\t\tvalue: 'day',\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\tname: 'Hour',\n\t\t\t\t\t\tvalue: 'hour',\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\tname: 'Month',\n\t\t\t\t\t\tvalue: 'month',\n\t\t\t\t\t},\n\t\t\t\t\t{\n\t\t\t\t\t\tname: 'Week',\n\t\t\t\t\t\tvalue: 'week',\n\t\t\t\t\t},\n\t\t\t\t],\n\t\t\t\tdefault: 'month',\n\t\t\t\tdescription: 'Returns search results within the specified time interval',\n\t\t\t\trouting: {\n\t\t\t\t\tsend: {\n\t\t\t\t\t\ttype: 'body',\n\t\t\t\t\t\tproperty: 'search_recency',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t],\n\t},\n];\n\nconst displayOptions = {\n\tshow: {\n\t\tresource: ['chat'],\n\t\toperation: ['complete'],\n\t},\n};\n\nexport const description = updateDisplayOptions(displayOptions, properties);\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,0BAAqC;AAErC,MAAM,aAAgC;AAAA,EACrC;AAAA,IACC,aAAa;AAAA,IACb,MAAM;AAAA,IACN,MAAM;AAAA,IACN,SAAS;AAAA,IACT,UAAU;AAAA,IACV,SAAS;AAAA,MACR,EAAE,MAAM,WAAW,OAAO,UAAU;AAAA,MACpC,EAAE,MAAM,SAAS,OAAO,QAAQ;AAAA,MAChC,EAAE,MAAM,uBAAuB,OAAO,sBAAsB;AAAA,MAC5D,EAAE,MAAM,aAAa,OAAO,YAAY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U;AAAA,YACV,OAAO;AAAA,UACR;AAAA,QACD;AAAA,MACD;AAAA,MACA;AAAA,QACC,aAAa;AAAA,QACb,MAAM;AAAA,QACN,MAAM;AAAA,QACN,SAAS;AAAA,UACR;AAAA,YACC,MAAM;AAAA,YACN,OAAO;AAAA,UACR;AAAA,UACA;AAAA,YACC,MAAM;AAAA,YACN,OAAO;AAAA,UACR;AAAA,UACA;AAAA,YACC,MAAM;AAAA,YACN,OAAO;AAAA,UACR;AAAA,UACA;AAAA,YACC,MAAM;AAAA,YACN,OAAO;AAAA,UACR;AAAA,QACD;AAAA,QACA,SAAS;AAAA,QACT,aAAa;AAAA,QACb,SAAS;AAAA,UACR,MAAM;AAAA,YACL,MAAM;AAAA,YACN,UAAU;AAAA,UACX;AAAA,QACD;AAAA,MACD;AAAA,IACD;AAAA,EACD;AACD;AAEA,MAAM,iBAAiB;AAAA,EACtB,MAAM;AAAA,IACL,UAAU,CAAC,MAAM;AAAA,IACjB,WAAW,CAAC,UAAU;AAAA,EACvB;AACD;AAEO,MAAM,kBAAc,0CAAqB,gBAAgB,UAAU;","names":[]}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var descriptions_exports = {};
|
|
30
|
+
__export(descriptions_exports, {
|
|
31
|
+
chat: () => chat
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(descriptions_exports);
|
|
34
|
+
var chat = __toESM(require("./chat/Chat.resource"));
|
|
35
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
36
|
+
0 && (module.exports = {
|
|
37
|
+
chat
|
|
38
|
+
});
|
|
39
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../nodes/Perplexity/descriptions/index.ts"],"sourcesContent":["export * as chat from './chat/Chat.resource';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,WAAsB;","names":[]}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
<?xml version="1.0" standalone="no"?>
|
|
2
|
+
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
|
|
3
|
+
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
|
|
4
|
+
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
|
|
5
|
+
width="270.000000pt" height="270.000000pt" viewBox="0 0 270.000000 270.000000"
|
|
6
|
+
preserveAspectRatio="xMidYMid meet">
|
|
7
|
+
<metadata>
|
|
8
|
+
Created by potrace 1.14, written by Peter Selinger 2001-2017
|
|
9
|
+
</metadata>
|
|
10
|
+
<g transform="translate(0.000000,270.000000) scale(0.100000,-0.100000)"
|
|
11
|
+
fill="#000000" stroke="none">
|
|
12
|
+
<path d="M185 2691 c-86 -21 -158 -93 -175 -175 -7 -35 -10 -415 -8 -1196 3
|
|
13
|
+
-1276 -2 -1180 73 -1253 20 -20 54 -42 74 -49 53 -19 2349 -19 2402 0 20 7 54
|
|
14
|
+
29 74 49 75 73 70 -23 73 1253 2 817 -1 1161 -9 1200 -9 46 -19 63 -64 106
|
|
15
|
+
-42 41 -63 54 -104 63 -59 13 -2284 14 -2336 2z m786 -547 l314 -255 3 255 2
|
|
16
|
+
256 60 0 60 0 2 -255 3 -256 315 257 315 257 3 -292 2 -291 135 0 135 0 0
|
|
17
|
+
-450 0 -450 -135 0 -135 0 -2 -296 -3 -295 -312 275 c-172 152 -315 276 -318
|
|
18
|
+
276 -3 0 -5 -133 -5 -295 l0 -295 -60 0 -60 0 0 295 c0 162 -2 295 -5 295 -3
|
|
19
|
+
0 -146 -124 -318 -276 l-312 -276 -3 296 -2 296 -135 0 -135 0 0 450 0 450
|
|
20
|
+
135 0 135 0 0 290 c0 160 2 290 4 290 2 0 145 -115 317 -256z"/>
|
|
21
|
+
<path d="M780 1981 l0 -161 215 0 216 0 -203 151 c-112 84 -209 156 -215 162
|
|
22
|
+
-10 7 -13 -24 -13 -152z"/>
|
|
23
|
+
<path d="M1706 1982 l-210 -157 209 -3 c114 -1 210 -1 212 1 2 2 2 74 1 160
|
|
24
|
+
l-3 156 -209 -157z"/>
|
|
25
|
+
<path d="M510 1370 l0 -330 70 0 70 0 0 88 0 88 38 35 c20 20 146 127 280 239
|
|
26
|
+
133 111 242 204 242 206 0 2 -157 4 -350 4 l-350 0 0 -330z"/>
|
|
27
|
+
<path d="M1490 1696 c0 -2 126 -102 280 -223 l280 -218 0 -107 0 -108 70 0 70
|
|
28
|
+
0 0 330 0 330 -350 0 c-192 0 -350 -2 -350 -4z"/>
|
|
29
|
+
<path d="M1028 1392 l-247 -217 0 -283 c-1 -233 1 -282 12 -275 8 4 122 104
|
|
30
|
+
255 222 l242 214 0 278 c0 154 -3 279 -7 279 -5 0 -119 -98 -255 -218z"/>
|
|
31
|
+
<path d="M1410 1332 l0 -279 242 -214 c133 -118 247 -218 255 -222 11 -7 13
|
|
32
|
+
42 12 275 l0 283 -245 215 c-135 118 -249 217 -254 218 -6 2 -10 -101 -10
|
|
33
|
+
-276z"/>
|
|
34
|
+
</g>
|
|
35
|
+
</svg>
|
|
@@ -92,13 +92,13 @@ class RespondToWebhook {
|
|
|
92
92
|
icon: { light: "file:webhook.svg", dark: "file:webhook.dark.svg" },
|
|
93
93
|
name: "respondToWebhook",
|
|
94
94
|
group: ["transform"],
|
|
95
|
-
version: [1, 1.1, 1.2, 1.3],
|
|
95
|
+
version: [1, 1.1, 1.2, 1.3, 1.4],
|
|
96
96
|
description: "Returns data for Webhook",
|
|
97
97
|
defaults: {
|
|
98
98
|
name: "Respond to Webhook"
|
|
99
99
|
},
|
|
100
100
|
inputs: [import_n8n_workflow.NodeConnectionTypes.Main],
|
|
101
|
-
outputs: `={{(${import_utils.configuredOutputs})($nodeVersion)}}`,
|
|
101
|
+
outputs: `={{(${import_utils.configuredOutputs})($nodeVersion, $parameter)}}`,
|
|
102
102
|
credentials: [
|
|
103
103
|
{
|
|
104
104
|
name: "jwtAuth",
|
|
@@ -111,6 +111,15 @@ class RespondToWebhook {
|
|
|
111
111
|
}
|
|
112
112
|
],
|
|
113
113
|
properties: [
|
|
114
|
+
{
|
|
115
|
+
displayName: "Enable Response Output Branch",
|
|
116
|
+
name: "enableResponseOutput",
|
|
117
|
+
type: "boolean",
|
|
118
|
+
default: false,
|
|
119
|
+
description: "Whether to provide an additional output branch with the response sent to the webhook",
|
|
120
|
+
isNodeSetting: true,
|
|
121
|
+
displayOptions: { show: { "@version": [{ _cnd: { gte: 1.4 } }] } }
|
|
122
|
+
},
|
|
114
123
|
{
|
|
115
124
|
displayName: `Verify that the "Webhook" node's "Respond" parameter is set to "Using Respond to Webhook Node". <a href="https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.respondtowebhook/" target="_blank">More details`,
|
|
116
125
|
name: "generalNotice",
|
|
@@ -447,7 +456,9 @@ class RespondToWebhook {
|
|
|
447
456
|
}
|
|
448
457
|
throw error;
|
|
449
458
|
}
|
|
450
|
-
if (nodeVersion
|
|
459
|
+
if (nodeVersion === 1.3) {
|
|
460
|
+
return [items, [{ json: { response } }]];
|
|
461
|
+
} else if (nodeVersion >= 1.4 && this.getNodeParameter("enableResponseOutput", 0, false)) {
|
|
451
462
|
return [items, [{ json: { response } }]];
|
|
452
463
|
}
|
|
453
464
|
return [items];
|