Overview
This n8n workflow is designed to extract specific interests from messages in a Telegram chat and retrieve related information using the Facebook Graph API. It aims to provide a streamlined solution for parsing and analyzing user-provided interests within the Telegram platform.
Features
- Interest Extraction: Automatically identifies and extracts interests from messages that start with the hashtag "#interest".
- Data Retrieval: Utilizes the Facebook Graph API to retrieve information related to the extracted interests.
- Structured Outputs: Presents the retrieved data in an organized format for further analysis and review.
Requirements
- Operational instance of n8n (self-hosted or cloud version).
- Basic understanding of n8n workflows and nodes.
Setup and Configuration
- Import Workflow: Load the provided JSON workflow into your n8n instance.
- Configure Telegram Trigger Node: Ensure the Telegram trigger node is set up with the appropriate credentials and webhook ID.
- Configure and Test Nodes: Adjust node parameters as necessary and test the workflow to ensure proper functionality.
How it Works
- Telegram Trigger: Listens for incoming messages in a specified Telegram chat.
- Check Message Contents: Verifies if the message begins with the specified hashtag and is from the designated chat ID.
- Extract Message: Extracts the content of the message for further processing.
- Split Message: Splits the extracted message to identify the interest and remaining content.
- Connect to Graph API: Utilizes the Facebook Graph API to search for information related to the extracted interest.
- Split Interests into a Table: Organizes the retrieved data into a structured table format.
- Get Variables: Maps the retrieved data to create a new JSON object containing specific fields related to the interest.
- Create a Spreadsheet: Generates a spreadsheet file in CSV format based on the retrieved and formatted data.
- Send the Spreadsheet File: Sends the generated spreadsheet file back to the original Telegram chat.
Customization
- Modify the filtering conditions and fields to suit specific requirements.
- Adjust the frequency of the trigger node based on preference.
Best Practices
- Regularly test the workflow to ensure consistent performance.
- Stay informed about any changes to external APIs that might affect the workflow's functionality.
Contributing
Your feedback and contributions are highly valued. Feel free to adapt, modify, and share enhancements with the n8n community.