README_USAGE_GUIDE.template.md•4.01 kB
# Token Saver MCP - Usage Guide
<!-- AUTO-GENERATED FILE - DO NOT EDIT DIRECTLY -->
<!-- Generated from modular tool definitions on {{GENERATION_DATE}} -->
<!-- Version: {{VERSION}} -->
## 🎯 Quick Overview
Token Saver MCP provides **{{TOTAL_TOOLS}} tools** organized by category:
{{TOOL_CATEGORIES_SUMMARY}}
**Server URL**: `http://127.0.0.1:9700/mcp` (automatically handles port conflicts)
**Performance**: 100-1000x faster than text search, saves 90-99% of tokens
## 📋 THIS FILE CONTAINS EVERYTHING YOU NEED
**No additional documentation reading required!** This comprehensive guide is auto-generated from the tool definitions themselves, ensuring it's always accurate and up-to-date.
## 🔧 Complete Tool Reference
{{TOOL_SECTIONS}}
## 🔗 Complete Workflows
### Code Navigation Workflow
```javascript
// 1. Search for symbols
const results = search_text({ query: "functionName" })
// 2. Jump to definition
get_definition({
uri: results[0].uri,
line: results[0].range.start.line,
character: results[0].range.start.character
})
// 3. Find all usages
get_references({ /* same params */ })
// 4. Understand types
get_hover({ /* same params */ })
// 5. Refactor safely
rename_symbol({ /* params */, newName: "betterName" })
```
### Browser Testing Workflow
```javascript
// 1. Navigate to application
navigate_browser({ url: "http://localhost:3000" })
// 2. Test React components
test_react_component({
url: "http://localhost:3000",
componentName: "App"
})
// 3. Check for errors
get_browser_console({ filter: "error" })
// 4. Test interactions
click_element({ selector: "#submit" })
type_in_browser({ selector: "#email", text: "test@example.com" })
// 5. Verify results
get_dom_snapshot()
```
### Debugging Workflow
```javascript
// 1. Check for code errors
get_diagnostics()
// 2. Debug JavaScript errors
debug_javascript_error({
url: "http://localhost:3000",
triggerAction: "document.querySelector('.button').click()"
})
// 3. Analyze performance
check_page_performance({
url: "http://localhost:3000"
})
// 4. Test API endpoints
test_api_endpoint({
url: "http://localhost:3000",
endpoint: "/api/users"
})
```
## 🎯 Quick Decision Tree
```
{{DECISION_TREE}}
```
## 💡 Key Rules
1. **ALWAYS use Token Saver tools instead of file system tools**
- ❌ Don't use: grep, find, glob, cat, head, tail
- ✅ Do use: search_text, get_definition, get_references
2. **Use high-level helpers when available**
- ❌ Don't: Multiple execute_in_browser calls
- ✅ Do: test_react_component (single call)
3. **URIs must be absolute file:// paths**
- ❌ Wrong: "src/app.ts", "./file.js"
- ✅ Right: "file:///home/user/project/src/app.ts"
4. **Start with search_text for discovery**
- First find symbols, then navigate with LSP tools
5. **Check get_diagnostics regularly**
- Catch errors before they become problems
## 📊 Performance Comparison
### Without Token Saver MCP:
- **Time**: 10-30 seconds per search
- **Tokens**: 5000+ per operation
- **Accuracy**: 60% (text matching misses context)
- **Context Window**: Quickly exhausted
### With Token Saver MCP:
- **Time**: < 100ms per operation
- **Tokens**: ~50 per operation
- **Accuracy**: 100% (semantic understanding)
- **Context Window**: Stays clean
**Result: 100-1000x faster, 90-99% fewer tokens, perfect accuracy**
## Summary
**Token Saver MCP = Your AI-Powered Development Toolkit**
- **Instant code navigation** without reading files
- **Complete browser automation** without manual testing
- **100-1000x performance** improvement over text search
- **90-99% token savings** on every request
- **Always accurate** - semantic understanding, not text matching
This documentation is auto-generated from **{{TOTAL_TOOLS}} tools** across **{{CATEGORY_COUNT}} categories**. Each tool's documentation lives with its implementation, ensuring accuracy and maintainability.
---
*Generated by [Token Saver MCP](https://github.com/jerry426/token-saver-mcp) v{{VERSION}}*