# URL and Email Token Detector AI Agent Connect

> Detect URLs and emails to calculate potential LLM token savings.

## Overview
- **Category:** utilities
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_tMjTV96dsKYy9CRpNT2FSKCn7KeN1MoHYCwRwxu5/ai-agent-connect
- **Tags:** tokens, url, email, optimization, llm

## Description

This MCP server provides deterministic analysis of text to identify URLs and email addresses. It calculates the potential reduction in LLM token usage by replacing high-entropy strings with fixed-length placeholders. Use `analyze_text_tokens` to find the exact number of URLs and emails and the total tokens saved through optimization.

## Tools

### analyze_text_tokens


### get_token_summary_template
Provides a template for reporting results

## Prompt Examples

**Prompt:** 
```
Analyze this text for token optimization: Check my site https://example.com and email me at test@domain.com
```

**Response:** 
```
url_count: 1, email_count: 1, total_url_tokens: 11, total_email_tokens: 5, tokens_saved: 14, optimization_possible: true
```

**Prompt:** 
```
How many tokens can I save in this text: contact@service.org
```

**Response:** 
```
url_count: 0, email_count: 1, total_url_tokens: 0, total_email_tokens: 4, tokens_saved: 2, optimization_possible: true
```

**Prompt:** 
```
Is there any optimization possible in: No URLs or emails here.
```

**Response:** 
```
url_count: 0, email_count: 0, total_url_tokens: 0, total_email_tokens: 0, tokens_saved: 0, optimization_possible: false
```

## Frequently Asked Questions

**How does this tool calculate token savings?**
It estimates the original token count by dividing the character length of detected URLs and emails by 4, then compares this to a fixed cost of 2 tokens per placeholder.

**What tools are available in this server?**
The server provides `analyze_text_tokens` for calculating savings and `get_token_summary_template` for generating formatted reports.

**Can I use this with Claude Desktop?**
Yes, this server can be connected to Claude Desktop, Cursor, VS Code, Windsurf, and any other MCP-compatible client via Vinkius Edge.
