raindrop-mcp / instructions
Copilot instructions188 starsChanged 9 months agoMITView on GitHub
This file now includes clear instructions for implementing tools and resources in an MCP server, following the design patterns from the template.
In this repository11 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- dxt-packagingSkill
- mcp-developmentSkill
- mcp-inspectorSkill
- mcp-refactoringSkill
- mcp-testingSkill
- publishingSkill
- raindrop-mcp-publishingSkill
- SKILL.mdSkill
The file
We split this copilot-instructions.md into the rules it gives an agent
9 rules. About 0 are common, 6 are distinctive, and 3 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 5
Protocol Compliance: All server logic must strictly follow the Model Context Protocol (MCP) specification.
- Very specific: line 8
Schema Validation: Use zod for all input/output validation.
- Very specific: line 12
Testing: Use Vitest for all tests. Place tests in tests/ and cover protocol, service, and transport logic.
- Very specific: line 13
Logging: Use a configurable logger.
- Distinctive: line 14
Async/Await: All operations must be async.
- Distinctive: line 15
Type Safety: Use TypeScript interfaces and types for all protocol objects.
- Distinctive: line 16
Configuration: Use environment variables and config files for secrets, endpoints, and options.
- Distinctive: line 17
Documentation: Document all public classes, methods, and schemas.
- Distinctive: line 26
Declarative Manifest: Ensure all tools and resources are declared in the manifest with their schemas, descriptions, and metadata.
≈ “Common” is an estimate: at least 1 in 5 of the 1,644 Copilot instructions files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
GitHub Copilot Instructions for MCP Server Development
MCP Server Design Patterns
- Protocol Compliance: All server logic must strictly follow the Model Context Protocol (MCP) specification. Reference MCP docs and LLMs integration guide.
- Transport Abstraction: Implement transport-agnostic logic. Use interfaces and dependency injection for HTTP, STDIO, or custom transports.
- Service Layer: Encapsulate business logic in service classes. Each service should be stateless, testable, and expose clear async methods for protocol operations.
- Schema Validation: Use
zodfor all input/output validation. Define schemas for requests, responses, and errors. Validate at the transport boundary. - Error Handling: Centralize error handling. Return MCP-compliant error objects with descriptive messages and codes.
- Manifest & Tooling: Expose a manifest endpoint/tool for host integration. Manifest must declare all supported operations, schemas, and metadata.
- Extensibility: Design for easy addition of new tools/operations. Use a registry or factory pattern for tool handlers.
- Testing: Use Vitest for all tests. Place tests in
tests/and cover protocol, service, and transport logic. - Logging: Use a configurable logger. Avoid
console.logfor STDIO servers; use structured logging and log levels. - Async/Await: All operations must be async.
- Type Safety: Use TypeScript interfaces and types for all protocol objects.
- Configuration: Use environment variables and config files for secrets, endpoints, and options.
- Documentation: Document all public classes, methods, and schemas.
Tool Implementation Patterns
- Tool Registration: Register each tool in a central registry or manifest. Use a factory or mapping to resolve tool handlers by name.
- Tool Handler Structure: Implement each tool as a class or function with a clear async
runorexecutemethod. Accept validated input, return structured output. - Schema-Driven: Define input/output schemas with
zod. Validate all tool calls at runtime. - Error Propagation: Catch errors in tool handlers and return MCP-compliant error objects.
- Resource Access: For resource tools (e.g., collections, bookmarks), encapsulate resource logic in dedicated service classes. Use dependency injection for external APIs.
- Declarative Manifest: Ensure all tools and resources are declared in the manifest with their schemas, descriptions, and metadata.
- Isolation: Tools should be stateless and not share mutable state. Use context objects for per-request data.
- Extensibility: New tools/resources should be easy to add by implementing a handler and updating the manifest/registry.
References
This file now includes clear instructions for implementing tools and resources in an MCP server, following the design patterns from the template.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

