Add Activepieces integration for workflow automation
- Add Activepieces fork with SmoothSchedule custom piece - Create integrations app with Activepieces service layer - Add embed token endpoint for iframe integration - Create Automations page with embedded workflow builder - Add sidebar visibility fix for embed mode - Add list inactive customers endpoint to Public API - Include SmoothSchedule triggers: event created/updated/cancelled - Include SmoothSchedule actions: create/update/cancel events, list resources/services/customers 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
{
|
||||
"extends": [
|
||||
"../../../../.eslintrc.json"
|
||||
],
|
||||
"ignorePatterns": [
|
||||
"!**/*"
|
||||
],
|
||||
"overrides": [
|
||||
{
|
||||
"files": [
|
||||
"*.ts",
|
||||
"*.tsx",
|
||||
"*.js",
|
||||
"*.jsx"
|
||||
],
|
||||
"rules": {}
|
||||
},
|
||||
{
|
||||
"files": [
|
||||
"*.ts",
|
||||
"*.tsx"
|
||||
],
|
||||
"rules": {}
|
||||
},
|
||||
{
|
||||
"files": [
|
||||
"*.js",
|
||||
"*.jsx"
|
||||
],
|
||||
"rules": {}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
# pieces-whatsable
|
||||
|
||||
This library was generated with [Nx](https://nx.dev).
|
||||
|
||||
## Building
|
||||
|
||||
Run `nx build pieces-whatsable` to build the library.
|
||||
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"name": "@activepieces/piece-whatsable",
|
||||
"version": "0.0.9"
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
{
|
||||
"name": "pieces-whatsable",
|
||||
"$schema": "../../../../node_modules/nx/schemas/project-schema.json",
|
||||
"sourceRoot": "packages/pieces/community/whatsable/src",
|
||||
"projectType": "library",
|
||||
"targets": {
|
||||
"build": {
|
||||
"executor": "@nx/js:tsc",
|
||||
"outputs": [
|
||||
"{options.outputPath}"
|
||||
],
|
||||
"options": {
|
||||
"outputPath": "dist/packages/pieces/community/whatsable",
|
||||
"tsConfig": "packages/pieces/community/whatsable/tsconfig.lib.json",
|
||||
"packageJson": "packages/pieces/community/whatsable/package.json",
|
||||
"main": "packages/pieces/community/whatsable/src/index.ts",
|
||||
"assets": [
|
||||
"packages/pieces/community/whatsable/*.md",
|
||||
{
|
||||
"input": "packages/pieces/community/whatsable/src/i18n",
|
||||
"output": "./src/i18n",
|
||||
"glob": "**/!(i18n.json)"
|
||||
}
|
||||
],
|
||||
"buildableProjectDepsInPackageJsonType": "dependencies",
|
||||
"updateBuildableProjectDepsInPackageJson": true
|
||||
},
|
||||
"dependsOn": [
|
||||
"^build",
|
||||
"prebuild"
|
||||
]
|
||||
},
|
||||
"publish": {
|
||||
"command": "node tools/scripts/publish.mjs pieces-whatsable {args.ver} {args.tag}",
|
||||
"dependsOn": [
|
||||
"build"
|
||||
]
|
||||
},
|
||||
"lint": {
|
||||
"executor": "@nx/eslint:lint",
|
||||
"outputs": [
|
||||
"{options.outputFile}"
|
||||
]
|
||||
},
|
||||
"prebuild": {
|
||||
"executor": "nx:run-commands",
|
||||
"options": {
|
||||
"cwd": "packages/pieces/community/whatsable",
|
||||
"command": "bun install --no-save --silent"
|
||||
},
|
||||
"dependsOn": [
|
||||
"^build"
|
||||
]
|
||||
}
|
||||
},
|
||||
"tags": []
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Manage your WhatsApp business account": "Verwalten Sie Ihr WhatsApp Business-Konto",
|
||||
"The auth token for Whatsable": "Das Auth-Token für Was ist möglich",
|
||||
"Send Message": "Nachricht senden",
|
||||
"To": "An",
|
||||
"Message": "Nachricht",
|
||||
"The recipient of the message": "Der Empfänger der Nachricht",
|
||||
"The message to send": "Die Nachricht zum Senden"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Manage your WhatsApp business account": "Administra tu cuenta de negocios de WhatsApp",
|
||||
"The auth token for Whatsable": "El token de autenticación para Whatsable",
|
||||
"Send Message": "Enviar mensaje",
|
||||
"To": "A",
|
||||
"Message": "Mensaje",
|
||||
"The recipient of the message": "El destinatario del mensaje",
|
||||
"The message to send": "El mensaje a enviar"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Manage your WhatsApp business account": "Gérez votre compte WhatsApp Business",
|
||||
"The auth token for Whatsable": "Le jeton d'authentification pour Whatsable",
|
||||
"Send Message": "Envoyer un message",
|
||||
"To": "À",
|
||||
"Message": "Message",
|
||||
"The recipient of the message": "Destinataire du message",
|
||||
"The message to send": "Le message à envoyer"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Manage your WhatsApp business account": "WhatsAppビジネスアカウントの管理",
|
||||
"The auth token for Whatsable": "Whatsableの認証トークン",
|
||||
"Send Message": "メッセージを送信",
|
||||
"To": "終了日",
|
||||
"Message": "メッセージ",
|
||||
"The recipient of the message": "メッセージの受信者",
|
||||
"The message to send": "送信するメッセージ"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Manage your WhatsApp business account": "Beheer je WhatsApp business account",
|
||||
"The auth token for Whatsable": "De authenticatietoken voor Whatsable",
|
||||
"Send Message": "Verstuur bericht",
|
||||
"To": "tot",
|
||||
"Message": "bericht",
|
||||
"The recipient of the message": "De ontvanger van het bericht",
|
||||
"The message to send": "Het te verzenden bericht"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Manage your WhatsApp business account": "Gerencie sua conta empresarial do WhatsApp",
|
||||
"The auth token for Whatsable": "O token de autenticação para Whatsable",
|
||||
"Send Message": "Enviar mensagem",
|
||||
"To": "Para",
|
||||
"Message": "mensagem",
|
||||
"The recipient of the message": "O destinatário da mensagem",
|
||||
"The message to send": "A mensagem a enviar"
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"Whatsable": "Касательно",
|
||||
"Manage your WhatsApp business account": "Управление вашим бизнес-аккаунтом WhatsApp",
|
||||
"The auth token for Whatsable": "Маркер авторизации для Whatsable",
|
||||
"Send Message": "Отправить сообщение",
|
||||
"To": "Кому",
|
||||
"Message": "Сообщение",
|
||||
"The recipient of the message": "Получатель сообщения",
|
||||
"The message to send": "Сообщение для отправки"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Manage your WhatsApp business account": "Manage your WhatsApp business account",
|
||||
"The auth token for Whatsable": "The auth token for Whatsable",
|
||||
"Send Message": "Send Message",
|
||||
"To": "To",
|
||||
"Message": "Message",
|
||||
"The recipient of the message": "The recipient of the message",
|
||||
"The message to send": "The message to send"
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"Whatsable": "Whatsable",
|
||||
"Manage your WhatsApp business account": "Manage your WhatsApp business account",
|
||||
"The auth token for Whatsable": "The auth token for Whatsable",
|
||||
"Send Message": "Send Message",
|
||||
"To": "To",
|
||||
"Message": "Message",
|
||||
"The recipient of the message": "The recipient of the message",
|
||||
"The message to send": "The message to send"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Manage your WhatsApp business account": "Manage your WhatsApp business account",
|
||||
"The auth token for Whatsable": "The auth token for Whatsable",
|
||||
"Send Message": "Send Message",
|
||||
"To": "To",
|
||||
"Message": "Message",
|
||||
"The recipient of the message": "The recipient of the message",
|
||||
"The message to send": "The message to send"
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
import { createPiece, PieceAuth } from '@activepieces/pieces-framework';
|
||||
import { sendMessage } from './lib/actions/send-message';
|
||||
|
||||
export const whatsableAuth = PieceAuth.SecretText({
|
||||
displayName: 'Whatsable Auth Token',
|
||||
description: 'The auth token for Whatsable',
|
||||
required: true,
|
||||
});
|
||||
|
||||
export const whatsable = createPiece({
|
||||
displayName: 'Whatsable',
|
||||
description: 'Manage your WhatsApp business account',
|
||||
auth: whatsableAuth,
|
||||
minimumSupportedRelease: '0.30.0',
|
||||
logoUrl: 'https://cdn.activepieces.com/pieces/whatsable.png',
|
||||
authors: ["abuaboud"],
|
||||
actions: [sendMessage],
|
||||
triggers: [],
|
||||
});
|
||||
@@ -0,0 +1,38 @@
|
||||
import { createAction, Property } from '@activepieces/pieces-framework';
|
||||
import {
|
||||
httpClient, HttpMethod,
|
||||
} from '@activepieces/pieces-common';
|
||||
import { whatsableAuth } from '../..';
|
||||
|
||||
export const sendMessage = createAction({
|
||||
name: 'sendMessage',
|
||||
displayName: 'Send Message',
|
||||
description: '',
|
||||
auth: whatsableAuth,
|
||||
props: {
|
||||
to: Property.ShortText({
|
||||
displayName: 'To',
|
||||
description: 'The recipient of the message',
|
||||
required: true,
|
||||
}),
|
||||
text: Property.LongText({
|
||||
displayName: 'Message',
|
||||
description: 'The message to send',
|
||||
required: true,
|
||||
}),
|
||||
},
|
||||
async run(ctx) {
|
||||
const { to, text } = ctx.propsValue;
|
||||
return await httpClient.sendRequest({
|
||||
method: HttpMethod.POST,
|
||||
url: 'https://dashboard.whatsable.app/api/whatsapp/messages/send',
|
||||
headers: {
|
||||
'Authorization': ctx.auth.secret_text,
|
||||
},
|
||||
body: {
|
||||
to,
|
||||
text,
|
||||
},
|
||||
});
|
||||
},
|
||||
});
|
||||
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"extends": "../../../../tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"forceConsistentCasingInFileNames": true,
|
||||
"strict": true,
|
||||
"noImplicitOverride": true,
|
||||
"noPropertyAccessFromIndexSignature": true,
|
||||
"noImplicitReturns": true,
|
||||
"noFallthroughCasesInSwitch": true
|
||||
},
|
||||
"files": [],
|
||||
"include": [],
|
||||
"references": [
|
||||
{
|
||||
"path": "./tsconfig.lib.json"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"extends": "./tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"outDir": "../../../../dist/out-tsc",
|
||||
"declaration": true,
|
||||
"types": ["node"]
|
||||
},
|
||||
"exclude": ["jest.config.ts", "src/**/*.spec.ts", "src/**/*.test.ts"],
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
Reference in New Issue
Block a user