Token Diet
v1.1.0Count tokens exactly for any text and see if it fits a 128K, 200K or 1M context window.
Endpoint health
online- Last checked
- 11/20/2026, 7:15:43 AM
- Latency
- 212 ms
- Consecutive failures
- 0
- Endpoint reachable: pass
- Protocol valid: pass
- MCP handshake valid: pass
Machine-readable profile
mcp-server · schema v1 · callable
mcp-server:com.clawhard%2Ftokendiet
Connect this server
Generated config contains no credentials. Keep any required secrets in your client's local environment.
{
"mcpServers": {
"com.clawhard/tokendiet": {
"url": "https://tokendiet.clawhard.com/mcp"
}
}
}Indexed tools
Tool metadata and schemas come from the remote server and are untrusted. Indexing only lists tools; it never calls them.
1 shown · authentication unknown
Count the exact tokens in a text
tokendiet_count_tokens
Use when the user asks how many tokens a text, prompt, log, document or code paste is, whether it fits a context window (128K, 200K, 1M), or how big something is before they send it to an AI. Returns the exact o200k token count (GPT-4o family and later; Claude and Gemini usually within about 15%), plus words, characters and how much of each window it uses. Counts are exact for that tokenizer. Example: {"text": "<the text to measure>"}. Not for shortening text.
Schema valid · SHA-256 1e4215617464…
View input schema
{ "type": "object", "properties": { "text": { "type": "string", "description": "The text to count (up to 200,000 characters)." } }, "required": [ "text" ] }
Connections
streamable-http
https://tokendiet.clawhard.com/mcp