|
| 1 | +# 📦 n8n-nodes-signal-cli |
| 2 | + |
| 3 | +This repository contains n8n nodes for interacting with Signal CLI. It includes a trigger node for receiving messages and an action node for various Signal operations. |
| 4 | + |
| 5 | +## 📚 Table of Contents |
| 6 | +1. [📋 Prerequisites](#-prerequisites) |
| 7 | +2. [🚀 Usage](#-usage) |
| 8 | +3. [📥 Installation](#-installation) |
| 9 | +4. [🤖 Nodes](#-nodes) |
| 10 | +5. [💻 Development](#-development) |
| 11 | +6. [🚀 Release](#-release) |
| 12 | +7. [🤝 Contributing](#-contributing) |
| 13 | +8. [⚠️ Known Limitations](#-known-limitations) |
| 14 | +9. [📄 License](#-license) |
| 15 | + |
| 16 | +## 📋 Prerequisites |
| 17 | + |
| 18 | +* Node.js (>=18.10) and pnpm (>=9.1) |
| 19 | +* n8n installed globally using `pnpm install n8n -g` |
| 20 | +* Signal CLI set up and running in daemon mode with HTTP JSON-RPC endpoint exposed (`--http`) |
| 21 | + |
| 22 | + |
| 23 | +## 📥 Installation |
| 24 | + |
| 25 | +1. Clone this repository. |
| 26 | +2. Run `pnpm install` to install dependencies. |
| 27 | +3. Run `pnpm build` to build the nodes. |
| 28 | +4. Copy the `dist` folder and `package.json` to your n8n custom nodes directory (usually `~/.n8n/custom/nodes/n8n-nodes-signal-cli`). |
| 29 | + |
| 30 | +## 🤖 Nodes |
| 31 | + |
| 32 | +### 🔔 SignalTrigger |
| 33 | + |
| 34 | +* Triggers when a new message is received via Signal CLI. |
| 35 | +* Requires Signal CLI API credential. |
| 36 | +* Parameters: |
| 37 | + * `account`: Signal account to listen for incoming messages. |
| 38 | + |
| 39 | +### 📱 Signal |
| 40 | + |
| 41 | +* Interact with Signal CLI API for various operations. |
| 42 | +* Requires Signal CLI API credential. |
| 43 | +* Supports the following resources and operations: |
| 44 | + * **Message**: |
| 45 | + * Send: Send a message to a recipient or group. |
| 46 | + * Parameters: `account`, `recipient`, `message` |
| 47 | + * **Group**: |
| 48 | + * Create: Create a new group. |
| 49 | + * Parameters: `account`, `name`, `members` |
| 50 | + * List: List all groups. |
| 51 | + * Parameters: `account` |
| 52 | + * **Contact**: |
| 53 | + * Update: Update a contact's name. |
| 54 | + * Parameters: `account`, `recipient`, `name` |
| 55 | + * List: List all contacts. |
| 56 | + * Parameters: `account` |
| 57 | + * **Reaction**: |
| 58 | + * Send: Send a reaction to a message. |
| 59 | + * Parameters: `account`, `recipient`, `reaction`, `targetAuthor`, `timestamp` |
| 60 | + * Remove: Remove a reaction from a message. |
| 61 | + * Parameters: `account`, `recipient`, `reaction`, `targetAuthor`, `timestamp` |
| 62 | + * **Receipt**: |
| 63 | + * Send: Send a receipt (read or viewed) for a message. |
| 64 | + * Parameters: `account`, `recipient`, `receiptType`, `timestamp` |
| 65 | + |
| 66 | +## 💻 Development |
| 67 | + |
| 68 | +* Run `pnpm dev` to start the TypeScript compiler in watch mode. |
| 69 | +* Run `pnpm lint` to check for linting errors. |
| 70 | +* Run `pnpm test` to run integration tests. |
| 71 | + |
| 72 | +Before running the tests, set the `ENDPOINT` environment variable to the Signal CLI API URL (e.g., "http://127.0.0.1:8085"). |
| 73 | + |
| 74 | +For example, you can run the following command in your terminal: |
| 75 | + |
| 76 | +```bash |
| 77 | +export ENDPOINT="http://127.0.0.1:8085" # signal-cli endpoint |
| 78 | +export ACCOUNT_NUMBER="±33620382719" # your phone number in international format |
| 79 | +``` |
| 80 | + |
| 81 | + |
| 82 | +## 🚀 Release |
| 83 | + |
| 84 | +* Run `pnpm release` to release a new version of the package. |
| 85 | + |
| 86 | +## 🤝 Contributing |
| 87 | + |
| 88 | +Contributions are welcome! Please follow these steps to contribute: |
| 89 | +1. Fork this repository. |
| 90 | +2. Create a new branch for your feature or bug fix. |
| 91 | +3. Submit a pull request with a clear description of your changes. |
| 92 | +4. Ensure that your code adheres to the existing coding standards and passes all tests. |
| 93 | + |
| 94 | +## ⚠️ Known Limitations |
| 95 | + |
| 96 | +* This implementation relies on the Signal CLI API, which may have its own limitations and constraints. |
| 97 | +* Ensure that the Signal CLI is properly configured and running before using these nodes. |
| 98 | +* Some operations may require specific permissions or settings within Signal CLI. |
| 99 | + |
| 100 | +## 📄 License |
| 101 | + |
| 102 | +MIT |
0 commit comments