@youdotcom-oss/mcp 1.3.5-next.5 → 1.3.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CONTRIBUTING.md DELETED
@@ -1,246 +0,0 @@
1
- # Contributing to You.com MCP Server
2
-
3
- Thank you for your interest in contributing! This guide will help you get started.
4
-
5
- ## Table of Contents
6
-
7
- - [Code of Conduct](#code-of-conduct)
8
- - [Getting Started](#getting-started)
9
- - [How to Contribute](#how-to-contribute)
10
- - [Development Workflow](#development-workflow)
11
- - [Getting Help](#getting-help)
12
-
13
- ## Code of Conduct
14
-
15
- This project adheres to professional open-source standards. Be respectful, constructive, and collaborative in all interactions.
16
-
17
- ## Getting Started
18
-
19
- ### Prerequisites
20
-
21
- - Bun >= 1.2.21
22
- - You.com API key from [api.you.com](https://api.you.com)
23
-
24
- ### Quick Setup
25
-
26
- ```bash
27
- git clone https://github.com/youdotcom-oss/youdotcom-mcp-server.git
28
- cd youdotcom-mcp-server
29
- bun install
30
- echo "export YDC_API_KEY=your-key" > .env
31
- source .env
32
- bun run dev
33
- ```
34
-
35
- For detailed development setup, code patterns, and architecture, see [AGENTS.md](./AGENTS.md).
36
-
37
- ## How to Contribute
38
-
39
- ### Reporting Bugs
40
-
41
- **Before submitting**: Check [existing issues](https://github.com/youdotcom-oss/youdotcom-mcp-server/issues)
42
-
43
- **When reporting**, include:
44
-
45
- - Clear description of the bug
46
- - Steps to reproduce
47
- - Expected vs actual behavior
48
- - Environment details (Bun version, OS, MCP client)
49
- - Error logs from your MCP client
50
-
51
- **Where to report**:
52
-
53
- - GitHub Issues: https://github.com/youdotcom-oss/youdotcom-mcp-server/issues
54
- - Email: support@you.com (for security issues)
55
-
56
- ### Suggesting Enhancements
57
-
58
- We welcome feature requests! Please:
59
-
60
- 1. Check if the feature already exists or is planned
61
- 2. Open an issue describing the enhancement
62
- 3. Explain the use case and benefits
63
- 4. Be open to discussion and iteration
64
-
65
- ### Submitting Pull Requests
66
-
67
- #### 1. Fork and Create Branch
68
-
69
- ```bash
70
- # Fork the repo on GitHub, then:
71
- git clone https://github.com/YOUR-USERNAME/youdotcom-mcp-server.git
72
- cd youdotcom-mcp-server
73
- git checkout -b feature/your-feature-name
74
- ```
75
-
76
- **Branch naming**:
77
-
78
- - `feature/description` - New features
79
- - `fix/description` - Bug fixes
80
- - `docs/description` - Documentation
81
- - `dx-<issue-num>-description` - DX improvements
82
-
83
- #### 2. Make Your Changes
84
-
85
- **Code Style**:
86
-
87
- - Follow patterns in [AGENTS.md](./AGENTS.md)
88
- - Use arrow functions for declarations
89
- - Run `bun run check:write` to auto-fix style issues
90
-
91
- **Testing**:
92
-
93
- - Add tests for new features
94
- - Maintain >80% coverage for utilities
95
- - Run `bun test` to verify
96
-
97
- **Documentation**:
98
-
99
- - Update AGENTS.md for developer-facing changes
100
- - Update README.md for user-facing changes
101
- - Add JSDoc comments for public APIs
102
-
103
- #### 3. Commit Your Changes
104
-
105
- Use [Conventional Commits](https://www.conventionalcommits.org/) format:
106
-
107
- ```
108
- <type>(<scope>): <subject>
109
-
110
- <body>
111
-
112
- <footer>
113
- ```
114
-
115
- **Types**:
116
-
117
- - `feat`: New feature
118
- - `fix`: Bug fix
119
- - `docs`: Documentation
120
- - `test`: Tests
121
- - `refactor`: Code refactoring
122
- - `chore`: Maintenance
123
- - `ci`: CI/CD changes
124
- - `perf`: Performance
125
- - `style`: Code style
126
- - `build`: Build system
127
-
128
- **Scopes** (optional):
129
-
130
- - `search`, `express`, `contents`, `shared`, `http`, `stdio`
131
-
132
- **Examples**:
133
-
134
- ```bash
135
- git commit -m "feat(search): add freshness filter support"
136
- git commit -m "fix(express): handle timeout errors gracefully"
137
- git commit -m "docs: update API examples in README"
138
- ```
139
-
140
- #### 4. Push and Create PR
141
-
142
- ```bash
143
- git push origin feature/your-feature-name
144
- ```
145
-
146
- Then create a pull request on GitHub with:
147
-
148
- - Clear title following commit conventions
149
- - Description of changes and motivation
150
- - Reference to related issues
151
- - Screenshots/examples if applicable
152
-
153
- #### 5. Code Review
154
-
155
- - Maintainers will review your PR
156
- - Address feedback constructively
157
- - Keep PR focused (one feature/fix per PR)
158
- - Be patient - reviews take time
159
-
160
- **PR Checklist**:
161
-
162
- - [ ] All tests pass (`bun test`)
163
- - [ ] Code quality checks pass (`bun run check`)
164
- - [ ] Documentation updated
165
- - [ ] Commit messages follow conventions
166
- - [ ] Branch is up-to-date with main
167
-
168
- ## Development Workflow
169
-
170
- ### Quality Checks
171
-
172
- Before submitting:
173
-
174
- ```bash
175
- bun run check # Biome + TypeScript + package.json
176
- bun test # Run all tests
177
- bun test --coverage # Check coverage
178
- ```
179
-
180
- ### Git Hooks
181
-
182
- Pre-commit hooks run automatically:
183
-
184
- - Biome formatting and linting
185
- - package.json formatting
186
-
187
- **Never bypass hooks** with `--no-verify`
188
-
189
- ### Local Testing
190
-
191
- Test with MCP Inspector:
192
-
193
- ```bash
194
- bun run inspect
195
- ```
196
-
197
- ### Architecture
198
-
199
- For codebase architecture, patterns, and technical details, see [AGENTS.md](./AGENTS.md).
200
-
201
- ## Getting Help
202
-
203
- ### Documentation
204
-
205
- - **Users**: [README.md](./README.md)
206
- - **Developers**: [AGENTS.md](./AGENTS.md)
207
- - **API Reference**: [API.md](./docs/API.md)
208
- - **You.com Docs**: https://documentation.you.com
209
-
210
- ### Support Channels
211
-
212
- - **GitHub Issues**: Bug reports and feature requests
213
- - **Email**: support@you.com
214
- - **Web Support**: https://you.com/support/contact-us
215
-
216
- ### Maintainer Response Time
217
-
218
- We aim to:
219
-
220
- - Acknowledge issues within 48 hours
221
- - Review PRs within 1 week
222
- - Respond to questions within 3 business days
223
-
224
- ## Recognition
225
-
226
- Contributors are recognized through:
227
-
228
- - Co-authorship in commits (Git)
229
- - Attribution in release notes
230
- - GitHub contributor graph
231
- - Acknowledgment in project documentation
232
-
233
- ## Types of Contributions We Value
234
-
235
- Beyond code, we appreciate:
236
-
237
- - 📝 Documentation improvements
238
- - 🐛 Bug reports with clear reproduction steps
239
- - 💡 Feature ideas and use case feedback
240
- - 🧪 Test coverage improvements
241
- - 🎨 UX/DX enhancements
242
- - 📢 Spreading the word about the project
243
-
244
- ---
245
-
246
- **Thank you for contributing to You.com MCP Server!** 🎉
package/docs/API.md DELETED
@@ -1,319 +0,0 @@
1
- # You.com MCP Server API Reference
2
-
3
- Complete technical documentation for all MCP tools provided by the You.com MCP Server.
4
-
5
- For setup and usage guides, see [README.md](../README.md).
6
- For development patterns and architecture, see [AGENTS.md](../AGENTS.md).
7
-
8
- ## Tools Overview
9
-
10
- | Tool | Purpose | Authentication |
11
- |------|---------|----------------|
12
- | `you-search` | Web and news search with advanced filtering | X-API-Key |
13
- | `you-express` | AI-powered answers with optional web search | Bearer token |
14
- | `you-contents` | Content extraction from web pages | X-API-Key |
15
-
16
- ---
17
-
18
- ## `you-search`
19
-
20
- Performs a comprehensive web and news search using the You.com Search API.
21
-
22
- ### Parameters
23
-
24
- - `query` (string, required): The base search query to send to the You.com API. This will be combined with additional filters like site, fileType, and language to create the final search query. You can also use operators directly: + (exact term, e.g., "Enron +GAAP"), - (exclude term, e.g., "guitar -prs"), site: (domain, e.g., "site:uscourts.gov"), filetype: (e.g., "filetype:pdf"), lang: (e.g., "lang:es"). Use parentheses for multi-word phrases (e.g., "+(machine learning)", "-(social media)").
25
- - `site` (string, optional): Search within a specific website domain (e.g., 'github.com')
26
- - `fileType` (string, optional): Filter by a specific file type (e.g., 'pdf', 'doc', 'txt')
27
- - `language` (string, optional): Filter by a specific language using ISO 639-1 code (e.g., 'en', 'es', 'fr')
28
- - `exactTerms` (string, optional): Exact terms with logical operators: 'python AND|tutorial|NOT beginner' (pipe-separated, add AND/OR after terms, default OR). Use parentheses for multi-word phrases (e.g., '(machine learning)|typescript')
29
- - `excludeTerms` (string, optional): Terms to exclude with logical operators: 'spam AND|ads|NOT relevant' (pipe-separated, add AND/OR after terms, default OR). Use parentheses for multi-word phrases (e.g., '(social media)|ads'). Cannot be used with exactTerms.
30
- - `count` (integer, optional): Maximum number of results to return per section. Range: 1-20.
31
- - `freshness` (string, optional): Freshness of results. Options: `day`, `week`, `month`, `year`.
32
- - `offset` (integer, optional): Offset for pagination (calculated in multiples of count). Range: 0-9.
33
- - `country` (string, optional): Country code for localized results. Examples: `US`, `GB`, `DE`, `FR`, `JP`, `CA`, `AU`, etc.
34
- - `safesearch` (string, optional): Content filtering level. Options: `off`, `moderate` (default), `strict`.
35
-
36
- ### Response Format
37
-
38
- ```json
39
- {
40
- "content": [
41
- {
42
- "type": "text",
43
- "text": "Search Results for \"machine learning\":\n\nWEB RESULTS:\n\nTitle: Introduction to Machine Learning\nURL: https://github.com/ml-tutorials/intro\nDescription: A comprehensive guide to machine learning fundamentals\nSnippets:\n- Learn the basics of supervised and unsupervised learning\n- Practical examples with Python and TensorFlow\n\n---\n\nTitle: Machine Learning Course\nURL: https://coursera.org/ml-course\nDescription: Stanford's machine learning course materials\nSnippets:\n- Mathematical foundations of ML algorithms\n- Hands-on programming assignments\n\n==================================================\n\nNEWS RESULTS:\n\nTitle: AI Breakthrough in Medical Diagnosis\nURL: https://techcrunch.com/ai-medical-breakthrough\nDescription: New machine learning model achieves 95% accuracy\nPublished: 2024-01-15T10:30:00"
44
- }
45
- ],
46
- "structuredContent": {
47
- "results": {
48
- "web": [
49
- {
50
- "url": "https://github.com/ml-tutorials/intro",
51
- "title": "Introduction to Machine Learning",
52
- "description": "A comprehensive guide to machine learning fundamentals",
53
- "snippets": [
54
- "Learn the basics of supervised and unsupervised learning",
55
- "Practical examples with Python and TensorFlow"
56
- ],
57
- "page_age": "2024-01-10T14:20:00",
58
- "authors": ["ML Tutorial Team"]
59
- }
60
- ],
61
- "news": [
62
- {
63
- "url": "https://techcrunch.com/ai-medical-breakthrough",
64
- "title": "AI Breakthrough in Medical Diagnosis",
65
- "description": "New machine learning model achieves 95% accuracy",
66
- "page_age": "2024-01-15T10:30:00"
67
- }
68
- ]
69
- },
70
- "metadata": {
71
- "query": "machine learning",
72
- "request_uuid": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
73
- "latency": 0.247
74
- }
75
- }
76
- }
77
- ```
78
-
79
- ---
80
-
81
- ## `you-express`
82
-
83
- Fast AI-powered agent for quick responses with optional real-time web search integration.
84
-
85
- ### Parameters
86
-
87
- - `input` (string, required): The query or instruction to send to the Express agent. Example: "What is the capital of France?"
88
- - `tools` (array, optional): Array of tool objects to expand the agent's capabilities. Currently supports:
89
- - `{ type: "web_search" }` - Enables real-time web search to provide more accurate and up-to-date information
90
-
91
- ### Features
92
-
93
- - Fast response times optimized for straightforward queries
94
- - Optional web search integration for real-time information
95
- - AI-synthesized answers with source citations (when web_search is enabled)
96
- - Non-streaming JSON responses (`stream: false`) for reliability
97
-
98
- ### Response Structure
99
-
100
- The tool returns a token-efficient MCP response format:
101
-
102
- - `answer` (string, required): AI-synthesized answer from the Express agent
103
- - `results` (object, optional): Web search results included when `web_search` tool is used
104
- - `web` (array): Array of search result objects, each containing:
105
- - `url` (string): The URL of the search result
106
- - `title` (string): The title of the search result
107
- - `snippet` (string): A text snippet from the search result
108
- - `agent` (string, optional): Agent identifier (e.g., "express")
109
-
110
- ### Example 1: Simple query without web_search
111
-
112
- **Input:**
113
-
114
- ```json
115
- {
116
- "input": "What is 2 + 2?"
117
- }
118
- ```
119
-
120
- **Response:**
121
-
122
- ```json
123
- {
124
- "content": [
125
- {
126
- "type": "text",
127
- "text": "Express Agent Answer:\n\n2 + 2 equals 4."
128
- }
129
- ],
130
- "structuredContent": {
131
- "answer": "2 + 2 equals 4.",
132
- "agent": "express"
133
- }
134
- }
135
- ```
136
-
137
- ### Example 2: Query with web_search enabled
138
-
139
- **Input:**
140
-
141
- ```json
142
- {
143
- "input": "What is the capital of France?",
144
- "tools": [{ "type": "web_search" }]
145
- }
146
- ```
147
-
148
- **Response:**
149
-
150
- ```json
151
- {
152
- "content": [
153
- {
154
- "type": "text",
155
- "text": "Express Agent Answer:\n\nThe capital of France is Paris, the country's largest city and its political, economic, and cultural center..."
156
- },
157
- {
158
- "type": "text",
159
- "text": "\nSearch Results:\n\nTitle: Paris - Wikipedia\nURL: https://en.wikipedia.org/wiki/Paris\nSnippet: Paris is the capital and most populous city of France. With an official estimated population of 2,102,650 residents...\n\nTitle: Paris | History, Map, Population, & Facts | Britannica\nURL: https://www.britannica.com/place/Paris\nSnippet: Paris, city and capital of France, situated in the north-central part of the country..."
160
- }
161
- ],
162
- "structuredContent": {
163
- "answer": "The capital of France is Paris, the country's largest city and its political, economic, and cultural center...",
164
- "results": {
165
- "web": [
166
- {
167
- "url": "https://en.wikipedia.org/wiki/Paris",
168
- "title": "Paris - Wikipedia",
169
- "snippet": "Paris is the capital and most populous city of France. With an official estimated population of 2,102,650 residents..."
170
- },
171
- {
172
- "url": "https://www.britannica.com/place/Paris",
173
- "title": "Paris | History, Map, Population, & Facts | Britannica",
174
- "snippet": "Paris, city and capital of France, situated in the north-central part of the country..."
175
- }
176
- ]
177
- },
178
- "agent": "express"
179
- }
180
- }
181
- ```
182
-
183
- ### Notes
184
-
185
- - The `content` array always displays the answer first, followed by search results (if web_search was used)
186
- - The response format is optimized for token efficiency, returning only essential fields
187
- - Search results are formatted consistently with the `you-search` tool using shared formatting utilities
188
-
189
- ---
190
-
191
- ## `you-contents`
192
-
193
- Extract and retrieve full content from web pages using the You.com Contents API. Returns content in markdown or HTML format for documentation, analysis, and content processing.
194
-
195
- ### Parameters
196
-
197
- - `urls` (array of strings, required): Array of URLs to extract content from. The API processes all URLs in a single request. Example: `["https://example.com", "https://wikipedia.org/wiki/AI"]`
198
- - `format` (string, optional): Output format for the extracted content. Default: `"markdown"`
199
- - `"markdown"` - Recommended for: text extraction, documentation, simpler consumption, and general content analysis
200
- - `"html"` - Recommended for: layout preservation, interactive content, visual fidelity, training data with structural details, and complex formatting
201
-
202
- ### Format Selection Guidance
203
-
204
- **Use markdown when you need:**
205
-
206
- - Clean, readable text without HTML tags
207
- - Content for documentation or note-taking
208
- - Simpler content parsing and processing
209
- - Text-focused analysis
210
-
211
- **Use HTML when you need:**
212
-
213
- - Preserve original page layout and structure
214
- - Interactive elements (forms, buttons, etc.)
215
- - Visual fidelity and styling information
216
- - Training data with semantic HTML structure
217
- - Complex formatting like tables with styling
218
-
219
- ### Response Structure
220
-
221
- The tool returns both text and structured content formats:
222
-
223
- - `content` (array): Text representation with metadata and full extracted content
224
- - `structuredContent` (object): Machine-readable format with metadata
225
- - `count` (number): Number of URLs processed
226
- - `format` (string): Format used for extraction ("markdown" or "html")
227
- - `items` (array): Array of extracted content objects, each containing:
228
- - `url` (string): URL of the extracted content
229
- - `title` (string): Page title
230
- - `content` (string): Full extracted content in the specified format
231
- - `contentLength` (number): Length of extracted content in characters
232
-
233
- ### Example 1: Single URL with markdown format (default)
234
-
235
- **Input:**
236
-
237
- ```json
238
- {
239
- "urls": ["https://example.com"]
240
- }
241
- ```
242
-
243
- **Response:**
244
-
245
- ```json
246
- {
247
- "content": [
248
- {
249
- "type": "text",
250
- "text": "Successfully extracted content from 1 URL(s):\n\n## Example Domain\nURL: https://example.com\nFormat: markdown\nContent Length: 156 characters\n\n---\n\n# Example Domain\n\nThis domain is for use in illustrative examples in documents. You may use this domain in literature without prior coordination or asking for permission.\n\n[More information...](https://www.iana.org/domains/example)\n\n---\n"
251
- }
252
- ],
253
- "structuredContent": {
254
- "count": 1,
255
- "format": "markdown",
256
- "items": [
257
- {
258
- "url": "https://example.com",
259
- "title": "Example Domain",
260
- "content": "# Example Domain\n\nThis domain is for use in illustrative examples in documents. You may use this domain in literature without prior coordination or asking for permission.\n\n[More information...](https://www.iana.org/domains/example)",
261
- "contentLength": 156
262
- }
263
- ]
264
- }
265
- }
266
- ```
267
-
268
- ### Example 2: Multiple URLs with HTML format
269
-
270
- **Input:**
271
-
272
- ```json
273
- {
274
- "urls": [
275
- "https://example.com",
276
- "https://en.wikipedia.org/wiki/Artificial_intelligence"
277
- ],
278
- "format": "html"
279
- }
280
- ```
281
-
282
- **Response:**
283
-
284
- ```json
285
- {
286
- "content": [
287
- {
288
- "type": "text",
289
- "text": "Successfully extracted content from 2 URL(s):\n\n## Example Domain\nURL: https://example.com\nFormat: html\nContent Length: 1234 characters\n\n---\n\n<html><body><h1>Example Domain</h1><p>This domain is for use in illustrative examples...</p></body></html>\n\n---\n\n## Artificial intelligence - Wikipedia\nURL: https://en.wikipedia.org/wiki/Artificial_intelligence\nFormat: html\nContent Length: 45678 characters\n\n---\n\n<html><body><h1>Artificial intelligence</h1><p>Artificial intelligence (AI), in its broadest sense...</p></body></html>\n\n---\n"
290
- }
291
- ],
292
- "structuredContent": {
293
- "count": 2,
294
- "format": "html",
295
- "items": [
296
- {
297
- "url": "https://example.com",
298
- "title": "Example Domain",
299
- "content": "<html><body><h1>Example Domain</h1><p>This domain is for use in illustrative examples...</p></body></html>",
300
- "contentLength": 1234
301
- },
302
- {
303
- "url": "https://en.wikipedia.org/wiki/Artificial_intelligence",
304
- "title": "Artificial intelligence - Wikipedia",
305
- "content": "<html><body><h1>Artificial intelligence</h1><p>Artificial intelligence (AI), in its broadest sense...</p></body></html>",
306
- "contentLength": 45678
307
- }
308
- ]
309
- }
310
- }
311
- ```
312
-
313
- ### Notes
314
-
315
- - The API processes all URLs in a single request, making it efficient for batch extraction
316
- - Full content is returned in both the text representation and structured format
317
- - You.com URLs may return empty results due to self-scraping prevention
318
- - For testing, use publicly accessible URLs like example.com, Wikipedia, or documentation sites
319
- - The tool returns complete content without truncation, suitable for documentation and analysis workflows