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:
poduck
2025-12-18 22:59:37 -05:00
parent 9848268d34
commit 3aa7199503
16292 changed files with 1284892 additions and 4708 deletions

View File

@@ -0,0 +1,33 @@
{
"extends": [
"../../../../.eslintrc.base.json"
],
"ignorePatterns": [
"!**/*"
],
"overrides": [
{
"files": [
"*.ts",
"*.tsx",
"*.js",
"*.jsx"
],
"rules": {}
},
{
"files": [
"*.ts",
"*.tsx"
],
"rules": {}
},
{
"files": [
"*.js",
"*.jsx"
],
"rules": {}
}
]
}

View File

@@ -0,0 +1,7 @@
# pieces-what-converts
This library was generated with [Nx](https://nx.dev).
## Building
Run `nx build pieces-what-converts` to build the library.

View File

@@ -0,0 +1,10 @@
{
"name": "@activepieces/piece-what-converts",
"version": "0.0.1",
"type": "commonjs",
"main": "./src/index.js",
"types": "./src/index.d.ts",
"dependencies": {
"tslib": "^2.3.0"
}
}

View File

@@ -0,0 +1,65 @@
{
"name": "pieces-what-converts",
"$schema": "../../../../node_modules/nx/schemas/project-schema.json",
"sourceRoot": "packages/pieces/community/what-converts/src",
"projectType": "library",
"release": {
"version": {
"manifestRootsToUpdate": [
"dist/{projectRoot}"
],
"currentVersionResolver": "git-tag",
"fallbackCurrentVersionResolver": "disk"
}
},
"tags": [],
"targets": {
"build": {
"executor": "@nx/js:tsc",
"outputs": [
"{options.outputPath}"
],
"options": {
"outputPath": "dist/packages/pieces/community/what-converts",
"tsConfig": "packages/pieces/community/what-converts/tsconfig.lib.json",
"packageJson": "packages/pieces/community/what-converts/package.json",
"main": "packages/pieces/community/what-converts/src/index.ts",
"assets": [
"packages/pieces/community/what-converts/*.md",
{
"input": "packages/pieces/community/what-converts/src/i18n",
"output": "./src/i18n",
"glob": "**/!(i18n.json)"
}
],
"buildableProjectDepsInPackageJsonType": "dependencies",
"updateBuildableProjectDepsInPackageJson": true
},
"dependsOn": [
"^build",
"prebuild"
]
},
"nx-release-publish": {
"options": {
"packageRoot": "dist/{projectRoot}"
}
},
"lint": {
"executor": "@nx/eslint:lint",
"outputs": [
"{options.outputFile}"
]
},
"prebuild": {
"executor": "nx:run-commands",
"options": {
"cwd": "packages/pieces/community/what-converts",
"command": "bun install --no-save --silent"
},
"dependsOn": [
"^build"
]
}
}
}

View File

@@ -0,0 +1,94 @@
{
"API Token": "API Token",
"API Secret": "API-Geheimnis",
"Your WhatConverts API Token.": "Ihr WhatConverts API Token.",
"Your WhatConverts API Secret.": "Dein WhatConverts API Secret.",
"\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ": "\n Um Ihre API-Zugangsdaten zu erhalten:\n 1. Melden Sie sich in Ihr WhatConverts-Dashboard ein.\n 2. Navigieren Sie zu einem Konto und wählen Sie ein Profil.\n 3. Wählen Sie das Dropdown-Menü **Tracking** aus.\n 4. Klicken Sie auf **Integrations**, dann **API Keys**.\n 5. Klicke auf **API-Schlüssel generieren** um dein Token und dein Geheimnis zu erhalten.\n ",
"Create Lead": "Lead erstellen",
"Export Leads": "Leads exportieren",
"Update Lead": "Lead aktualisieren",
"Find Lead": "Lead finden",
"Create a new lead in WhatConverts.": "Erstellen Sie eine neue Lead in WhatConverts.",
"Retrieves all leads from an account, handling pagination automatically.": "Ruft alle Leads von einem Konto ab und behandelt die Paginierung automatisch.",
"Update an existing lead's attributes by its ID.": "Aktualisiere die Attribute einer Lead durch ihre ID.",
"Find a lead by various criteria.": "Finden Sie eine Führung durch verschiedene Kriterien.",
"Account": "Konto",
"Profile": "Profil",
"Lead Type": "Lead-Typ",
"First Name": "Vorname",
"Last Name": "Nachname",
"Email": "E-Mail",
"Phone Number": "Telefonnummer",
"Company Name": "Firmenname",
"Notes": "Notizen",
"Referring Source": "Verweisende Quelle",
"Referring Medium": "Verweisende Mittel",
"Send Notification": "Benachrichtigung senden",
"Creation Date": "Erstellungsdatum",
"Quotable": "Quotierbar",
"Quote Value": "Angebotswert",
"Sales Value": "Umsatzwert",
"Start Date": "Startdatum",
"End Date": "Enddatum",
"Lead Type (Optional)": "Lead-Typ (optional)",
"Leads Per Page": "Leads pro Seite",
"Number of Pages": "Anzahl der Seiten",
"Lead": "Lead",
"Referring Campaign": "Verweisende Kampagne",
"Email Address": "E-Mail-Adresse",
"The account to select a profile from.": "Das Konto, von dem ein Profil ausgewählt werden soll.",
"The profile to search for leads in.": "Das Profil, in dem nach Leads gesucht werden soll.",
"The type of the lead.": "Der Typ der Führung.",
"The source of the lead (e.g., \"google\").": "Die Quelle der Lead (z. B. \"google\").",
"The medium of the lead (e.g., \"cpc\").": "Das Bleimittelmittel (z.B. \"cpc\").",
"Set to true to send a new lead notification email.": "Auf true setzen, um eine neue Lead-Benachrichtigungs-E-Mail zu senden.",
"The date and time when the lead was created.": "Das Datum und die Uhrzeit, an der die Lead erstellt wurde.",
"Indicates if the lead is quotable.": "Gibt an, ob die Lead quotable ist.",
"The monetary value of the quote associated with the lead.": "Der monetäre Wert des mit der Führung assoziierten Zitats.",
"The monetary value of the sale associated with the lead.": "Der monetäre Wert des Verkaufs im Zusammenhang mit der Leitung.",
"The start date for the export range in YYYY-MM-DD format.": "Das Startdatum für den Exportbereich im Format JJJJ-MM-TT.",
"The end date for the export range in YYYY-MM-DD format.": "Das Enddatum für den Exportbereich im Format JJJ-MM-TT.",
"Filter leads by their type.": "Leads nach ihrem Typ filtern.",
"Number of leads to fetch per page (max 1000).": "Anzahl der zu holenden Leads pro Seite (max 1000).",
"The number of pages to retrieve (max 100).": "Die Anzahl der abzurufenden Seiten (max 100).",
"The lead to update.": "Die Anleitung zum Update.",
"Mark the lead as quotable.": "Markieren Sie die Lead als quotabel.",
"The monetary value of the lead (e.g., \"150.00\").": "Der monetäre Wert der Lead (z. B. \"150.00\").",
"The campaign that generated the lead.": "Die Kampagne, die den Vorsprung erzeugte.",
"Find a lead by their email address.": "Finden Sie eine Lead über ihre E-Mail-Adresse.",
"Find a lead by their E.164 formatted phone number.": "Finden Sie einen Leitfaden durch ihre E.164 formatierte Telefonnummer.",
"The number of leads to return (default 25, max 2500).": "Die Anzahl der zurückzugebenden Leads (Standard 25, max 2500).",
"Phone Call": "Telefonanruf",
"Web Form": "Web-Formular",
"Chat": "Chat",
"Transaction": "Transaktion",
"Event": "Ereignis",
"Appointment": "Termin",
"Text Message": "Textnachricht",
"Google": "Google",
"Bing": "Bing",
"Facebook": "Facebook",
"LinkedIn": "LinkedIn",
"Twitter": "Twitter",
"Instagram": "Instagram",
"Direct Traffic": "Direkter Verkehr",
"Organic Search": "Organische Suche",
"Paid Search (CPC)": "Bezahlte Suche (CPC)",
"Social Media": "Soziale Medien",
"Referral": "Empfehlung",
"Display Ad": "Anzeige anzeigen",
"None (for Direct Traffic)": "Keine (für direkten Verkehr)",
"Yes": "Ja",
"No": "Nein",
"Pending": "Ausstehend",
"Not Set": "Nicht gesetzt",
"Other": "Andere",
"Summer Sale": "Sommerverkauf",
"Q4 Promotion": "Q4 Werbung",
"New Product Launch": "Neues Produkt starten",
"Brand Awareness": "Markenbewusstsein",
"New Lead": "Neuer Lead",
"Updated Lead": "Aktualisierte Lead",
"Fires when a new lead is received.": "Feuert ab, wenn ein neuer Blei empfangen wird.",
"Fires when an existing lead is updated in WhatConverts.": "Feuer, wenn ein existierender Lead in WhatConverts aktualisiert wird."
}

View File

@@ -0,0 +1,94 @@
{
"API Token": "API Token",
"API Secret": "API secreta",
"Your WhatConverts API Token.": "Tu token WhatConverts API.",
"Your WhatConverts API Secret.": "Tu WhatConverts API Sect.",
"\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ": "\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ",
"Create Lead": "Crear plomo",
"Export Leads": "Exportar clientes potenciales",
"Update Lead": "Actualizar plomo",
"Find Lead": "Buscar plomo",
"Create a new lead in WhatConverts.": "Crear un nuevo plomo en WhatConverts.",
"Retrieves all leads from an account, handling pagination automatically.": "Recuperar todos los clientes potenciales de una cuenta, manejando la paginación automáticamente.",
"Update an existing lead's attributes by its ID.": "Actualizar los atributos de un plomo existente por su ID.",
"Find a lead by various criteria.": "Encuentre un liderazgo según varios criterios.",
"Account": "Cuenta",
"Profile": "Perfil",
"Lead Type": "Tipo de plomo",
"First Name": "Nombre",
"Last Name": "Apellido",
"Email": "E-mail",
"Phone Number": "Número de teléfono",
"Company Name": "Nombre De La Empresa",
"Notes": "Notas",
"Referring Source": "Fuente recomendada",
"Referring Medium": "Medios de referencia",
"Send Notification": "Enviar notificación",
"Creation Date": "Fecha de creación",
"Quotable": "Cotizable",
"Quote Value": "Valor de cotización",
"Sales Value": "Valor de ventas",
"Start Date": "Fecha de inicio",
"End Date": "Fecha de fin",
"Lead Type (Optional)": "Tipo de plomo (opcional)",
"Leads Per Page": "Prospectos por página",
"Number of Pages": "Número de páginas",
"Lead": "Plomo",
"Referring Campaign": "Refiriendo Campaña",
"Email Address": "Dirección de email",
"The account to select a profile from.": "La cuenta desde la que seleccionar un perfil.",
"The profile to search for leads in.": "El perfil en el que buscar derivados.",
"The type of the lead.": "El tipo de plomo.",
"The source of the lead (e.g., \"google\").": "La fuente del plomo (por ej., \"google\").",
"The medium of the lead (e.g., \"cpc\").": "El medio del plomo (por ej., \"cpc\").",
"Set to true to send a new lead notification email.": "Establecer en true para enviar un nuevo correo electrónico de notificación principal.",
"The date and time when the lead was created.": "La fecha y hora en que el cliente potencial fue creado.",
"Indicates if the lead is quotable.": "Indica si el plomo es cotizable.",
"The monetary value of the quote associated with the lead.": "El valor monetario de la cotización asociada con el plomo.",
"The monetary value of the sale associated with the lead.": "El valor monetario de la venta asociada con el plomo.",
"The start date for the export range in YYYY-MM-DD format.": "La fecha de inicio para el rango de exportación en formato AAA-MM-DD.",
"The end date for the export range in YYYY-MM-DD format.": "La fecha de finalización del rango de exportación en formato AAA-MM-DD.",
"Filter leads by their type.": "Filtrar prospectos por su tipo.",
"Number of leads to fetch per page (max 1000).": "Número de clientes potenciales a buscar por página (máx. 1000).",
"The number of pages to retrieve (max 100).": "El número de páginas a recuperar (máx. 100).",
"The lead to update.": "La ventaja a actualizar.",
"Mark the lead as quotable.": "Marcar el plomo como cotizable.",
"The monetary value of the lead (e.g., \"150.00\").": "El valor monetario del plomo (por ej., \"150.00\").",
"The campaign that generated the lead.": "La campaña que generó el liderazgo.",
"Find a lead by their email address.": "Encuentre un líder por su dirección de correo electrónico.",
"Find a lead by their E.164 formatted phone number.": "Encuentre una ventaja por su número de teléfono con formato E.164.",
"The number of leads to return (default 25, max 2500).": "El número de clientes potenciales a devolver (por defecto 25, máx. 2500).",
"Phone Call": "Llamada telefónica",
"Web Form": "Formulario Web",
"Chat": "Chatear",
"Transaction": "Transacción",
"Event": "Evento",
"Appointment": "Cita",
"Text Message": "Mensaje de texto",
"Google": "Google",
"Bing": "Bing",
"Facebook": "Facebook",
"LinkedIn": "LinkedIn",
"Twitter": "Twitter",
"Instagram": "Instagrama",
"Direct Traffic": "Traste Directo",
"Organic Search": "Búsqueda orgánica",
"Paid Search (CPC)": "Búsqueda pagada (CPC)",
"Social Media": "Redes Sociales",
"Referral": "Referir",
"Display Ad": "Mostrar anuncio",
"None (for Direct Traffic)": "Ninguno (para trafico directo)",
"Yes": "Sí",
"No": "Nu",
"Pending": "Pendiente",
"Not Set": "No definido",
"Other": "Otro",
"Summer Sale": "Oferta de verano",
"Q4 Promotion": "P4 Promover",
"New Product Launch": "Nuevo lanzamiento de producto",
"Brand Awareness": "Conocimiento de marca",
"New Lead": "Nuevo plomo",
"Updated Lead": "Prospectos actualizados",
"Fires when a new lead is received.": "Dispara cuando se recibe un nuevo plomo.",
"Fires when an existing lead is updated in WhatConverts.": "Dispara cuando se actualiza un plomo existente en WhatConverts."
}

View File

@@ -0,0 +1,94 @@
{
"API Token": "API Token",
"API Secret": "Secret de l'API",
"Your WhatConverts API Token.": "Votre jeton API WhatConverts.",
"Your WhatConverts API Secret.": "Votre secret de l'API WhatConverts.",
"\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ": "\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ",
"Create Lead": "Créer Prospect",
"Export Leads": "Exporter les prospects",
"Update Lead": "Mettre à jour le prospect",
"Find Lead": "Trouver un prospect",
"Create a new lead in WhatConverts.": "Crée un nouveau prospect dans WhatConverts.",
"Retrieves all leads from an account, handling pagination automatically.": "Récupère tous les prospects depuis un compte, la pagination automatiquement.",
"Update an existing lead's attributes by its ID.": "Mettre à jour les attributs d'un prospect existant par son ID.",
"Find a lead by various criteria.": "Trouvez un chef de file selon différents critères.",
"Account": "Compte client",
"Profile": "Profil",
"Lead Type": "Type de prospect",
"First Name": "First Name",
"Last Name": "Last Name",
"Email": "Courriel",
"Phone Number": "Numéro de téléphone",
"Company Name": "Nom de lentreprise",
"Notes": "Notes",
"Referring Source": "Source de référence",
"Referring Medium": "Moyen référant",
"Send Notification": "Envoyer une notification",
"Creation Date": "Date de création",
"Quotable": "Citation",
"Quote Value": "Valeur du devis",
"Sales Value": "Valeur des ventes",
"Start Date": "Date de début",
"End Date": "Date de fin",
"Lead Type (Optional)": "Type de prospect (facultatif)",
"Leads Per Page": "Prospects par page",
"Number of Pages": "Nombre de pages",
"Lead": "Prospect",
"Referring Campaign": "Campagne de parrainage",
"Email Address": "Adresse e-mail",
"The account to select a profile from.": "Le compte à partir duquel sélectionner un profil.",
"The profile to search for leads in.": "Le profil dans lequel rechercher des prospects",
"The type of the lead.": "Le type de plomb.",
"The source of the lead (e.g., \"google\").": "La source du plomb (par exemple, « google »).",
"The medium of the lead (e.g., \"cpc\").": "Le milieu du plomb (par exemple, « cpc »).",
"Set to true to send a new lead notification email.": "Définir à vrai pour envoyer un nouvel e-mail de notification de plomb.",
"The date and time when the lead was created.": "La date et l'heure de la création de la prospection.",
"Indicates if the lead is quotable.": "Indique si le prospect est quotable.",
"The monetary value of the quote associated with the lead.": "La valeur monétaire du devis associé au plomb.",
"The monetary value of the sale associated with the lead.": "La valeur monétaire de la vente associée au plomb.",
"The start date for the export range in YYYY-MM-DD format.": "La date de début de la plage d'exportation au format AAAA-MM-JJ.",
"The end date for the export range in YYYY-MM-DD format.": "La date de fin pour la plage d'exportation au format AAAA-MM-JJ.",
"Filter leads by their type.": "Filtrer les pistes par leur type.",
"Number of leads to fetch per page (max 1000).": "Nombre de pistes à récupérer par page (max 1000).",
"The number of pages to retrieve (max 100).": "Le nombre de pages à récupérer (max 100).",
"The lead to update.": "La piste à mettre à jour.",
"Mark the lead as quotable.": "Marquer le prospect comme quotable.",
"The monetary value of the lead (e.g., \"150.00\").": "La valeur monétaire du plomb (par exemple, \"150.00\").",
"The campaign that generated the lead.": "La campagne qui a généré le plomb.",
"Find a lead by their email address.": "Trouvez un prospect par leur adresse e-mail.",
"Find a lead by their E.164 formatted phone number.": "Trouvez un prospect par leur numéro de téléphone formaté au format E.164.",
"The number of leads to return (default 25, max 2500).": "Le nombre de pistes à retourner (par défaut 25, max 2500).",
"Phone Call": "Appel téléphonique",
"Web Form": "Formulaire Web",
"Chat": "Discuter",
"Transaction": "Opération",
"Event": "Evénement",
"Appointment": "Rendez-vous",
"Text Message": "Message texte",
"Google": "Google",
"Bing": "Bing",
"Facebook": "Facebook",
"LinkedIn": "LinkedIn",
"Twitter": "Twitter",
"Instagram": "Instagram",
"Direct Traffic": "Trafic direct",
"Organic Search": "Recherche organique",
"Paid Search (CPC)": "Recherche payante (CPC)",
"Social Media": "Réseaux sociaux",
"Referral": "Parrainage",
"Display Ad": "Afficher la pub",
"None (for Direct Traffic)": "Aucun (pour le trafic direct)",
"Yes": "Oui",
"No": "Non",
"Pending": "En attente",
"Not Set": "Non défini",
"Other": "Autres",
"Summer Sale": "Soldes d'été",
"Q4 Promotion": "Promotion Q4",
"New Product Launch": "Lancement d'un nouveau produit",
"Brand Awareness": "Sensibilisation de la marque",
"New Lead": "Nouveau prospect",
"Updated Lead": "Prospect mis à jour",
"Fires when a new lead is received.": "Tire quand une nouvelle avance est reçue.",
"Fires when an existing lead is updated in WhatConverts.": "Se déclenche lorsqu'une piste existante est mise à jour dans WhatConverts."
}

View File

@@ -0,0 +1,94 @@
{
"API Token": "API Token",
"API Secret": "APIシークレット",
"Your WhatConverts API Token.": "あなたの機能 API トークンを変換します。",
"Your WhatConverts API Secret.": "あなたの機能 API の秘密を変換します。",
"\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ": "\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ",
"Create Lead": "リードを作成",
"Export Leads": "リードをエクスポート",
"Update Lead": "潜在顧客を更新",
"Find Lead": "リードを見つける",
"Create a new lead in WhatConverts.": "WhatConverts で新しいリードを作成します。",
"Retrieves all leads from an account, handling pagination automatically.": "すべてのリードをアカウントから取得し、ページネーションを自動的に処理します。",
"Update an existing lead's attributes by its ID.": "既存のリードの属性を ID で更新します。",
"Find a lead by various criteria.": "さまざまな基準でリードを検索します。",
"Account": "アカウント",
"Profile": "プロフィール",
"Lead Type": "リードタイプ",
"First Name": "名",
"Last Name": "Last Name",
"Email": "Eメールアドレス",
"Phone Number": "電話番号",
"Company Name": "会社名",
"Notes": "メモ",
"Referring Source": "参照元",
"Referring Medium": "中程度を参照",
"Send Notification": "通知を送信",
"Creation Date": "作成日",
"Quotable": "引用可能",
"Quote Value": "見積もり値",
"Sales Value": "販売価格",
"Start Date": "開始日",
"End Date": "終了日",
"Lead Type (Optional)": "リードタイプ (オプション)",
"Leads Per Page": "ページあたりのリード数",
"Number of Pages": "ページ数",
"Lead": "リード",
"Referring Campaign": "キャンペーンの参照",
"Email Address": "メールアドレス",
"The account to select a profile from.": "プロファイルを選択するアカウント",
"The profile to search for leads in.": "リードを検索するプロファイル。",
"The type of the lead.": "リードのタイプ",
"The source of the lead (e.g., \"google\").": "リードの情報源(例:\"google\")。",
"The medium of the lead (e.g., \"cpc\").": "リードの媒体(例:\"cpc\")。",
"Set to true to send a new lead notification email.": "新しいリード通知メールを送信するには、true に設定します。",
"The date and time when the lead was created.": "リードが作成された日時",
"Indicates if the lead is quotable.": "リードがクォータ可能かどうかを示します。",
"The monetary value of the quote associated with the lead.": "リードに関連付けられた見積もりの金銭的価値。",
"The monetary value of the sale associated with the lead.": "リードに関連付けられた販売の金銭的価値。",
"The start date for the export range in YYYY-MM-DD format.": "エクスポート範囲の開始日を YYYY-MM-DD 形式で指定します。",
"The end date for the export range in YYYY-MM-DD format.": "エクスポート範囲の終了日を YYYY-MM-DD 形式で指定します。",
"Filter leads by their type.": "リード線のタイプで絞り込みます。",
"Number of leads to fetch per page (max 1000).": "ページごとのフェッチリード数最大1000",
"The number of pages to retrieve (max 100).": "取得するページ数(最大 100。",
"The lead to update.": "更新のリード。",
"Mark the lead as quotable.": "リードを引用符としてマークします。",
"The monetary value of the lead (e.g., \"150.00\").": "リードの貨幣価値(例:\"150.00\")。",
"The campaign that generated the lead.": "リードを生み出したキャンペーン。",
"Find a lead by their email address.": "彼らのメールアドレスでリードを探します。",
"Find a lead by their E.164 formatted phone number.": "E.164形式の電話番号でリードを見つけます。",
"The number of leads to return (default 25, max 2500).": "返却する見込み客の数デフォルトでは25、最大2500。",
"Phone Call": "電話",
"Web Form": "Webフォーム",
"Chat": "チャット",
"Transaction": "取引",
"Event": "イベント",
"Appointment": "予約",
"Text Message": "メッセージ",
"Google": "Google",
"Bing": "Bing",
"Facebook": "Facebook",
"LinkedIn": "LinkedIn",
"Twitter": "Twitter",
"Instagram": "Instagram",
"Direct Traffic": "ダイレクトトラフィック",
"Organic Search": "有機検索",
"Paid Search (CPC)": "有料検索 (CPC)",
"Social Media": "SNS",
"Referral": "紹介する",
"Display Ad": "広告を表示",
"None (for Direct Traffic)": "(ダイレクトトラフィックの場合)",
"Yes": "はい",
"No": "いいえ",
"Pending": "処理待ち",
"Not Set": "未設定",
"Other": "その他",
"Summer Sale": "夏のセール",
"Q4 Promotion": "Q4プロモーション",
"New Product Launch": "新しい製品の起動",
"Brand Awareness": "ブランドの認識",
"New Lead": "新しいリード",
"Updated Lead": "更新されたリード",
"Fires when a new lead is received.": "新しいリードを受け取ったときに発火します。",
"Fires when an existing lead is updated in WhatConverts.": "WhatConverts で既存のリードが更新されたときに発生します。"
}

View File

@@ -0,0 +1,94 @@
{
"API Token": "API Token",
"API Secret": "API Geheim",
"Your WhatConverts API Token.": "Uw WatConverts API Token.",
"Your WhatConverts API Secret.": "Uw Watkey-Converts API-geheim.",
"\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ": "\n Om uw API-gegevens te krijgen:\n 1. Log in op uw WatConverts dashboard.\n 2. Navigeer naar een account en selecteer een profiel.\n 3. Selecteer het **Tracking** dropdown menu.\n 4. Klik op **Integraties**, dan **API Keys**.\n 5. Klik **Genereer API-sleutel** om uw Token en Geheim te krijgen.\n ",
"Create Lead": "Maak Lead",
"Export Leads": "Exporteer Leads",
"Update Lead": "Lead bijwerken",
"Find Lead": "Zoek Lead",
"Create a new lead in WhatConverts.": "Maak een nieuwe lead in WhatConverts.",
"Retrieves all leads from an account, handling pagination automatically.": "Ophalen alle leads vanaf een account en automatisch paginering afhandelen.",
"Update an existing lead's attributes by its ID.": "Werk een bestaande lead's attributen bij met zijn ID.",
"Find a lead by various criteria.": "Zoek een voorsprong op basis van verschillende criteria.",
"Account": "Rekening",
"Profile": "Profiel",
"Lead Type": "Lead type",
"First Name": "Voornaam",
"Last Name": "Achternaam",
"Email": "E-mail",
"Phone Number": "Telefoon nummer",
"Company Name": "Bedrijfsnaam",
"Notes": "Opmerkingen",
"Referring Source": "Verwijzende bron",
"Referring Medium": "Verwijzend medium",
"Send Notification": "Stuur notificatie",
"Creation Date": "Aanmaak datum",
"Quotable": "Offerbaar",
"Quote Value": "Offerte waarde",
"Sales Value": "Waarde verkoop",
"Start Date": "Start datum",
"End Date": "Eind datum",
"Lead Type (Optional)": "Lead type (optioneel)",
"Leads Per Page": "Leads per pagina",
"Number of Pages": "Aantal pagina's",
"Lead": "Lood",
"Referring Campaign": "Verwijzende campagne",
"Email Address": "Uw e-mailadres",
"The account to select a profile from.": "Account om een profiel van te selecteren.",
"The profile to search for leads in.": "Het profiel om naar leads in te zoeken.",
"The type of the lead.": "Het type van de lead.",
"The source of the lead (e.g., \"google\").": "De bron van de lead (bijv. \"google\").",
"The medium of the lead (e.g., \"cpc\").": "Het medium van de lead (bijv. \"cpc\").",
"Set to true to send a new lead notification email.": "Zet op juist om een nieuwe lead notificatie e-mail te verzenden.",
"The date and time when the lead was created.": "De datum en tijd waarop de lead is aangemaakt.",
"Indicates if the lead is quotable.": "Geeft aan of de lead quotabel is.",
"The monetary value of the quote associated with the lead.": "De monetaire waarde van de offerte die is gekoppeld aan de lood.",
"The monetary value of the sale associated with the lead.": "De monetaire waarde van de verkoop geassocieerd met de lood.",
"The start date for the export range in YYYY-MM-DD format.": "De startdatum voor het exportbereik in JJJJ-MM-DD formaat.",
"The end date for the export range in YYYY-MM-DD format.": "De einddatum voor het exportbereik in JJJJ-MM-DD formaat.",
"Filter leads by their type.": "Filter leads volgens hun type.",
"Number of leads to fetch per page (max 1000).": "Aantal leads om per pagina op te halen (max 1000).",
"The number of pages to retrieve (max 100).": "Het aantal op te halen pagina's (max 100).",
"The lead to update.": "De lead om te updaten.",
"Mark the lead as quotable.": "Markeer de voorsprong als quotabel.",
"The monetary value of the lead (e.g., \"150.00\").": "De monetaire waarde van de lead (bijv. \"150,00\").",
"The campaign that generated the lead.": "De campagne die de lead heeft gegenereerd.",
"Find a lead by their email address.": "Zoek een lead op basis van hun e-mailadres.",
"Find a lead by their E.164 formatted phone number.": "Vind een lead door hun E.164 opgemaakt telefoonnummer.",
"The number of leads to return (default 25, max 2500).": "Het aantal leads om terug te keren (standaard 25, max 2500).",
"Phone Call": "Telefoon gesprek",
"Web Form": "Web Formulier",
"Chat": "Chatten",
"Transaction": "Transactie",
"Event": "Gebeurtenis",
"Appointment": "Afspraak",
"Text Message": "Bericht sms'en",
"Google": "Google",
"Bing": "Ving",
"Facebook": "Facebook",
"LinkedIn": "LinkedIn",
"Twitter": "Twitter",
"Instagram": "Instagram",
"Direct Traffic": "Direct Dataverkeer",
"Organic Search": "Organisch zoeken",
"Paid Search (CPC)": "Betaald Zoeken (CPC)",
"Social Media": "Sociale Media",
"Referral": "Verwijzing",
"Display Ad": "Advertentie weergeven",
"None (for Direct Traffic)": "Geen (voor Direct Traffice)",
"Yes": "ja",
"No": "Neen",
"Pending": "In behandeling",
"Not Set": "Niet ingesteld",
"Other": "anders",
"Summer Sale": "Zomer Verkoop",
"Q4 Promotion": "Q4 Promotie",
"New Product Launch": "Nieuw product starten",
"Brand Awareness": "Merk bewustwording",
"New Lead": "Nieuwe Lead",
"Updated Lead": "Bijgewerkt Lead",
"Fires when a new lead is received.": "Vuurt af wanneer een nieuwe lead is binnengekomen.",
"Fires when an existing lead is updated in WhatConverts.": "Vuurt wanneer een bestaande lead wordt bijgewerkt in WhatConverts."
}

View File

@@ -0,0 +1,94 @@
{
"API Token": "API Token",
"API Secret": "API Segredo",
"Your WhatConverts API Token.": "Seu WhatConverts API Token.",
"Your WhatConverts API Secret.": "Seu Secreto de API do WhatConverts.",
"\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ": "\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ",
"Create Lead": "Criar Potencial",
"Export Leads": "Exportar Leads",
"Update Lead": "Atualizar Lead",
"Find Lead": "Encontrar Potencial",
"Create a new lead in WhatConverts.": "Crie um novo lead em WhatConverts.",
"Retrieves all leads from an account, handling pagination automatically.": "Recupera todos os leads de uma conta, manipulando a paginação automaticamente.",
"Update an existing lead's attributes by its ID.": "Atualizar os atributos de um potencial existente com seu ID.",
"Find a lead by various criteria.": "Encontre uma posição de liderança com vários critérios.",
"Account": "conta",
"Profile": "Perfil",
"Lead Type": "Tipo de Potencial",
"First Name": "Nome",
"Last Name": "Sobrenome",
"Email": "e-mail",
"Phone Number": "Número de telefone",
"Company Name": "Nome da Empresa",
"Notes": "Observações",
"Referring Source": "Fonte Referência",
"Referring Medium": "Referência média",
"Send Notification": "Enviar Notificação",
"Creation Date": "Data de Criação",
"Quotable": "Citação",
"Quote Value": "Valor da Cotação",
"Sales Value": "Valor de Vendas",
"Start Date": "Data Inicial",
"End Date": "Data de Término",
"Lead Type (Optional)": "Tipo de lead (opcional)",
"Leads Per Page": "Leads por Página",
"Number of Pages": "Número de páginas",
"Lead": "Conduzir",
"Referring Campaign": "Campanha de Referência",
"Email Address": "Endereço de e-mail",
"The account to select a profile from.": "A conta de onde você deseja selecionar um perfil.",
"The profile to search for leads in.": "O perfil para pesquisar por Potenciais.",
"The type of the lead.": "O tipo do chumbo.",
"The source of the lead (e.g., \"google\").": "A fonte do lead (ex.: \"google\").",
"The medium of the lead (e.g., \"cpc\").": "O meio do chumbo (ex.: \"cpc\").",
"Set to true to send a new lead notification email.": "Defina como verdadeiro para enviar um novo e-mail de notificação de leads.",
"The date and time when the lead was created.": "Data e hora em que a vantagem foi criada.",
"Indicates if the lead is quotable.": "Indica se o lead é citado.",
"The monetary value of the quote associated with the lead.": "O valor monetário da cotação associada ao chumbo.",
"The monetary value of the sale associated with the lead.": "O valor monetário da venda associado ao chumbo.",
"The start date for the export range in YYYY-MM-DD format.": "A data de início do intervalo de exportação em formato YYYY-MM-DD.",
"The end date for the export range in YYYY-MM-DD format.": "A data final para o intervalo de exportação em formato YYYY-MM-DD.",
"Filter leads by their type.": "Filtrar leads por seu tipo.",
"Number of leads to fetch per page (max 1000).": "Número de leva para buscar por página (máx. 1000).",
"The number of pages to retrieve (max 100).": "O número de páginas a serem recuperadas (máximo 100).",
"The lead to update.": "O chumbo de atualização.",
"Mark the lead as quotable.": "Marcar o chumbo como citado.",
"The monetary value of the lead (e.g., \"150.00\").": "O valor monetário do chumbo (por exemplo, \"150.00\").",
"The campaign that generated the lead.": "A campanha que gerou a liderança.",
"Find a lead by their email address.": "Encontre um líder com seu endereço de e-mail.",
"Find a lead by their E.164 formatted phone number.": "Encontre uma vantagem usando o número de telefone formatado por E.164.",
"The number of leads to return (default 25, max 2500).": "O número de leva a retornar (padrão 25, máx. 2500).",
"Phone Call": "Chamada Telefônica",
"Web Form": "Formulário Web",
"Chat": "Bate-papo",
"Transaction": "Transação",
"Event": "Evento",
"Appointment": "Compromisso",
"Text Message": "Mensagem de texto",
"Google": "Google",
"Bing": "Bing",
"Facebook": "Siga-nos",
"LinkedIn": "LinkedIn",
"Twitter": "Twitter",
"Instagram": "Instagram",
"Direct Traffic": "Tráfego direto",
"Organic Search": "Pesquisa Orgânica",
"Paid Search (CPC)": "Pesquisa paga (CPC)",
"Social Media": "Mídias Sociais",
"Referral": "Referência",
"Display Ad": "Mostrar anúncio",
"None (for Direct Traffic)": "Nenhum (para tráfego direto)",
"Yes": "sim",
"No": "Não",
"Pending": "Pendente",
"Not Set": "Não definido",
"Other": "Outros",
"Summer Sale": "Promoção de Verão",
"Q4 Promotion": "Promover Q4",
"New Product Launch": "Novo lançamento de produto",
"Brand Awareness": "Consciência da Marca",
"New Lead": "Novo Potencial",
"Updated Lead": "Lead atualizado",
"Fires when a new lead is received.": "Atira quando um novo lead é recebido.",
"Fires when an existing lead is updated in WhatConverts.": "Atira quando um lead existente é atualizado em WhatConverts."
}

View File

@@ -0,0 +1,94 @@
{
"API Token": "API Token",
"API Secret": "API Secret",
"Your WhatConverts API Token.": "Your WhatConverts API Token.",
"Your WhatConverts API Secret.": "Your WhatConverts API Secret.",
"\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ": "\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ",
"Create Lead": "Create Lead",
"Export Leads": "Export Leads",
"Update Lead": "Update Lead",
"Find Lead": "Find Lead",
"Create a new lead in WhatConverts.": "Create a new lead in WhatConverts.",
"Retrieves all leads from an account, handling pagination automatically.": "Retrieves all leads from an account, handling pagination automatically.",
"Update an existing lead's attributes by its ID.": "Update an existing lead's attributes by its ID.",
"Find a lead by various criteria.": "Find a lead by various criteria.",
"Account": "Account",
"Profile": "Profile",
"Lead Type": "Lead Type",
"First Name": "First Name",
"Last Name": "Last Name",
"Email": "Email",
"Phone Number": "Phone Number",
"Company Name": "Company Name",
"Notes": "Notes",
"Referring Source": "Referring Source",
"Referring Medium": "Referring Medium",
"Send Notification": "Send Notification",
"Creation Date": "Creation Date",
"Quotable": "Quotable",
"Quote Value": "Quote Value",
"Sales Value": "Sales Value",
"Start Date": "Start Date",
"End Date": "End Date",
"Lead Type (Optional)": "Lead Type (Optional)",
"Leads Per Page": "Leads Per Page",
"Number of Pages": "Number of Pages",
"Lead": "Lead",
"Referring Campaign": "Referring Campaign",
"Email Address": "Email Address",
"The account to select a profile from.": "The account to select a profile from.",
"The profile to search for leads in.": "The profile to search for leads in.",
"The type of the lead.": "The type of the lead.",
"The source of the lead (e.g., \"google\").": "The source of the lead (e.g., \"google\").",
"The medium of the lead (e.g., \"cpc\").": "The medium of the lead (e.g., \"cpc\").",
"Set to true to send a new lead notification email.": "Set to true to send a new lead notification email.",
"The date and time when the lead was created.": "The date and time when the lead was created.",
"Indicates if the lead is quotable.": "Indicates if the lead is quotable.",
"The monetary value of the quote associated with the lead.": "The monetary value of the quote associated with the lead.",
"The monetary value of the sale associated with the lead.": "The monetary value of the sale associated with the lead.",
"The start date for the export range in YYYY-MM-DD format.": "The start date for the export range in YYYY-MM-DD format.",
"The end date for the export range in YYYY-MM-DD format.": "The end date for the export range in YYYY-MM-DD format.",
"Filter leads by their type.": "Filter leads by their type.",
"Number of leads to fetch per page (max 1000).": "Number of leads to fetch per page (max 1000).",
"The number of pages to retrieve (max 100).": "The number of pages to retrieve (max 100).",
"The lead to update.": "The lead to update.",
"Mark the lead as quotable.": "Mark the lead as quotable.",
"The monetary value of the lead (e.g., \"150.00\").": "The monetary value of the lead (e.g., \"150.00\").",
"The campaign that generated the lead.": "The campaign that generated the lead.",
"Find a lead by their email address.": "Find a lead by their email address.",
"Find a lead by their E.164 formatted phone number.": "Find a lead by their E.164 formatted phone number.",
"The number of leads to return (default 25, max 2500).": "The number of leads to return (default 25, max 2500).",
"Phone Call": "Phone Call",
"Web Form": "Web Form",
"Chat": "Chat",
"Transaction": "Transaction",
"Event": "Event",
"Appointment": "Appointment",
"Text Message": "Text Message",
"Google": "Google",
"Bing": "Bing",
"Facebook": "Facebook",
"LinkedIn": "LinkedIn",
"Twitter": "Twitter",
"Instagram": "Instagram",
"Direct Traffic": "Direct Traffic",
"Organic Search": "Organic Search",
"Paid Search (CPC)": "Paid Search (CPC)",
"Social Media": "Social Media",
"Referral": "Referral",
"Display Ad": "Display Ad",
"None (for Direct Traffic)": "None (for Direct Traffic)",
"Yes": "Yes",
"No": "No",
"Pending": "Pending",
"Not Set": "Not Set",
"Other": "Other",
"Summer Sale": "Summer Sale",
"Q4 Promotion": "Q4 Promotion",
"New Product Launch": "New Product Launch",
"Brand Awareness": "Brand Awareness",
"New Lead": "New Lead",
"Updated Lead": "Updated Lead",
"Fires when a new lead is received.": "Fires when a new lead is received.",
"Fires when an existing lead is updated in WhatConverts.": "Fires when an existing lead is updated in WhatConverts."
}

View File

@@ -0,0 +1,94 @@
{
"API Token": "API Token",
"API Secret": "API Secret",
"Your WhatConverts API Token.": "Your WhatConverts API Token.",
"Your WhatConverts API Secret.": "Your WhatConverts API Secret.",
"\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ": "\n To get your API credentials:\n 1. Log in to your WhatConverts dashboard.\n 2. Navigate to an account and select a profile.\n 3. Select the **Tracking** dropdown menu.\n 4. Click on **Integrations**, then **API Keys**.\n 5. Click **Generate API Key** to get your Token and Secret.\n ",
"Create Lead": "Create Lead",
"Export Leads": "Export Leads",
"Update Lead": "Update Lead",
"Find Lead": "Find Lead",
"Create a new lead in WhatConverts.": "Create a new lead in WhatConverts.",
"Retrieves all leads from an account, handling pagination automatically.": "Retrieves all leads from an account, handling pagination automatically.",
"Update an existing lead's attributes by its ID.": "Update an existing lead's attributes by its ID.",
"Find a lead by various criteria.": "Find a lead by various criteria.",
"Account": "Account",
"Profile": "Profile",
"Lead Type": "Lead Type",
"First Name": "First Name",
"Last Name": "名字",
"Email": "电子邮件地址",
"Phone Number": "Phone Number",
"Company Name": "Company Name",
"Notes": "Notes",
"Referring Source": "Referring Source",
"Referring Medium": "Referring Medium",
"Send Notification": "Send Notification",
"Creation Date": "Creation Date",
"Quotable": "Quotable",
"Quote Value": "Quote Value",
"Sales Value": "Sales Value",
"Start Date": "Start Date",
"End Date": "End Date",
"Lead Type (Optional)": "Lead Type (Optional)",
"Leads Per Page": "Leads Per Page",
"Number of Pages": "Number of Pages",
"Lead": "Lead",
"Referring Campaign": "Referring Campaign",
"Email Address": "Email Address",
"The account to select a profile from.": "The account to select a profile from.",
"The profile to search for leads in.": "The profile to search for leads in.",
"The type of the lead.": "The type of the lead.",
"The source of the lead (e.g., \"google\").": "The source of the lead (e.g., \"google\").",
"The medium of the lead (e.g., \"cpc\").": "The medium of the lead (e.g., \"cpc\").",
"Set to true to send a new lead notification email.": "Set to true to send a new lead notification email.",
"The date and time when the lead was created.": "The date and time when the lead was created.",
"Indicates if the lead is quotable.": "Indicates if the lead is quotable.",
"The monetary value of the quote associated with the lead.": "The monetary value of the quote associated with the lead.",
"The monetary value of the sale associated with the lead.": "The monetary value of the sale associated with the lead.",
"The start date for the export range in YYYY-MM-DD format.": "The start date for the export range in YYYY-MM-DD format.",
"The end date for the export range in YYYY-MM-DD format.": "The end date for the export range in YYYY-MM-DD format.",
"Filter leads by their type.": "Filter leads by their type.",
"Number of leads to fetch per page (max 1000).": "Number of leads to fetch per page (max 1000).",
"The number of pages to retrieve (max 100).": "The number of pages to retrieve (max 100).",
"The lead to update.": "The lead to update.",
"Mark the lead as quotable.": "Mark the lead as quotable.",
"The monetary value of the lead (e.g., \"150.00\").": "The monetary value of the lead (e.g., \"150.00\").",
"The campaign that generated the lead.": "The campaign that generated the lead.",
"Find a lead by their email address.": "Find a lead by their email address.",
"Find a lead by their E.164 formatted phone number.": "Find a lead by their E.164 formatted phone number.",
"The number of leads to return (default 25, max 2500).": "The number of leads to return (default 25, max 2500).",
"Phone Call": "Phone Call",
"Web Form": "Web Form",
"Chat": "Chat",
"Transaction": "Transaction",
"Event": "Event",
"Appointment": "Appointment",
"Text Message": "Text Message",
"Google": "Google",
"Bing": "Bing",
"Facebook": "Facebook",
"LinkedIn": "LinkedIn",
"Twitter": "Twitter",
"Instagram": "Instagram",
"Direct Traffic": "Direct Traffic",
"Organic Search": "Organic Search",
"Paid Search (CPC)": "Paid Search (CPC)",
"Social Media": "Social Media",
"Referral": "Referral",
"Display Ad": "Display Ad",
"None (for Direct Traffic)": "None (for Direct Traffic)",
"Yes": "Yes",
"No": "No",
"Pending": "待處理",
"Not Set": "Not Set",
"Other": "Other",
"Summer Sale": "Summer Sale",
"Q4 Promotion": "Q4 Promotion",
"New Product Launch": "New Product Launch",
"Brand Awareness": "Brand Awareness",
"New Lead": "New Lead",
"Updated Lead": "Updated Lead",
"Fires when a new lead is received.": "Fires when a new lead is received.",
"Fires when an existing lead is updated in WhatConverts.": "Fires when an existing lead is updated in WhatConverts."
}

View File

@@ -0,0 +1,25 @@
import { createPiece } from '@activepieces/pieces-framework';
import { whatConvertsAuth } from '../src/lib/common/auth';
import { createLeadAction } from '../src/lib/actions/create-lead';
import { exportLeadsAction } from '../src/lib/actions/create-export';
import { updateLeadAction } from '../src/lib/actions/update-lead';
import { findLeadAction } from '../src/lib/actions/find-lead';
import { newLeadTrigger } from '../src/lib/triggers/new-lead';
import { updatedLeadTrigger } from '../src/lib/triggers/update-lead';
import { PieceCategory } from '@activepieces/shared';
export const whatConverts = createPiece({
displayName: 'WhatConverts',
auth: whatConvertsAuth,
minimumSupportedRelease: '0.36.1',
logoUrl: 'https://cdn.activepieces.com/pieces/what-converts.png',
authors: ['Prabhukiran161', 'sanket-a11y'],
categories: [PieceCategory.SALES_AND_CRM, PieceCategory.MARKETING],
actions: [
createLeadAction,
exportLeadsAction,
updateLeadAction,
findLeadAction,
],
triggers: [newLeadTrigger, updatedLeadTrigger],
});

View File

@@ -0,0 +1,96 @@
import { createAction, Property } from '@activepieces/pieces-framework';
import { whatConvertsAuth } from '../common/auth';
import { whatConvertsClient } from '../common/client';
import { whatConvertsProps } from '../common/props';
import { Lead } from '../common/types';
export const exportLeadsAction = createAction({
auth: whatConvertsAuth,
name: 'export_leads',
displayName: 'Export Leads',
description:
'Retrieves all leads from an account, handling pagination automatically.',
props: {
account_id: whatConvertsProps.account_id(),
profile_id: whatConvertsProps.profile_id(),
from_date: Property.ShortText({
displayName: 'Start Date',
description: 'The start date for the export range in YYYY-MM-DD format.',
required: false,
}),
to_date: Property.ShortText({
displayName: 'End Date',
description: 'The end date for the export range in YYYY-MM-DD format.',
required: false,
}),
lead_type: Property.StaticDropdown({
displayName: 'Lead Type (Optional)',
description: 'Filter leads by their type.',
required: false,
options: {
options: [
{ label: 'Appointment', value: 'appointment' },
{ label: 'Chat', value: 'chat' },
{ label: 'Email', value: 'email' },
{ label: 'Event', value: 'event' },
{ label: 'Other', value: 'other' },
{ label: 'Phone Call', value: 'phone_call' },
{ label: 'Text Message', value: 'text_message' },
{ label: 'Transaction', value: 'transaction' },
{ label: 'Web Form', value: 'web_form' },
],
},
}),
per_page: Property.Number({
displayName: 'Leads Per Page',
description: 'Number of leads to fetch per page (max 1000).',
required: false,
defaultValue: 25,
}),
no_of_pages: Property.Number({
displayName: 'Number of Pages',
description: 'The number of pages to retrieve (max 100).',
required: false,
defaultValue: 1,
}),
},
async run(context) {
const { auth, propsValue } = context;
const { profile_id, from_date, to_date, lead_type, per_page } = propsValue;
if (profile_id === undefined) {
throw new Error('Profile ID is required for exporting leads.');
}
const initialResponse = await whatConvertsClient.findLeads(auth, {
profile_id: profile_id,
from_date: from_date,
to_date: to_date,
lead_type: lead_type,
per_page: per_page,
page_number: 1,
});
let allLeads: Lead[] = initialResponse.leads || [];
const totalPages = Math.min(
initialResponse.total_pages || 1,
propsValue.no_of_pages || 1,
100
);
for (let page = 2; page <= totalPages; page++) {
const response = await whatConvertsClient.findLeads(auth, {
profile_id: profile_id,
from_date: from_date,
to_date: to_date,
lead_type: lead_type,
per_page: per_page,
page_number: page,
});
allLeads = allLeads.concat(response.leads || []);
}
return allLeads;
},
});

View File

@@ -0,0 +1,155 @@
import { createAction, Property } from '@activepieces/pieces-framework';
import { whatConvertsAuth } from '../common/auth';
import { whatConvertsProps } from '../common/props';
import { whatConvertsClient } from '../common/client';
export const createLeadAction = createAction({
auth: whatConvertsAuth,
name: 'create_lead',
displayName: 'Create Lead',
description: 'Create a new lead in WhatConverts.',
props: {
account_id: whatConvertsProps.account_id(),
profile_id: whatConvertsProps.profile_id(),
lead_type: Property.StaticDropdown({
displayName: 'Lead Type',
description: 'The type of the lead.',
required: true,
options: {
options: [
{ label: 'Phone Call', value: 'phone_call' },
{ label: 'Web Form', value: 'web_form' },
{ label: 'Chat', value: 'chat' },
{ label: 'Transaction', value: 'transaction' },
{ label: 'Event', value: 'event' },
{ label: 'Appointment', value: 'appointment' },
{ label: 'Text Message', value: 'text_message' },
],
},
}),
first_name: Property.ShortText({
displayName: 'First Name',
required: false,
}),
last_name: Property.ShortText({
displayName: 'Last Name',
required: false,
}),
email: Property.ShortText({
displayName: 'Email',
required: false,
}),
phone_number: Property.ShortText({
displayName: 'Phone Number',
required: false,
}),
company_name: Property.ShortText({
displayName: 'Company Name',
required: false,
}),
notes: Property.LongText({
displayName: 'Notes',
required: false,
}),
referring_source: Property.StaticDropdown({
displayName: 'Referring Source',
description: 'The source of the lead (e.g., "google").',
required: false,
options: {
options: [
{ label: 'Google', value: 'google' },
{ label: 'Bing', value: 'bing' },
{ label: 'Facebook', value: 'facebook' },
{ label: 'LinkedIn', value: 'linkedin' },
{ label: 'Twitter', value: 'twitter' },
{ label: 'Instagram', value: 'instagram' },
{ label: 'Direct Traffic', value: '(direct)' },
],
},
}),
referring_medium: Property.StaticDropdown({
displayName: 'Referring Medium',
description: 'The medium of the lead (e.g., "cpc").',
required: false,
options: {
options: [
{ label: 'Organic Search', value: 'organic' },
{ label: 'Paid Search (CPC)', value: 'cpc' },
{ label: 'Social Media', value: 'social' },
{ label: 'Email', value: 'email' },
{ label: 'Referral', value: 'referral' },
{ label: 'Display Ad', value: 'display' },
{ label: 'None (for Direct Traffic)', value: '(none)' },
],
},
}),
send_notification: Property.Checkbox({
displayName: 'Send Notification',
description: 'Set to true to send a new lead notification email.',
required: true,
defaultValue: false,
}),
date_created : Property.DateTime({
displayName: 'Creation Date',
description: 'The date and time when the lead was created.',
required: false,
}),
quotable: Property.StaticDropdown({
displayName: 'Quotable',
description: 'Indicates if the lead is quotable.',
required: false,
options: {
options: [
{ label: 'Yes', value: 'yes' },
{ label: 'No', value: 'no' },
{ label: 'Pending', value: 'pending' },
{ label: 'Not Set', value: 'not_set' },
],
},
}),
quote_value: Property.Number({
displayName: 'Quote Value',
description: 'The monetary value of the quote associated with the lead.',
required: false,
}),
sales_value: Property.Number({
displayName: 'Sales Value',
description: 'The monetary value of the sale associated with the lead.',
required: false,
}),
},
async run(context) {
const { auth, propsValue } = context;
if (propsValue.account_id === undefined) {
throw new Error('Account ID is required.');
}
if (propsValue.profile_id === undefined) {
throw new Error('Profile ID is required.');
}
const contactName = [propsValue.first_name, propsValue.last_name]
.filter(Boolean)
.join(' ')
.trim();
return await whatConvertsClient.createLead(auth, propsValue.account_id, {
profile_id: propsValue.profile_id as number,
lead_type: propsValue.lead_type,
send_notification: propsValue.send_notification,
referring_source: propsValue.referring_source,
referring_medium: propsValue.referring_medium,
contact_name: contactName || undefined,
email_address: propsValue.email,
phone_number: propsValue.phone_number,
company_name: propsValue.company_name,
notes: propsValue.notes,
date_created: propsValue.date_created,
quotable: propsValue.quotable,
quote_value: propsValue.quote_value,
sales_value: propsValue.sales_value,
});
},
});

View File

@@ -0,0 +1,72 @@
import { createAction, Property } from '@activepieces/pieces-framework';
import { whatConvertsAuth } from '../common/auth';
import { whatConvertsProps } from '../common/props';
import { whatConvertsClient } from '../common/client';
export const findLeadAction = createAction({
auth: whatConvertsAuth,
name: 'find_lead',
displayName: 'Find Lead',
description: 'Find a lead by various criteria.',
props: {
account_id: whatConvertsProps.account_id(),
profile_id: whatConvertsProps.profile_id(),
email_address: Property.ShortText({
displayName: 'Email Address',
description: 'Find a lead by their email address.',
required: false,
}),
phone_number: Property.ShortText({
displayName: 'Phone Number',
description: 'Find a lead by their E.164 formatted phone number.',
required: false,
}),
lead_type: Property.StaticDropdown({
displayName: 'Lead Type',
description: 'Filter leads by their type.',
required: false,
options: {
options: [
{ label: 'Appointment', value: 'appointment' },
{ label: 'Chat', value: 'chat' },
{ label: 'Email', value: 'email' },
{ label: 'Event', value: 'event' },
{ label: 'Other', value: 'other' },
{ label: 'Phone Call', value: 'phone_call' },
{ label: 'Text Message', value: 'text_message' },
{ label: 'Transaction', value: 'transaction' },
{ label: 'Web Form', value: 'web_form' },
],
},
}),
per_page: Property.Number({
displayName: 'Leads Per Page',
description: 'The number of leads to return (default 25, max 2500).',
required: false,
}),
},
async run(context) {
const { auth, propsValue } = context;
const searchCriteria = [
propsValue.email_address,
propsValue.phone_number,
propsValue.lead_type,
];
if (searchCriteria.every((criterion) => !criterion)) {
throw new Error(
'Please provide at least one search criteria (Email, Phone, or Lead Type).'
);
}
return await whatConvertsClient.findLeads(auth, {
profile_id: propsValue.profile_id,
email_address: propsValue.email_address,
phone_number: propsValue.phone_number,
lead_type: propsValue.lead_type,
per_page: propsValue.per_page,
});
},
});

View File

@@ -0,0 +1,148 @@
import { createAction, Property } from '@activepieces/pieces-framework';
import { whatConvertsAuth } from '../common/auth';
import { whatConvertsClient } from '../common/client';
import { whatConvertsProps } from '../common/props';
export const updateLeadAction = createAction({
auth: whatConvertsAuth,
name: 'update_lead',
displayName: 'Update Lead',
description: "Update an existing lead's attributes by its ID.",
props: {
account_id: whatConvertsProps.account_id(),
profile_id: whatConvertsProps.profile_id(true),
lead_id: whatConvertsProps.lead_id(),
lead_type: Property.StaticDropdown({
displayName: 'Lead Type',
description: 'The type of the lead.',
required: false,
options: {
options: [
{ label: 'Phone Call', value: 'Phone Call' },
{ label: 'Web Form', value: 'Web Form' },
{ label: 'Chat', value: 'Chat' },
{ label: 'Transaction', value: 'Transaction' },
{ label: 'Event', value: 'Event' },
],
},
}),
quotable: Property.StaticDropdown({
displayName: 'Quotable',
description: 'Mark the lead as quotable.',
required: false,
options: {
options: [
{ label: 'Yes', value: 'Yes' },
{ label: 'No', value: 'No' },
],
},
}),
sales_value: Property.ShortText({
displayName: 'Sales Value',
description: 'The monetary value of the lead (e.g., "150.00").',
required: false,
}),
first_name: Property.ShortText({
displayName: 'First Name',
required: false,
}),
last_name: Property.ShortText({
displayName: 'Last Name',
required: false,
}),
email: Property.ShortText({
displayName: 'Email',
required: false,
}),
phone_number: Property.ShortText({
displayName: 'Phone Number',
required: false,
}),
notes: Property.LongText({
displayName: 'Notes',
required: false,
}),
referring_source: Property.StaticDropdown({
displayName: 'Referring Source',
description: 'The source of the lead (e.g., "google").',
required: false,
options: {
options: [
{ label: 'Google', value: 'google' },
{ label: 'Bing', value: 'bing' },
{ label: 'Facebook', value: 'facebook' },
{ label: 'LinkedIn', value: 'linkedin' },
{ label: 'Twitter', value: 'twitter' },
{ label: 'Instagram', value: 'instagram' },
{ label: 'Direct Traffic', value: '(direct)' },
],
},
}),
referring_medium: Property.StaticDropdown({
displayName: 'Referring Medium',
description: 'The medium of the lead (e.g., "cpc").',
required: false,
options: {
options: [
{ label: 'Organic Search', value: 'organic' },
{ label: 'Paid Search (CPC)', value: 'cpc' },
{ label: 'Social Media', value: 'social' },
{ label: 'Email', value: 'email' },
{ label: 'Referral', value: 'referral' },
{ label: 'Display Ad', value: 'display' },
{ label: 'None (for Direct Traffic)', value: '(none)' },
],
},
}),
referring_campaign: Property.StaticDropdown({
displayName: 'Referring Campaign',
description: 'The campaign that generated the lead.',
required: false,
options: {
options: [
{ label: 'Summer Sale', value: 'summer-sale' },
{ label: 'Q4 Promotion', value: 'q4-promo' },
{ label: 'New Product Launch', value: 'new-product-launch' },
{ label: 'Brand Awareness', value: 'brand-awareness' },
],
},
}),
},
async run(context) {
const { auth, propsValue } = context;
if (propsValue.lead_id === undefined) {
throw new Error('Lead ID is required to update a lead.');
}
const body: { [key: string]: unknown } = {};
const leadDetails: { [key: string]: unknown } = {};
const addIfExists = (
obj: { [key: string]: unknown },
key: string,
value: unknown
) => {
if (value !== undefined && value !== null && value !== '') {
obj[key] = value;
}
};
addIfExists(body, 'lead_type', propsValue.lead_type);
addIfExists(body, 'quotable', propsValue.quotable);
addIfExists(body, 'sales_value', propsValue.sales_value);
addIfExists(body, 'referring_source', propsValue.referring_source);
addIfExists(body, 'referring_medium', propsValue.referring_medium);
addIfExists(body, 'referring_campaign', propsValue.referring_campaign);
addIfExists(leadDetails, 'first_name', propsValue.first_name);
addIfExists(leadDetails, 'last_name', propsValue.last_name);
addIfExists(leadDetails, 'email', propsValue.email);
addIfExists(leadDetails, 'phone_number', propsValue.phone_number);
addIfExists(leadDetails, 'notes', propsValue.notes);
if (Object.keys(leadDetails).length > 0) {
body['lead_details'] = leadDetails;
}
return await whatConvertsClient.updateLead(auth, propsValue.lead_id, body);
},
});

View File

@@ -0,0 +1,66 @@
import {
AppConnectionValueForAuthProperty,
PieceAuth,
Property,
StaticPropsValue,
} from '@activepieces/pieces-framework';
import {
httpClient,
HttpMethod,
AuthenticationType,
} from '@activepieces/pieces-common';
const WHATCONVERTS_API_URL = 'https://app.whatconverts.com/api/v1';
const whatConvertsAuthProps = {
api_token: Property.ShortText({
displayName: 'API Token',
description: 'Your WhatConverts API Token.',
required: true,
}),
api_secret: PieceAuth.SecretText({
displayName: 'API Secret',
description: 'Your WhatConverts API Secret.',
required: true,
}),
};
export const whatConvertsAuth = PieceAuth.CustomAuth({
description: `
To get your API credentials:
1. Log in to your WhatConverts dashboard.
2. Navigate to an account and select a profile.
3. Select the **Tracking** dropdown menu.
4. Click on **Integrations**, then **API Keys**.
5. Click **Generate API Key** to get your Token and Secret.
`,
required: true,
props: whatConvertsAuthProps,
validate: async ({ auth }) => {
try {
await httpClient.sendRequest({
method: HttpMethod.GET,
url: `${WHATCONVERTS_API_URL}/leads`,
authentication: {
type: AuthenticationType.BASIC,
username: auth.api_token,
password: auth.api_secret,
},
queryParams: {
per_page: '1',
},
});
return {
valid: true,
};
} catch (e) {
return {
valid: false,
error:
'Invalid API Token or Secret. Please check your credentials and try again.',
};
}
},
});
export type WhatConvertsAuth = AppConnectionValueForAuthProperty<typeof whatConvertsAuth>;

View File

@@ -0,0 +1,120 @@
import {
AuthenticationType,
httpClient,
HttpMethod,
HttpRequest,
QueryParams,
} from '@activepieces/pieces-common';
import { WhatConvertsAuth } from './auth';
import {
CreateLeadParams,
FindLeadParams,
LeadsResponse,
Profile,
ProfilesResponse,
UpdateLeadParams,
AccountsResponse,
Account,
} from './types';
const WHATCONVERTS_API_URL = 'https://app.whatconverts.com/api/v1';
export const whatConvertsClient = {
async getAccounts(auth: WhatConvertsAuth): Promise<Account[]> {
const request: HttpRequest = {
method: HttpMethod.GET,
url: `${WHATCONVERTS_API_URL}/accounts`,
authentication: {
type: AuthenticationType.BASIC,
username: auth.props.api_token,
password: auth.props.api_secret,
},
};
const response = await httpClient.sendRequest<AccountsResponse>(request);
return response.body.accounts;
},
async getProfiles(
auth: WhatConvertsAuth,
accountId: number
): Promise<Profile[]> {
const request: HttpRequest = {
method: HttpMethod.GET,
url: `${WHATCONVERTS_API_URL}/accounts/${accountId}/profiles`,
authentication: {
type: AuthenticationType.BASIC,
username: auth.props. api_token,
password: auth.props.api_secret,
},
};
const response = await httpClient.sendRequest<ProfilesResponse>(request);
return response.body.profiles;
},
async createLead(
auth: WhatConvertsAuth,
accountId: number,
params: CreateLeadParams
) {
const request: HttpRequest = {
method: HttpMethod.POST,
url: `${WHATCONVERTS_API_URL}/leads`,
authentication: {
type: AuthenticationType.BASIC,
username: auth.props.api_token,
password: auth.props.api_secret,
},
body: params,
headers: {
'Content-Type': 'application/x-www-form-urlencoded',
},
};
const response = await httpClient.sendRequest(request);
return response.body;
},
async findLeads(
auth: WhatConvertsAuth,
params: FindLeadParams
): Promise<LeadsResponse> {
const queryParams: QueryParams = {};
Object.keys(params).forEach((key) => {
const value = params[key as keyof FindLeadParams];
if (value !== undefined && value !== null && value !== '') {
queryParams[key] = value.toString();
}
});
const request: HttpRequest = {
method: HttpMethod.GET,
url: `${WHATCONVERTS_API_URL}/leads`,
authentication: {
type: AuthenticationType.BASIC,
username: auth.props.api_token,
password: auth.props.api_secret,
},
queryParams: queryParams,
};
const response = await httpClient.sendRequest<LeadsResponse>(request);
return response.body;
},
async updateLead(
auth: WhatConvertsAuth,
leadId: number,
params: UpdateLeadParams
) {
const request: HttpRequest = {
method: HttpMethod.POST,
url: `${WHATCONVERTS_API_URL}/leads/${leadId}`,
authentication: {
type: AuthenticationType.BASIC,
username: auth.props.api_token,
password: auth.props. api_secret,
},
body: params,
};
const response = await httpClient.sendRequest(request);
return response.body;
},
};

View File

@@ -0,0 +1,103 @@
import { Property } from '@activepieces/pieces-framework';
import { whatConvertsAuth, WhatConvertsAuth } from './auth';
import { whatConvertsClient } from './client';
export const whatConvertsProps = {
account_id: () =>
Property.Dropdown({
auth: whatConvertsAuth,
displayName: 'Account',
description: 'The account to select a profile from.',
required: true,
refreshers: ['auth'],
options: async ({ auth }) => {
if (!auth) {
return {
disabled: true,
placeholder: 'Please authenticate first.',
options: [],
};
}
const accounts = await whatConvertsClient.getAccounts(
auth as WhatConvertsAuth
);
return {
disabled: false,
options: accounts.map((account) => ({
label: account.account_name,
value: account.account_id,
})),
};
},
}),
profile_id: (required = true) =>
Property.Dropdown({
auth: whatConvertsAuth,
displayName: 'Profile',
description: 'The profile to search for leads in.',
required: required,
refreshers: ['auth', 'account_id'],
options: async ({ auth, account_id }) => {
if (!auth || !account_id) {
return {
disabled: true,
placeholder: 'Please select an account first.',
options: [],
};
}
const profiles = await whatConvertsClient.getProfiles(
auth as WhatConvertsAuth,
account_id as number
);
return {
disabled: false,
options: profiles.map((profile) => ({
label: profile.profile_name,
value: profile.profile_id,
})),
};
},
}),
lead_id: () =>
Property.Dropdown({
auth: whatConvertsAuth,
displayName: 'Lead',
description: 'The lead to update.',
required: true,
refreshers: ['auth', 'profile_id'],
options: async ({ auth, profile_id }) => {
if (!auth || !profile_id) {
return {
disabled: true,
placeholder: 'Please select a profile first.',
options: [],
};
}
const response = await whatConvertsClient.findLeads(
auth as WhatConvertsAuth,
{
profile_id: profile_id as number,
per_page: 50,
}
);
return {
disabled: false,
options: (response.leads || []).map((lead) => {
const emailDetail = lead.lead_details?.find(
(d) => d.label === 'Email'
);
const nameDetail = lead.lead_details?.find(
(d) => d.label === 'First Name'
);
const label = `${
nameDetail?.value || emailDetail?.value || lead.lead_type
} (ID: ${lead.lead_id})`;
return {
label: label,
value: lead.lead_id,
};
}),
};
},
}),
};

View File

@@ -0,0 +1,78 @@
export interface Profile {
profile_id: number;
profile_name: string;
}
export interface ProfilesResponse {
profiles: Profile[];
}
export interface CreateLeadParams {
profile_id: number;
lead_type: string;
referring_source?: string;
referring_medium?: string;
send_notification?: boolean;
contact_name?: string;
email_address?: string;
phone_number?: string;
company_name?: string;
notes?: string;
date_created?: string;
quotable?: string;
quote_value?: number;
sales_value?: number;
}
export interface FindLeadParams {
profile_id?: number;
email_address?: string;
phone_number?: string;
lead_type?: string;
per_page?: number;
from_date?: string;
to_date?: string;
page_number?: number;
}
export interface CreateExportParams {
profile_id: number;
from_date: string;
to_date: string;
export_type?: string;
}
export interface UpdateLeadParams {
lead_type?: string;
quotable?: 'Yes' | 'No';
sales_value?: string;
referring_source?: string;
referring_medium?: string;
referring_campaign?: string;
lead_details?: { [key: string]: unknown };
}
export interface LeadDetail {
label: string;
value: string;
}
export interface Lead {
lead_id: number;
lead_type: string;
lead_details: LeadDetail[];
}
export interface LeadsResponse {
leads: Lead[];
total_pages: number;
}
export interface Account {
account_id: number;
account_name: string;
}
export interface AccountsResponse {
accounts: Account[];
}

View File

@@ -0,0 +1,110 @@
import {
createTrigger,
Property,
TriggerStrategy,
} from '@activepieces/pieces-framework';
import { whatConvertsAuth } from '../common/auth';
export const newLeadTrigger = createTrigger({
auth: whatConvertsAuth,
name: 'new_lead',
displayName: 'New Lead',
description: 'Fires when a new lead is received.',
props: {},
sampleData: {
trigger: 'new',
lead_id: 153928,
user_id: '51497-af17340d-62b8-3044-423f-3dc754e621c2',
lead_type: 'Phone Call',
lead_status: 'Unique',
lead_analysis: {
'Keyword Detection': 'buy,quote,test',
'Lead Summary':
'The customer was looking to purchase call tracking services. The agent assisted them with setting up an account.',
'Intent Detection': 'The customer wanted to purchase services.',
'Sentiment Detection': 'Positive',
'Topic Detection': 'call tracking,purchase,sign up',
},
last_updated: '2016-01-25T17:18:20Z',
date_created: '2016-02-01T14:09:01Z',
quotable: 'Not Set',
quote_value: null,
sales_value: null,
spotted_keywords: 'buy,quote',
lead_score: 50,
lead_state: 'Completed',
profile: 'My Profile',
profile_id: 51497,
account: 'My Account',
account_id: 27313,
lead_url: 'https://www.whatconverts.com/contact',
landing_url: 'https://www.whatconverts.com/',
operating_system: 'iOS 12',
browser: 'Chrome Mobile 71',
device_type: 'Smartphone',
device_make: 'Apple iPhone',
lead_source: 'google',
lead_medium: 'cpc',
lead_campaign: 'lead generation',
lead_content: 'new ad',
lead_keyword: 'generating leads',
ip_address: '107.210.21.188',
notes: 'This is a new lead!',
contact_name: 'Jeremy Helms',
contact_company_name: 'Call Tracking Company',
contact_email_address: 'hello@whatconverts.com',
contact_phone_number: '+18887203034',
email_address: 'hello@whatconverts.com',
phone_number: '+18887203034',
city: 'Charlotte',
state: 'NC',
zip: '28226',
country: 'US',
field_mappings: {
'Company Name': 'Call Tracking Company',
'Contact Person': 'Jeremy Helms',
Email: 'hello@whatconverts.com',
'Phone Number': '(888) 720-3034',
},
gclid: 'CLibmtmqpNICFcSfGwodQbUAvg',
msclkid: '25d83debf85f146b8f1d66a754c6a56c',
unbounce_page_id: 'f8e32bbc-e1a1-2c5b-b4d3-c6289c8e33b',
unbounce_variant_id: 'b',
unbounce_visitor_id: '107.210.21.1881565955056416071',
salesforce_user_id: '15228103840',
roistat_visit_id: 'wqeOuWjfeIUQdd122casdLK',
hubspot_visitor_id: '5a72d290d2d21865a693f14bcf710fed',
facebook_browser_id: 'fb.1.1621529626600.927228660',
facebook_click_id:
'fb.1.1621529626598.IwAR1yDeb6_5RRDGD3fTthh9cPoaqhLYYyDFLN-LolvQwaMAPMhGRljDj-POc',
google_analytics_client_id: '1017418163.1594157791',
vwo_account_id: '512835',
vwo_experiment_id: '2',
vwo_variant_id: '2',
vwo_user_id: 'D4A14C3EFD6DB2A51749E1A931BE96B44',
duplicate: false,
spam: false,
},
type: TriggerStrategy.WEBHOOK,
async onEnable(_context) {
// User configures the webhook manually in the WhatConverts UI.
},
async onDisable(_context) {
// User removes the webhook manually in the WhatConverts UI.
},
async run(context) {
const payloadBody = context.payload.body as {
trigger: string;
lead_type: string;
};
if (payloadBody.trigger !== 'new') {
return [];
}
return [context.payload.body];
},
});

View File

@@ -0,0 +1,91 @@
import { createTrigger, TriggerStrategy } from '@activepieces/pieces-framework';
import { whatConvertsAuth } from '../common/auth';
export const updatedLeadTrigger = createTrigger({
auth: whatConvertsAuth,
name: 'updated_lead',
displayName: 'Updated Lead',
description: 'Fires when an existing lead is updated in WhatConverts.',
props: {},
sampleData: {
trigger: 'update',
lead_id: 153928,
user_id: '51497-af17340d-62b8-3044-423f-3dc754e621c2',
lead_type: 'Phone Call',
lead_status: 'Unique',
last_updated: '2016-01-25T17:18:20Z',
date_created: '2016-02-01T14:09:01Z',
quotable: 'Not Set',
quote_value: null,
sales_value: null,
spotted_keywords: 'buy,quote',
lead_score: 50,
lead_state: 'Completed',
profile: 'My Profile',
profile_id: 51497,
account: 'My Account',
account_id: 27313,
lead_url: 'https://www.whatconverts.com/contact',
landing_url: 'https://www.whatconverts.com/',
lead_source: 'google',
lead_medium: 'cpc',
lead_campaign: 'lead generation',
lead_content: 'new ad',
lead_keyword: 'generating leads',
ip_address: '107.210.21.188',
notes: 'This is a new lead!',
contact_name: 'Jeremy Helms',
contact_company_name: 'Call Tracking Company',
contact_email_address: 'hello@whatconverts.com',
contact_phone_number: '+18887203034',
email_address: 'hello@whatconverts.com',
phone_number: '+18887203034',
city: 'Charlotte',
state: 'NC',
zip: '28226',
country: 'US',
field_mappings: {
'Company Name': 'Call Tracking Company',
'Contact Person': 'Jeremy Helms',
Email: 'hello@whatconverts.com',
'Phone Number': '(888) 720-3034',
},
gclid: 'CLibmtmqpNICFcSfGwodQbUAvg',
msclkid: '25d83debf85f146b8f1d66a754c6a56c',
unbounce_page_id: 'f8e32bbc-e1a1-2c5b-b4d3-c6289c8e33b',
unbounce_variant_id: 'b',
unbounce_visitor_id: '107.210.21.1881565955056416071',
salesforce_user_id: '15228103840',
roistat_visit_id: 'wqeOuWjfeIUQdd122casdLK',
hubspot_visitor_id: '5a72d290d2d21865a693f14bcf710fed',
facebook_browser_id: 'fb.1.1621529626600.927228660',
facebook_click_id:
'fb.1.1621529626598.IwAR1yDeb6_5RRDGD3fTthh9cPoaqhLYYyDFLN-LolvQwaMAPMhGRljDj-POc',
google_analytics_client_id: '1017418163.1594157791',
vwo_account_id: '512835',
vwo_experiment_id: '2',
vwo_variant_id: '2',
vwo_user_id: 'D4A14C3EFD6DB2A51749E1A931BE96B44',
duplicate: false,
spam: false,
},
type: TriggerStrategy.WEBHOOK,
async onEnable(_context) {
// User configures the webhook manually in the WhatConverts UI.
},
async onDisable(_context) {
// User removes the webhook manually in the WhatConverts UI.
},
async run(context) {
const payloadBody = context.payload.body as { trigger: string };
if (payloadBody.trigger !== 'update') {
return [];
}
return [context.payload.body];
},
});

View File

@@ -0,0 +1,20 @@
{
"extends": "../../../../tsconfig.base.json",
"compilerOptions": {
"module": "commonjs",
"forceConsistentCasingInFileNames": true,
"strict": true,
"importHelpers": true,
"noImplicitOverride": true,
"noImplicitReturns": true,
"noFallthroughCasesInSwitch": true,
"noPropertyAccessFromIndexSignature": true
},
"files": [],
"include": [],
"references": [
{
"path": "./tsconfig.lib.json"
}
]
}

View File

@@ -0,0 +1,9 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"outDir": "../../../../dist/out-tsc",
"declaration": true,
"types": ["node"]
},
"include": ["src/**/*.ts"]
}