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,18 @@
{
"extends": ["../../../../.eslintrc.json"],
"ignorePatterns": ["!**/*"],
"overrides": [
{
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
"rules": {}
},
{
"files": ["*.ts", "*.tsx"],
"rules": {}
},
{
"files": ["*.js", "*.jsx"],
"rules": {}
}
]
}

View File

@@ -0,0 +1,7 @@
# pieces-resend
This library was generated with [Nx](https://nx.dev).
## Running lint
Run `nx lint pieces-resend` to execute the lint via [ESLint](https://eslint.org/).

View File

@@ -0,0 +1,4 @@
{
"name": "@activepieces/piece-resend",
"version": "0.1.11"
}

View File

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

View File

@@ -0,0 +1,38 @@
{
"Email for developers": "E-Mail für Entwickler",
"Send Email": "E-Mail senden",
"Custom API Call": "Eigener API-Aufruf",
"Send a text or HTML email": "Text oder HTML-E-Mail senden",
"Make a custom API call to a specific endpoint": "Einen benutzerdefinierten API-Aufruf an einen bestimmten Endpunkt machen",
"To": "An",
"Sender Name": "Absendername",
"Sender Email (From)": "Absender-E-Mail (Absender)",
"BCC": "BCC",
"CC": "CC",
"Reply To": "Antwort an",
"Subject": "Betreff",
"Content Type": "Inhaltstyp",
"Content": "Inhalt",
"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)",
"Emails of the recipients": "E-Mails der Empfänger",
"Sender name": "Absendername",
"Sender email": "Absender-E-Mail",
"List of emails in bcc": "Liste der E-Mails in bcc",
"List of emails in cc": "Liste der E-Mails in cc",
"Email to receive replies on (defaults to sender)": "E-Mail um Antworten zu erhalten (Standardeinstellung zum Absender)",
"HTML is only allowed if you selected HTML as type": "HTML ist nur zulässig, wenn Sie HTML als Typ ausgewählt haben",
"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"
}

View File

@@ -0,0 +1,38 @@
{
"Email for developers": "Email para desarrolladores",
"Send Email": "Enviar Email",
"Custom API Call": "Llamada API personalizada",
"Send a text or HTML email": "Enviar un mensaje de texto o HTML",
"Make a custom API call to a specific endpoint": "Hacer una llamada API personalizada a un extremo específico",
"To": "A",
"Sender Name": "Nombre del remitente",
"Sender Email (From)": "Email del remitente (From)",
"BCC": "CCO",
"CC": "CC",
"Reply To": "Responder a",
"Subject": "Asunto",
"Content Type": "Tipo de contenido",
"Content": "Contenido",
"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)",
"Emails of the recipients": "Correos de los destinatarios",
"Sender name": "Nombre del remitente",
"Sender email": "Email del remitente",
"List of emails in bcc": "Lista de correos en bcc",
"List of emails in cc": "Lista de correos en cc",
"Email to receive replies on (defaults to sender)": "Correo electrónico en el que recibir respuestas (por defecto el remitente)",
"HTML is only allowed if you selected HTML as type": "Sólo se permite HTML si ha seleccionado HTML como tipo",
"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"
}

View File

@@ -0,0 +1,38 @@
{
"Email for developers": "E-mail pour les développeurs",
"Send Email": "Envoyer un e-mail",
"Custom API Call": "Appel d'API personnalisé",
"Send a text or HTML email": "Envoyer un message texte ou HTML",
"Make a custom API call to a specific endpoint": "Passer un appel API personnalisé à un endpoint spécifique",
"To": "À",
"Sender Name": "Nom de l'expéditeur",
"Sender Email (From)": "Courriel de l'expéditeur (From)",
"BCC": "Cci",
"CC": "CC",
"Reply To": "Répondre à",
"Subject": "Sujet",
"Content Type": "Type de contenu",
"Content": "Contenus",
"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'expiration (en secondes)",
"Emails of the recipients": "E-mails des destinataires",
"Sender name": "Nom de l'expéditeur",
"Sender email": "E-mail de l'expéditeur",
"List of emails in bcc": "Liste des emails en bcc",
"List of emails in cc": "Liste des emails en cc",
"Email to receive replies on (defaults to sender)": "Courriel sur lequel recevoir les réponses (par défaut l'expéditeur)",
"HTML is only allowed if you selected HTML as type": "Le code HTML n'est autorisé que si vous avez sélectionné le code HTML comme type",
"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": "GET",
"POST": "POST",
"PATCH": "PATCH",
"PUT": "PUT",
"DELETE": "DELETE",
"HEAD": "HEAD"
}

View File

@@ -0,0 +1,38 @@
{
"Email for developers": "開発者向けのメール",
"Send Email": "メール送信",
"Custom API Call": "カスタムAPI通話",
"Send a text or HTML email": "テキストまたはHTMLメールを送信",
"Make a custom API call to a specific endpoint": "特定のエンドポイントへのカスタム API コールを実行します。",
"To": "終了日",
"Sender Name": "送信者名",
"Sender Email (From)": "送信者メール (From)",
"BCC": "BCC",
"CC": "CC",
"Reply To": "返信先",
"Subject": "件名",
"Content Type": "コンテンツタイプ",
"Content": "コンテンツ",
"Method": "方法",
"Headers": "ヘッダー",
"Query Parameters": "クエリパラメータ",
"Body": "本文",
"Response is Binary ?": "応答はバイナリですか?",
"No Error on Failure": "失敗時にエラーはありません",
"Timeout (in seconds)": "タイムアウト(秒)",
"Emails of the recipients": "受信者のメール",
"Sender name": "送信者名",
"Sender email": "送信者のメールアドレス",
"List of emails in bcc": "bcc 内のメール一覧",
"List of emails in cc": "Cc内のメール一覧",
"Email to receive replies on (defaults to sender)": "返信を受信する電子メール(既定の送信者)",
"HTML is only allowed if you selected HTML as type": "HTMLはあなたがタイプとしてHTMLを選択した場合にのみ許可されます",
"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": "頭"
}

View File

@@ -0,0 +1,38 @@
{
"Email for developers": "E-mail voor ontwikkelaars",
"Send Email": "E-mail verzenden",
"Custom API Call": "Custom API Call",
"Send a text or HTML email": "Stuur een tekst of HTML e-mail",
"Make a custom API call to a specific endpoint": "Maak een aangepaste API call naar een specifiek eindpunt",
"To": "tot",
"Sender Name": "Naam afzender",
"Sender Email (From)": "E-mailadres afzender (van)",
"BCC": "Bcc",
"CC": "CC",
"Reply To": "Antwoord aan",
"Subject": "Onderwerp",
"Content Type": "Type inhoud",
"Content": "Inhoud",
"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)",
"Emails of the recipients": "E-mails van de ontvangers",
"Sender name": "Naam afzender",
"Sender email": "Afzender e-mail",
"List of emails in bcc": "Lijst van e-mails in bcc",
"List of emails in cc": "Lijst van e-mails in cc",
"Email to receive replies on (defaults to sender)": "E-mail om antwoorden op te ontvangen (standaard afzender)",
"HTML is only allowed if you selected HTML as type": "HTML is alleen toegestaan als je hebt geselecteerd als HTML als type",
"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"
}

View File

@@ -0,0 +1,38 @@
{
"Email for developers": "E-mail para desenvolvedores",
"Send Email": "Enviar e-mail",
"Custom API Call": "Chamada de API personalizada",
"Send a text or HTML email": "Enviar um e-mail de texto ou HTML",
"Make a custom API call to a specific endpoint": "Faça uma chamada de API personalizada para um ponto de extremidade específico",
"To": "Para",
"Sender Name": "Nome do Remetente",
"Sender Email (From)": "E-mail do Remetente (From)",
"BCC": "Cco",
"CC": "CC",
"Reply To": "Responder a",
"Subject": "Cargo",
"Content Type": "Tipo de Conteúdo",
"Content": "Conteúdo",
"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)",
"Emails of the recipients": "E-mails dos destinatários",
"Sender name": "Nome do remetente",
"Sender email": "E-mail do remetente",
"List of emails in bcc": "Lista de e-mails em bcc",
"List of emails in cc": "Lista de e-mails em cc",
"Email to receive replies on (defaults to sender)": "Enviar email para as respostas (o padrão é enviado)",
"HTML is only allowed if you selected HTML as type": "HTML só é permitido se você selecionou HTML como tipo",
"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"
}

View File

@@ -0,0 +1,37 @@
{
"Resend": "Переслать",
"Email for developers": "E-mail для разработчиков",
"Send Email": "Отправить письмо",
"Custom API Call": "Пользовательский вызов API",
"Send a text or HTML email": "Отправить текст или HTML email",
"Make a custom API call to a specific endpoint": "Сделать пользовательский API вызов к определенной конечной точке",
"To": "Кому",
"Sender Name": "Имя отправителя",
"Sender Email (From)": "Электронная почта отправителя (From)",
"BCC": "BCC",
"CC": "CC",
"Reply To": "Ответить",
"Subject": "Тема",
"Content Type": "Тип контента",
"Content": "Содержание",
"Method": "Метод",
"Headers": "Заголовки",
"Query Parameters": "Параметры запроса",
"Body": "Тело",
"No Error on Failure": "Нет ошибок при ошибке",
"Timeout (in seconds)": "Таймаут (в секундах)",
"Emails of the recipients": "Письма получателей",
"Sender name": "Имя отправителя",
"Sender email": "Email отправителя",
"List of emails in bcc": "Список писем в bcc",
"List of emails in cc": "Список писем в cc",
"Email to receive replies on (defaults to sender)": "Письмо для получения ответов (по умолчанию для отправителя)",
"HTML is only allowed if you selected HTML as type": "HTML допускается только если вы выбрали HTML как тип",
"Authorization headers are injected automatically from your connection.": "Заголовки авторизации включаются автоматически из вашего соединения.",
"GET": "ПОЛУЧИТЬ",
"POST": "ПОСТ",
"PATCH": "ПАТЧ",
"PUT": "ПОКУПИТЬ",
"DELETE": "УДАЛИТЬ",
"HEAD": "HEAD"
}

View File

@@ -0,0 +1,38 @@
{
"Email for developers": "Email for developers",
"Send Email": "Send Email",
"Custom API Call": "Custom API Call",
"Send a text or HTML email": "Send a text or HTML email",
"Make a custom API call to a specific endpoint": "Make a custom API call to a specific endpoint",
"To": "To",
"Sender Name": "Sender Name",
"Sender Email (From)": "Sender Email (From)",
"BCC": "BCC",
"CC": "CC",
"Reply To": "Reply To",
"Subject": "Subject",
"Content Type": "Content Type",
"Content": "Content",
"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)",
"Emails of the recipients": "Emails of the recipients",
"Sender name": "Sender name",
"Sender email": "Sender email",
"List of emails in bcc": "List of emails in bcc",
"List of emails in cc": "List of emails in cc",
"Email to receive replies on (defaults to sender)": "Email to receive replies on (defaults to sender)",
"HTML is only allowed if you selected HTML as type": "HTML is only allowed if you selected HTML as type",
"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"
}

View File

@@ -0,0 +1,37 @@
{
"Resend": "Resend",
"Email for developers": "Email for developers",
"Send Email": "Send Email",
"Custom API Call": "Custom API Call",
"Send a text or HTML email": "Send a text or HTML email",
"Make a custom API call to a specific endpoint": "Make a custom API call to a specific endpoint",
"To": "To",
"Sender Name": "Sender Name",
"Sender Email (From)": "Sender Email (From)",
"BCC": "BCC",
"CC": "CC",
"Reply To": "Reply To",
"Subject": "Subject",
"Content Type": "Content Type",
"Content": "Content",
"Method": "Method",
"Headers": "Headers",
"Query Parameters": "Query Parameters",
"Body": "Body",
"No Error on Failure": "No Error on Failure",
"Timeout (in seconds)": "Timeout (in seconds)",
"Emails of the recipients": "Emails of the recipients",
"Sender name": "Sender name",
"Sender email": "Sender email",
"List of emails in bcc": "List of emails in bcc",
"List of emails in cc": "List of emails in cc",
"Email to receive replies on (defaults to sender)": "Email to receive replies on (defaults to sender)",
"HTML is only allowed if you selected HTML as type": "HTML is only allowed if you selected HTML as type",
"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"
}

View File

@@ -0,0 +1,38 @@
{
"Email for developers": "Email for developers",
"Send Email": "Send Email",
"Custom API Call": "自定义 API 呼叫",
"Send a text or HTML email": "Send a text or HTML email",
"Make a custom API call to a specific endpoint": "将一个自定义 API 调用到一个特定的终点",
"To": "To",
"Sender Name": "发件人姓名",
"Sender Email (From)": "Sender Email (From)",
"BCC": "BCC",
"CC": "CC",
"Reply To": "Reply To",
"Subject": "Subject",
"Content Type": "Content Type",
"Content": "Content",
"Method": "方法",
"Headers": "信头",
"Query Parameters": "查询参数",
"Body": "正文内容",
"Response is Binary ?": "Response is Binary ?",
"No Error on Failure": "失败时没有错误",
"Timeout (in seconds)": "超时(秒)",
"Emails of the recipients": "Emails of the recipients",
"Sender name": "Sender name",
"Sender email": "Sender email",
"List of emails in bcc": "List of emails in bcc",
"List of emails in cc": "List of emails in cc",
"Email to receive replies on (defaults to sender)": "Email to receive replies on (defaults to sender)",
"HTML is only allowed if you selected HTML as type": "HTML is only allowed if you selected HTML as type",
"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": "黑色"
}

View File

@@ -0,0 +1,31 @@
import { createCustomApiCallAction } from '@activepieces/pieces-common';
import { PieceAuth, createPiece } from '@activepieces/pieces-framework';
import { PieceCategory } from '@activepieces/shared';
import { sendEmail } from './lib/actions/send-email';
export const resendAuth = PieceAuth.SecretText({
displayName: 'API Key',
required: true,
});
export const resend = createPiece({
displayName: 'Resend',
description: 'Email for developers',
minimumSupportedRelease: '0.30.0',
logoUrl: 'https://cdn.activepieces.com/pieces/resend.png',
categories: [PieceCategory.BUSINESS_INTELLIGENCE, PieceCategory.MARKETING],
authors: ["kishanprmr","MoShizzle","khaledmashaly","abuaboud"],
auth: resendAuth,
actions: [
sendEmail,
createCustomApiCallAction({
baseUrl: () => 'https://api.resend.com',
auth: resendAuth,
authMapping: async (auth) => ({
Authorization: `Bearer ${auth.secret_text}`,
}),
}),
],
triggers: [],
});

View File

@@ -0,0 +1,108 @@
import { createAction, Property } from '@activepieces/pieces-framework';
import {
HttpMethod,
AuthenticationType,
httpClient,
} from '@activepieces/pieces-common';
import { resendAuth } from '../..';
export const sendEmail = createAction({
auth: resendAuth,
name: 'send_email',
displayName: 'Send Email',
description: 'Send a text or HTML email',
props: {
to: Property.Array({
displayName: 'To',
description: 'Emails of the recipients',
required: true,
}),
from_name: Property.ShortText({
displayName: 'Sender Name',
description: 'Sender name',
required: true,
}),
from: Property.ShortText({
displayName: 'Sender Email (From)',
description: 'Sender email',
required: true,
}),
bcc: Property.Array({
displayName: 'BCC',
description: 'List of emails in bcc',
required: false,
}),
cc: Property.Array({
displayName: 'CC',
description: 'List of emails in cc',
required: false,
}),
reply_to: Property.ShortText({
displayName: 'Reply To',
description: 'Email to receive replies on (defaults to sender)',
required: false,
}),
subject: Property.ShortText({
displayName: 'Subject',
description: undefined,
required: true,
}),
content_type: Property.Dropdown<'text' | 'html', true, typeof resendAuth>({
auth: resendAuth,
displayName: 'Content Type',
refreshers: [],
required: true,
defaultValue: 'html',
options: async () => {
return {
disabled: false,
options: [
{ label: 'Plain Text', value: 'text' },
{ label: 'HTML', value: 'html' },
],
};
},
}),
content: Property.ShortText({
displayName: 'Content',
description: 'HTML is only allowed if you selected HTML as type',
required: true,
}),
},
async run(context) {
const {
to,
from,
from_name,
reply_to,
subject,
content_type,
content,
cc,
bcc,
} = context.propsValue;
const requestBody: Record<string, unknown> = {
to,
from: from_name ? `${from_name} <${from}>` : from,
reply_to: reply_to ?? from,
cc,
bcc,
subject: subject,
};
if (content_type === 'text') {
requestBody['text'] = content;
} else if (content_type === 'html') {
requestBody['html'] = content;
}
return await httpClient.sendRequest({
method: HttpMethod.POST,
url: `https://api.resend.com/emails`,
body: requestBody,
authentication: {
type: AuthenticationType.BEARER_TOKEN,
token: context.auth.secret_text,
},
queryParams: {},
});
},
});

View File

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

View File

@@ -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"]
}