From c47abfe4b784aba8596e50634d87c11e98e5d804 Mon Sep 17 00:00:00 2001 From: gmorks Date: Mon, 27 Jan 2025 22:48:13 -0600 Subject: [PATCH] Added Preview image to the README.md file --- README.md | 66 ++++++++++++++++++++++++++++++++++--------------------- 1 file changed, 41 insertions(+), 25 deletions(-) diff --git a/README.md b/README.md index 7d0e2c6..46aaf35 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,9 @@ ComfyUI-SendToDiscord is a custom node for [ComfyUI](https://github.com/comfyanonymous/ComfyUI) that simplifies sending preview images to Discord via webhooks. It supports both single-image uploads and batch mode, making it an efficient tool for sharing your generated images directly with your Discord server. +![Node Preview](examples/workflow.png "Node Example") +- Workflow included in the image + ## Features - Send individual or batches of images directly to a Discord channel via webhooks. - Includes metadata (e.g., prompts and additional PNG information) in saved images. @@ -13,39 +16,52 @@ ComfyUI-SendToDiscord is a custom node for [ComfyUI](https://github.com/comfyano - `Pillow`, `requests`, and `numpy` libraries (automatically installed via `requirements.txt`). ## Installation + 1. Clone the repository into your ComfyUI custom nodes directory: - ``` - git clone https://github.com/yourusername/ComfyUI-SendToDiscord.git - ``` + ```bash + git clone https://github.com/yourusername/ComfyUI-SendToDiscord.git + ``` 2. Install dependencies: -``` -pip install -r requirements.txt -``` -3. Add your Discord webhook URL to the config.ini file located in the root directory: -``` -[Discord] -webhook_url = https://discord.com/api/webhooks/your-webhook-id -``` -Usage + ```bash + pip install -r requirements.txt + ``` +3. Add your Discord webhook URL to the `config.ini` file located in the root directory: + ```ini + # Configuration file for ComfyUI-SendToDiscord + # Replace 'your-webhook-url-here' with your Discord webhook URL. + [Discord] + webhook_url = https://discord.com/api/webhooks/your-webhook-id + ``` +### Dependencies +This node has been tested with the following Python packages: - Open ComfyUI. - Add the "Preview Image (with Discord option)" node to your workflow. - Configure the node parameters: - Send to Discord: Enable or disable image uploads to Discord. - Batch Mode: Enable to accumulate images and send them in a single batch. - Generate your images, and they will be uploaded automatically to the specified Discord channel. +- `Pillow>=9.5.0` +- `requests>=2.28.2` +- `numpy>=1.23.5` -Configuration +If you encounter issues, please ensure these versions or higher are installed, or consult the official ComfyUI documentation for compatible dependencies. + +## Usage + +1. Open ComfyUI. +2. Add the "Preview Image (with Discord option)" node to your workflow. +3. Configure the node parameters: + - **Send to Discord**: Enable or disable image uploads to Discord. + - **Batch Mode**: Enable to accumulate images and send them in a single batch. +4. Generate your images, and they will be uploaded automatically to the specified Discord channel. + +## Configuration The node uses the following parameters: - images: The list of images to process. - send_to_discord: Enable or disable sending images to Discord (enable/disable). - batch_mode: Accumulate images and send them as a batch (enable/disable). +- **images**: The list of images to process. +- **send_to_discord**: Enable or disable sending images to Discord (enable/disable). +- **batch_mode**: Accumulate images and send them as a batch (enable/disable). -Example Workflow +## Example Workflow You can add this node after your image generation process to preview and share your results directly. -License -This project is licensed under the MIT License. \ No newline at end of file +## License + +This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.