Add Activepieces integration for workflow automation
- Add Activepieces fork with SmoothSchedule custom piece - Create integrations app with Activepieces service layer - Add embed token endpoint for iframe integration - Create Automations page with embedded workflow builder - Add sidebar visibility fix for embed mode - Add list inactive customers endpoint to Public API - Include SmoothSchedule triggers: event created/updated/cancelled - Include SmoothSchedule actions: create/update/cancel events, list resources/services/customers 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"extends": ["../../../../.eslintrc.json"],
|
||||
"ignorePatterns": ["!**/*"],
|
||||
"overrides": [
|
||||
{
|
||||
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
|
||||
"rules": {}
|
||||
},
|
||||
{
|
||||
"files": ["*.ts", "*.tsx"],
|
||||
"rules": {}
|
||||
},
|
||||
{
|
||||
"files": ["*.js", "*.jsx"],
|
||||
"rules": {}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
# pieces-flowise
|
||||
|
||||
This library was generated with [Nx](https://nx.dev).
|
||||
|
||||
## Building
|
||||
|
||||
Run `nx build pieces-flowise` to build the library.
|
||||
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"name": "@activepieces/piece-flowise",
|
||||
"version": "0.0.10",
|
||||
"devDependencies": {
|
||||
"@types/is-url": "^1.2.32"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
{
|
||||
"name": "pieces-flowise",
|
||||
"$schema": "../../../../node_modules/nx/schemas/project-schema.json",
|
||||
"sourceRoot": "packages/pieces/community/flowise/src",
|
||||
"projectType": "library",
|
||||
"targets": {
|
||||
"build": {
|
||||
"executor": "@nx/js:tsc",
|
||||
"outputs": [
|
||||
"{options.outputPath}"
|
||||
],
|
||||
"options": {
|
||||
"outputPath": "dist/packages/pieces/community/flowise",
|
||||
"tsConfig": "packages/pieces/community/flowise/tsconfig.lib.json",
|
||||
"packageJson": "packages/pieces/community/flowise/package.json",
|
||||
"main": "packages/pieces/community/flowise/src/index.ts",
|
||||
"assets": [
|
||||
"packages/pieces/community/flowise/*.md",
|
||||
{
|
||||
"input": "packages/pieces/community/flowise/src/i18n",
|
||||
"output": "./src/i18n",
|
||||
"glob": "**/!(i18n.json)"
|
||||
}
|
||||
],
|
||||
"buildableProjectDepsInPackageJsonType": "dependencies",
|
||||
"updateBuildableProjectDepsInPackageJson": true
|
||||
},
|
||||
"dependsOn": [
|
||||
"^build",
|
||||
"prebuild"
|
||||
]
|
||||
},
|
||||
"publish": {
|
||||
"command": "node tools/scripts/publish.mjs pieces-flowise {args.ver} {args.tag}",
|
||||
"dependsOn": [
|
||||
"build"
|
||||
]
|
||||
},
|
||||
"lint": {
|
||||
"executor": "@nx/eslint:lint",
|
||||
"outputs": [
|
||||
"{options.outputFile}"
|
||||
]
|
||||
},
|
||||
"prebuild": {
|
||||
"executor": "nx:run-commands",
|
||||
"options": {
|
||||
"cwd": "packages/pieces/community/flowise",
|
||||
"command": "bun install --no-save --silent"
|
||||
},
|
||||
"dependsOn": [
|
||||
"^build"
|
||||
]
|
||||
}
|
||||
},
|
||||
"tags": []
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"No-Code AI workflow builder": "No-Code AI Workflow-Builder",
|
||||
"Base URL": "Basis-URL",
|
||||
"API Key": "API-Schlüssel",
|
||||
"Enter the base URL": "Basis-URL eingeben",
|
||||
"Enter the API Key": "API-Schlüssel eingeben",
|
||||
"Enter your Flowise URL and API Key": "Geben Sie Ihre Flowise URL und API-Schlüssel ein",
|
||||
"Make Prediction": "Vorhersage machen",
|
||||
"Custom API Call": "Eigener API-Aufruf",
|
||||
"Run Flowise Predict": "Flowise Vorhersage ausführen",
|
||||
"Make a custom API call to a specific endpoint": "Einen benutzerdefinierten API-Aufruf an einen bestimmten Endpunkt machen",
|
||||
"Chatflow ID": "Chatflow-ID",
|
||||
"Input/Question": "Eingabe/Frage",
|
||||
"History": "Verlauf",
|
||||
"Override Config": "Konfiguration überschreiben",
|
||||
"Method": "Methode",
|
||||
"Headers": "Kopfzeilen",
|
||||
"Query Parameters": "Abfrageparameter",
|
||||
"Body": "Körper",
|
||||
"Response is Binary ?": "Antwort ist binär?",
|
||||
"No Error on Failure": "Kein Fehler bei Fehler",
|
||||
"Timeout (in seconds)": "Timeout (in Sekunden)",
|
||||
"Enter the Chatflow ID": "Chatflow ID eingeben",
|
||||
"Enter the Input/Question": "Geben Sie die Eingabe/Frage ein",
|
||||
"Enter the History": "Verlauf eingeben",
|
||||
"Enter the Override Config": "Überschreibungs-Konfiguration eingeben",
|
||||
"Authorization headers are injected automatically from your connection.": "Autorisierungs-Header werden automatisch von Ihrer Verbindung injiziert.",
|
||||
"Enable for files like PDFs, images, etc..": "Aktivieren für Dateien wie PDFs, Bilder, etc..",
|
||||
"GET": "ERHALTEN",
|
||||
"POST": "POST",
|
||||
"PATCH": "PATCH",
|
||||
"PUT": "PUT",
|
||||
"DELETE": "LÖSCHEN",
|
||||
"HEAD": "HEAD"
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"No-Code AI workflow builder": "Constructor de flujo de trabajo AI sin código",
|
||||
"Base URL": "URL base",
|
||||
"API Key": "Clave API",
|
||||
"Enter the base URL": "Introduzca la URL base",
|
||||
"Enter the API Key": "Introduzca la clave API",
|
||||
"Enter your Flowise URL and API Key": "Introduzca su URL de Flowise y clave de API",
|
||||
"Make Prediction": "Hacer predicción",
|
||||
"Custom API Call": "Llamada API personalizada",
|
||||
"Run Flowise Predict": "Ejecutar predicción de Flowise",
|
||||
"Make a custom API call to a specific endpoint": "Hacer una llamada API personalizada a un extremo específico",
|
||||
"Chatflow ID": "ID de Chatflow",
|
||||
"Input/Question": "Entrada/Pregunta",
|
||||
"History": "Historial",
|
||||
"Override Config": "Anular configuración",
|
||||
"Method": "Método",
|
||||
"Headers": "Encabezados",
|
||||
"Query Parameters": "Parámetros de consulta",
|
||||
"Body": "Cuerpo",
|
||||
"Response is Binary ?": "¿Respuesta es binaria?",
|
||||
"No Error on Failure": "No hay ningún error en fallo",
|
||||
"Timeout (in seconds)": "Tiempo de espera (en segundos)",
|
||||
"Enter the Chatflow ID": "Introduzca el ID de Chatflow",
|
||||
"Enter the Input/Question": "Introduzca la entrada/pregunta",
|
||||
"Enter the History": "Ingrese el Historial",
|
||||
"Enter the Override Config": "Introduzca la configuración de sobrescribir",
|
||||
"Authorization headers are injected automatically from your connection.": "Las cabeceras de autorización se inyectan automáticamente desde tu conexión.",
|
||||
"Enable for files like PDFs, images, etc..": "Activar para archivos como PDFs, imágenes, etc.",
|
||||
"GET": "RECOGER",
|
||||
"POST": "POST",
|
||||
"PATCH": "PATCH",
|
||||
"PUT": "PUT",
|
||||
"DELETE": "BORRAR",
|
||||
"HEAD": "LIMPIO"
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"No-Code AI workflow builder": "Constructeur de workflow sans Code AI",
|
||||
"Base URL": "URL de base",
|
||||
"API Key": "Clé API",
|
||||
"Enter the base URL": "Entrez l'URL de base",
|
||||
"Enter the API Key": "Entrez la clé API",
|
||||
"Enter your Flowise URL and API Key": "Entrez votre URL Flowise et votre clé API",
|
||||
"Make Prediction": "Faire de la prédiction",
|
||||
"Custom API Call": "Appel API personnalisé",
|
||||
"Run Flowise Predict": "Lancer Flowise Predict",
|
||||
"Make a custom API call to a specific endpoint": "Passez un appel API personnalisé à un point de terminaison spécifique",
|
||||
"Chatflow ID": "ID du flux de discussion",
|
||||
"Input/Question": "Saisie/Question",
|
||||
"History": "Historique",
|
||||
"Override Config": "Remplacer la configuration",
|
||||
"Method": "Méthode",
|
||||
"Headers": "En-têtes",
|
||||
"Query Parameters": "Paramètres de requête",
|
||||
"Body": "Corps",
|
||||
"Response is Binary ?": "La réponse est Binaire ?",
|
||||
"No Error on Failure": "Aucune erreur en cas d'échec",
|
||||
"Timeout (in seconds)": "Délai d'attente (en secondes)",
|
||||
"Enter the Chatflow ID": "Entrez l'ID du flux de discussion",
|
||||
"Enter the Input/Question": "Entrer la Saisie/Question",
|
||||
"Enter the History": "Entrer dans l'historique",
|
||||
"Enter the Override Config": "Accéder à la configuration de remplacement",
|
||||
"Authorization headers are injected automatically from your connection.": "Les en-têtes d'autorisation sont injectés automatiquement à partir de votre connexion.",
|
||||
"Enable for files like PDFs, images, etc..": "Activer pour les fichiers comme les PDFs, les images, etc.",
|
||||
"GET": "OBTENIR",
|
||||
"POST": "POSTER",
|
||||
"PATCH": "PATCH",
|
||||
"PUT": "EFFACER",
|
||||
"DELETE": "SUPPRIMER",
|
||||
"HEAD": "TÊTE"
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"No-Code AI workflow builder": "コードのないAIワークフロービルダ",
|
||||
"Base URL": "ベースURL",
|
||||
"API Key": "API キー",
|
||||
"Enter the base URL": "ベース URL を入力してください",
|
||||
"Enter the API Key": "API キーを入力",
|
||||
"Enter your Flowise URL and API Key": "Flowise URLとAPIキーを入力してください",
|
||||
"Make Prediction": "予測を行う",
|
||||
"Custom API Call": "カスタムAPI通話",
|
||||
"Run Flowise Predict": "フローの予測を実行",
|
||||
"Make a custom API call to a specific endpoint": "特定のエンドポイントへのカスタム API コールを実行します。",
|
||||
"Chatflow ID": "チャットフローID",
|
||||
"Input/Question": "入力/質問",
|
||||
"History": "沿革",
|
||||
"Override Config": "設定を上書き",
|
||||
"Method": "方法",
|
||||
"Headers": "ヘッダー",
|
||||
"Query Parameters": "クエリパラメータ",
|
||||
"Body": "本文",
|
||||
"Response is Binary ?": "応答はバイナリですか?",
|
||||
"No Error on Failure": "失敗時にエラーはありません",
|
||||
"Timeout (in seconds)": "タイムアウト(秒)",
|
||||
"Enter the Chatflow ID": "チャットフローIDを入力してください",
|
||||
"Enter the Input/Question": "入力/問題を入力してください",
|
||||
"Enter the History": "履歴を入力してください",
|
||||
"Enter the Override Config": "オーバーライド設定を入力してください",
|
||||
"Authorization headers are injected automatically from your connection.": "認証ヘッダは接続から自動的に注入されます。",
|
||||
"Enable for files like PDFs, images, etc..": "PDF、画像などのファイルを有効にします。",
|
||||
"GET": "取得",
|
||||
"POST": "POST",
|
||||
"PATCH": "PATCH",
|
||||
"PUT": "PUT",
|
||||
"DELETE": "削除",
|
||||
"HEAD": "頭"
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"No-Code AI workflow builder": "No-Code AI workflowbouwer",
|
||||
"Base URL": "Basis URL",
|
||||
"API Key": "API Sleutel",
|
||||
"Enter the base URL": "Voer de basis-URL in",
|
||||
"Enter the API Key": "Voer de API-sleutel in",
|
||||
"Enter your Flowise URL and API Key": "Voer uw Flowise URL en API Key in",
|
||||
"Make Prediction": "Voorspelling maken",
|
||||
"Custom API Call": "Custom API Call",
|
||||
"Run Flowise Predict": "Voer Flowise Predict uit",
|
||||
"Make a custom API call to a specific endpoint": "Maak een aangepaste API call naar een specifiek eindpunt",
|
||||
"Chatflow ID": "Chatflow ID",
|
||||
"Input/Question": "Invoer/vraag",
|
||||
"History": "Geschiedenis",
|
||||
"Override Config": "Configuratie overschrijven",
|
||||
"Method": "Methode",
|
||||
"Headers": "Kopteksten",
|
||||
"Query Parameters": "Query parameters",
|
||||
"Body": "Lichaam",
|
||||
"Response is Binary ?": "Antwoord is binair?",
|
||||
"No Error on Failure": "Geen fout bij fout",
|
||||
"Timeout (in seconds)": "Time-out (in seconden)",
|
||||
"Enter the Chatflow ID": "Voer de Chatflow ID in",
|
||||
"Enter the Input/Question": "Voer de invoer/vraag in",
|
||||
"Enter the History": "Voer de geschiedenis in",
|
||||
"Enter the Override Config": "Voer de Config in",
|
||||
"Authorization headers are injected automatically from your connection.": "Autorisatie headers worden automatisch geïnjecteerd vanuit uw verbinding.",
|
||||
"Enable for files like PDFs, images, etc..": "Inschakelen voor bestanden zoals PDF's, afbeeldingen etc..",
|
||||
"GET": "KRIJG",
|
||||
"POST": "POSTE",
|
||||
"PATCH": "BEKIJK",
|
||||
"PUT": "PUT",
|
||||
"DELETE": "VERWIJDEREN",
|
||||
"HEAD": "HOOFD"
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"No-Code AI workflow builder": "Criador de workflow No-Code AI",
|
||||
"Base URL": "URL Base",
|
||||
"API Key": "Chave de API",
|
||||
"Enter the base URL": "Digite a URL base",
|
||||
"Enter the API Key": "Digite a chave API",
|
||||
"Enter your Flowise URL and API Key": "Digite sua URL Flowise e chave da API",
|
||||
"Make Prediction": "Faça a previsão",
|
||||
"Custom API Call": "Chamada de API personalizada",
|
||||
"Run Flowise Predict": "Executar Predição de fluir",
|
||||
"Make a custom API call to a specific endpoint": "Faça uma chamada de API personalizada para um ponto de extremidade específico",
|
||||
"Chatflow ID": "Chatflow ID",
|
||||
"Input/Question": "Entrada/Questão",
|
||||
"History": "Histórico",
|
||||
"Override Config": "Substituir configuração",
|
||||
"Method": "Método",
|
||||
"Headers": "Cabeçalhos",
|
||||
"Query Parameters": "Parâmetros da consulta",
|
||||
"Body": "Conteúdo",
|
||||
"Response is Binary ?": "A resposta é binária ?",
|
||||
"No Error on Failure": "Nenhum erro no Failure",
|
||||
"Timeout (in seconds)": "Tempo limite (em segundos)",
|
||||
"Enter the Chatflow ID": "Entre com o Chatflow ID",
|
||||
"Enter the Input/Question": "Digite a Entrada/Pergunta",
|
||||
"Enter the History": "Digite o histórico",
|
||||
"Enter the Override Config": "Digite a Configuração de Substituição",
|
||||
"Authorization headers are injected automatically from your connection.": "Os cabeçalhos de autorização são inseridos automaticamente a partir da sua conexão.",
|
||||
"Enable for files like PDFs, images, etc..": "Habilitar para arquivos como PDFs, imagens, etc..",
|
||||
"GET": "OBTER",
|
||||
"POST": "POSTAR",
|
||||
"PATCH": "COMPRAR",
|
||||
"PUT": "COLOCAR",
|
||||
"DELETE": "EXCLUIR",
|
||||
"HEAD": "CABEÇA"
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
{
|
||||
"Flowise": "Мозаика",
|
||||
"No-Code AI workflow builder": "Конструктор ИИ без кода",
|
||||
"Base URL": "Базовый URL",
|
||||
"API Key": "Ключ API",
|
||||
"Enter the base URL": "Введите базовый URL",
|
||||
"Enter the API Key": "Введите ключ API",
|
||||
"Enter your Flowise URL and API Key": "Введите ваш Flowise URL и API Key",
|
||||
"Make Prediction": "Сделать прогноз",
|
||||
"Custom API Call": "Пользовательский вызов API",
|
||||
"Run Flowise Predict": "Запустить прогноз Flowise",
|
||||
"Make a custom API call to a specific endpoint": "Сделать пользовательский API вызов к определенной конечной точке",
|
||||
"Chatflow ID": "ID чата",
|
||||
"Input/Question": "Ввод/Вопрос",
|
||||
"History": "История",
|
||||
"Override Config": "Переопределить конфигурацию",
|
||||
"Method": "Метод",
|
||||
"Headers": "Заголовки",
|
||||
"Query Parameters": "Параметры запроса",
|
||||
"Body": "Тело",
|
||||
"No Error on Failure": "Нет ошибок при ошибке",
|
||||
"Timeout (in seconds)": "Таймаут (в секундах)",
|
||||
"Enter the Chatflow ID": "Введите ID чата",
|
||||
"Enter the Input/Question": "Введите ввод/вопрос",
|
||||
"Enter the History": "Введите историю",
|
||||
"Enter the Override Config": "Введите переопределение конфигурации",
|
||||
"Authorization headers are injected automatically from your connection.": "Заголовки авторизации включаются автоматически из вашего соединения.",
|
||||
"GET": "ПОЛУЧИТЬ",
|
||||
"POST": "ПОСТ",
|
||||
"PATCH": "ПАТЧ",
|
||||
"PUT": "ПОКУПИТЬ",
|
||||
"DELETE": "УДАЛИТЬ",
|
||||
"HEAD": "HEAD"
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"No-Code AI workflow builder": "No-Code AI workflow builder",
|
||||
"Base URL": "Base URL",
|
||||
"API Key": "API Key",
|
||||
"Enter the base URL": "Enter the base URL",
|
||||
"Enter the API Key": "Enter the API Key",
|
||||
"Enter your Flowise URL and API Key": "Enter your Flowise URL and API Key",
|
||||
"Make Prediction": "Make Prediction",
|
||||
"Custom API Call": "Custom API Call",
|
||||
"Run Flowise Predict": "Run Flowise Predict",
|
||||
"Make a custom API call to a specific endpoint": "Make a custom API call to a specific endpoint",
|
||||
"Chatflow ID": "Chatflow ID",
|
||||
"Input/Question": "Input/Question",
|
||||
"History": "History",
|
||||
"Override Config": "Override Config",
|
||||
"Method": "Method",
|
||||
"Headers": "Headers",
|
||||
"Query Parameters": "Query Parameters",
|
||||
"Body": "Body",
|
||||
"Response is Binary ?": "Response is Binary ?",
|
||||
"No Error on Failure": "No Error on Failure",
|
||||
"Timeout (in seconds)": "Timeout (in seconds)",
|
||||
"Enter the Chatflow ID": "Enter the Chatflow ID",
|
||||
"Enter the Input/Question": "Enter the Input/Question",
|
||||
"Enter the History": "Enter the History",
|
||||
"Enter the Override Config": "Enter the Override Config",
|
||||
"Authorization headers are injected automatically from your connection.": "Authorization headers are injected automatically from your connection.",
|
||||
"Enable for files like PDFs, images, etc..": "Enable for files like PDFs, images, etc..",
|
||||
"GET": "GET",
|
||||
"POST": "POST",
|
||||
"PATCH": "PATCH",
|
||||
"PUT": "PUT",
|
||||
"DELETE": "DELETE",
|
||||
"HEAD": "HEAD"
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
{
|
||||
"Flowise": "Flowise",
|
||||
"No-Code AI workflow builder": "No-Code AI workflow builder",
|
||||
"Base URL": "Base URL",
|
||||
"API Key": "API Key",
|
||||
"Enter the base URL": "Enter the base URL",
|
||||
"Enter the API Key": "Enter the API Key",
|
||||
"Enter your Flowise URL and API Key": "Enter your Flowise URL and API Key",
|
||||
"Make Prediction": "Make Prediction",
|
||||
"Custom API Call": "Custom API Call",
|
||||
"Run Flowise Predict": "Run Flowise Predict",
|
||||
"Make a custom API call to a specific endpoint": "Make a custom API call to a specific endpoint",
|
||||
"Chatflow ID": "Chatflow ID",
|
||||
"Input/Question": "Input/Question",
|
||||
"History": "History",
|
||||
"Override Config": "Override Config",
|
||||
"Method": "Method",
|
||||
"Headers": "Headers",
|
||||
"Query Parameters": "Query Parameters",
|
||||
"Body": "Body",
|
||||
"No Error on Failure": "No Error on Failure",
|
||||
"Timeout (in seconds)": "Timeout (in seconds)",
|
||||
"Enter the Chatflow ID": "Enter the Chatflow ID",
|
||||
"Enter the Input/Question": "Enter the Input/Question",
|
||||
"Enter the History": "Enter the History",
|
||||
"Enter the Override Config": "Enter the Override Config",
|
||||
"Authorization headers are injected automatically from your connection.": "Authorization headers are injected automatically from your connection.",
|
||||
"GET": "GET",
|
||||
"POST": "POST",
|
||||
"PATCH": "PATCH",
|
||||
"PUT": "PUT",
|
||||
"DELETE": "DELETE",
|
||||
"HEAD": "HEAD"
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"No-Code AI workflow builder": "No-Code AI workflow builder",
|
||||
"Base URL": "基本网址",
|
||||
"API Key": "API 密钥",
|
||||
"Enter the base URL": "Enter the base URL",
|
||||
"Enter the API Key": "Enter the API Key",
|
||||
"Enter your Flowise URL and API Key": "Enter your Flowise URL and API Key",
|
||||
"Make Prediction": "Make Prediction",
|
||||
"Custom API Call": "自定义 API 呼叫",
|
||||
"Run Flowise Predict": "Run Flowise Predict",
|
||||
"Make a custom API call to a specific endpoint": "将一个自定义 API 调用到一个特定的终点",
|
||||
"Chatflow ID": "Chatflow ID",
|
||||
"Input/Question": "Input/Question",
|
||||
"History": "History",
|
||||
"Override Config": "Override Config",
|
||||
"Method": "方法",
|
||||
"Headers": "信头",
|
||||
"Query Parameters": "查询参数",
|
||||
"Body": "正文内容",
|
||||
"Response is Binary ?": "Response is Binary ?",
|
||||
"No Error on Failure": "失败时没有错误",
|
||||
"Timeout (in seconds)": "超时(秒)",
|
||||
"Enter the Chatflow ID": "Enter the Chatflow ID",
|
||||
"Enter the Input/Question": "Enter the Input/Question",
|
||||
"Enter the History": "Enter the History",
|
||||
"Enter the Override Config": "Enter the Override Config",
|
||||
"Authorization headers are injected automatically from your connection.": "授权头自动从您的连接中注入。",
|
||||
"Enable for files like PDFs, images, etc..": "Enable for files like PDFs, images, etc..",
|
||||
"GET": "获取",
|
||||
"POST": "帖子",
|
||||
"PATCH": "PATCH",
|
||||
"PUT": "弹出",
|
||||
"DELETE": "删除",
|
||||
"HEAD": "黑色"
|
||||
}
|
||||
101
activepieces-fork/packages/pieces/community/flowise/src/index.ts
Normal file
101
activepieces-fork/packages/pieces/community/flowise/src/index.ts
Normal file
@@ -0,0 +1,101 @@
|
||||
import { createCustomApiCallAction } from '@activepieces/pieces-common';
|
||||
import {
|
||||
createAction,
|
||||
createPiece,
|
||||
PieceAuth,
|
||||
Property,
|
||||
} from '@activepieces/pieces-framework';
|
||||
import { PieceCategory } from '@activepieces/shared';
|
||||
|
||||
const flowiseAuth = PieceAuth.CustomAuth({
|
||||
description: 'Enter your Flowise URL and API Key',
|
||||
props: {
|
||||
base_url: Property.ShortText({
|
||||
displayName: 'Base URL',
|
||||
description: 'Enter the base URL',
|
||||
required: true,
|
||||
}),
|
||||
access_token: PieceAuth.SecretText({
|
||||
displayName: 'API Key',
|
||||
description: 'Enter the API Key',
|
||||
required: true,
|
||||
}),
|
||||
},
|
||||
required: true,
|
||||
});
|
||||
|
||||
// /api/v1/prediction/{your-chatflowid}
|
||||
export const flowisePredict = createAction({
|
||||
name: 'make_prediction',
|
||||
displayName: 'Make Prediction',
|
||||
description: 'Run Flowise Predict',
|
||||
auth: flowiseAuth,
|
||||
props: {
|
||||
chatflow_id: Property.ShortText({
|
||||
displayName: 'Chatflow ID',
|
||||
description: 'Enter the Chatflow ID',
|
||||
required: true,
|
||||
}),
|
||||
input: Property.ShortText({
|
||||
displayName: 'Input/Question',
|
||||
description: 'Enter the Input/Question',
|
||||
required: true,
|
||||
}),
|
||||
history: Property.Json({
|
||||
displayName: 'History',
|
||||
description: 'Enter the History',
|
||||
required: false,
|
||||
}),
|
||||
overrideConfig: Property.Json({
|
||||
displayName: 'Override Config',
|
||||
description: 'Enter the Override Config',
|
||||
required: false,
|
||||
}),
|
||||
},
|
||||
async run(ctx) {
|
||||
const { base_url, access_token } = ctx.auth.props;
|
||||
const chatflow_id = ctx.propsValue['chatflow_id'];
|
||||
const input = ctx.propsValue['input'];
|
||||
const url = `${base_url}/api/v1/prediction/${chatflow_id}`;
|
||||
const headers = {
|
||||
'Content-Type': 'application/json',
|
||||
Authorization: `Bearer ${access_token}`,
|
||||
};
|
||||
const body = {
|
||||
question: input,
|
||||
history: ctx.propsValue['history'],
|
||||
overrideConfig: ctx.propsValue['overrideConfig'],
|
||||
};
|
||||
const response = await fetch(url, {
|
||||
method: 'POST',
|
||||
headers,
|
||||
body: JSON.stringify(body),
|
||||
});
|
||||
const data = await response.json();
|
||||
return data;
|
||||
},
|
||||
});
|
||||
|
||||
export const flowise = createPiece({
|
||||
displayName: 'Flowise',
|
||||
description: 'No-Code AI workflow builder',
|
||||
|
||||
logoUrl: 'https://cdn.activepieces.com/pieces/flowise.png',
|
||||
auth: flowiseAuth,
|
||||
minimumSupportedRelease: '0.30.0',
|
||||
categories: [PieceCategory.ARTIFICIAL_INTELLIGENCE],
|
||||
authors: ["aasimsani","kishanprmr","MoShizzle","abuaboud"],
|
||||
actions: [
|
||||
flowisePredict,
|
||||
createCustomApiCallAction({
|
||||
baseUrl: (auth) => (auth?.props.base_url ?? ''),
|
||||
auth: flowiseAuth,
|
||||
authMapping: async (auth) => ({
|
||||
Authorization: `Bearer ${
|
||||
auth.props.access_token
|
||||
}`,
|
||||
}),
|
||||
}),
|
||||
],
|
||||
triggers: [],
|
||||
});
|
||||
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"extends": "../../../../tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"forceConsistentCasingInFileNames": true,
|
||||
"strict": true,
|
||||
"noImplicitOverride": true,
|
||||
"noPropertyAccessFromIndexSignature": true,
|
||||
"noImplicitReturns": true,
|
||||
"noFallthroughCasesInSwitch": true
|
||||
},
|
||||
"files": [],
|
||||
"include": [],
|
||||
"references": [
|
||||
{
|
||||
"path": "./tsconfig.lib.json"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"extends": "./tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"outDir": "../../../../dist/out-tsc",
|
||||
"declaration": true,
|
||||
"types": ["node"]
|
||||
},
|
||||
"exclude": ["jest.config.ts", "src/**/*.spec.ts", "src/**/*.test.ts"],
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
Reference in New Issue
Block a user