AI token tracker for WhatsApp Telegram Save AI usage to G
๐ธ GPT-4o Token Tracker โ Measure AI Usage and Cost via WhatsApp or Telegram Hi! I'm Amanda โ I create smart, useful AI automations for n8n and Make. This wo...
๐ Nodes & Integrations Used (11)
๐ Implementation & Setup Guide
๐ธ GPT-4o Token Tracker โ Measure AI Usage and Cost via WhatsApp or Telegram
Hi! I'm Amanda โ I create smart, useful AI automations for n8n and Make. This workflow helps you monitor how many tokens are consumed per conversation with AI Agent Tokens, and logs that usage into **Google Sheets** โ so you can track expenses and make smarter decisions about your AI usage.
You can connect it to **Telegram** or **WhatsApp (via Evolution API)**, and it will automatically capture: - Prompt and completion tokens - Total tokens - Time of interaction - The user/channel - (Optional) Cost estimate in USD
---
๐ What this workflow does
- Logs token usage from LangChain agents
- Calculates token totals for each request
- Appends the data to a structured Google Sheet
- Works with **WhatsApp (Evolution API)** or **Telegram bots**
- Ideal for tracking AI Agent Tokens usage over time and controlling costs
---
๐งช Free Spreadsheet Template
You can duplicate and use this template for logging token usage:
Includes columns like: - Date - Input - Output - Tokens (Prompt / Completion / Total) - Tool name or use case - Estimated cost
---
๐ ๏ธ Setup Instructions
- Import the workflow to your n8n (Cloud or self-hosted)
- Connect your Google Sheets account
- Choose your trigger:
- - WhatsApp (Evolution API webhook)
- - Telegram (Bot webhook or message input)
- Fill out:
- - AI Agent model used (e.g. `gpt-4o`)
- - Cost per 1K tokens (optional, for USD estimation)
- Update spreadsheet ID and tab name in the Google Sheets node
- (Optional) Connect as a sub-tool to an AI agent for automatic logging
---
๐งฐ Tech Used
- OpenRouter
- LangChain
- Google Sheets
- Telegram or WhatsApp webhook (Evolution API)
- Nodes: HTTP Request, Set, If, Google Sheets, Merge
---
โ Who This Is For
- Developers or agencies that want to monitor AI Agent Tokens usage
- Freelancers managing AI bots for clients
- Teams that need billing visibility and cost control
- Anyone who wants transparency in AI token spending
---
โ Requirements
- OpenAI GPT-4o access
- Google Sheets credential
- Telegram Bot Token (or Evolution API access for WhatsApp)
- n8n (Cloud or self-hosted)
---
๐ Want this template?
โค๏ธ Buy more workflows at: [https://iloveflows.com](https://iloveflows.com) โ๏ธ Try n8n Cloud: [https://n8n.partnerlinks.io/amanda](https://n8n.partnerlinks.io/amanda)
โก How to import this workflow into n8n:
- Click the Direct Download JSON button above to save
_AI_token_tracker_for_WhatsApp_Telegram_Save_AI_usage_to_G.json. - Log in to your n8n Cloud or self-hosted n8n instance.
- In your workflow canvas, click the menu in top-right and select Import from File (or paste the JSON directly).
- Configure your credentials (e.g. API keys, database URLs) in the corresponding node settings.
- Click Execute Workflow to test and switch to Active!
Related AI Agents Workflows
View All in AI Agents โ5 ways to process images PDFs with Gemini AI in n8n
How it works Many users have asked in the support forum about different methods to analyze images and PDF documents with Google Gemini AI in n8n. This workfl...
7 AI Sales Assistant
Production-ready n8n automation template for 7 AI Sales Assistant built by AhiXLight. Seamlessly connects Airtop Tool, Slack, Airtop with 24 configured nodes.
AAVE portfolio professional AI agent Telegram Email GPT 4o
A next-generation AI-powered DeFi health monitor that tracks wallet positions across Aave V3 using GPT-4o and LangChain. It delivers human-readable reports v...
Access control for AI agents RBAC using Airtable and Telegram
Purpose This workflow allows granular control over the access to tools connected to AI Agents (including Multi-Agent setups) using Role Based Access Control....