|
| 1 | +# Contributing to Model Context Protocol |
| 2 | + |
| 3 | +Thank you for your interest in contributing to the Model Context Protocol specification! This document outlines how to contribute to this project. |
| 4 | + |
| 5 | +## Prerequisites |
| 6 | + |
| 7 | +The following software is required to work on the spec: |
| 8 | + |
| 9 | +- Node.js 20 or above |
| 10 | +- TypeScript |
| 11 | +- TypeScript JSON Schema (for generating JSON schema) |
| 12 | +- Hugo (optional, for docs) |
| 13 | +- Go (optional, for docs) |
| 14 | +- nvm (optional, for managing Node versions) |
| 15 | + |
| 16 | +## Getting Started |
| 17 | + |
| 18 | +1. Fork the repository |
| 19 | +2. Clone your fork: |
| 20 | +```bash |
| 21 | +git clone https://github.com/YOUR-USERNAME/specification.git |
| 22 | +cd specification |
| 23 | +``` |
| 24 | + |
| 25 | +3. Install dependencies: |
| 26 | +```bash |
| 27 | +nvm install # install correct Node version |
| 28 | +npm install # install dependencies |
| 29 | +``` |
| 30 | + |
| 31 | +## Making Changes |
| 32 | + |
| 33 | +1. Create a new branch: |
| 34 | +```bash |
| 35 | +git checkout -b feature/your-feature-name |
| 36 | +``` |
| 37 | + |
| 38 | +2. Make your changes |
| 39 | +3. Validate your changes: |
| 40 | +```bash |
| 41 | +npm run validate:schema # validate schema |
| 42 | +npm run validate:examples # validate examples |
| 43 | +npm run generate:json # generate JSON schema |
| 44 | +``` |
| 45 | + |
| 46 | +4. Run docs locally (optional): |
| 47 | +```bash |
| 48 | +npm run serve:docs |
| 49 | +``` |
| 50 | + |
| 51 | +## Submitting Changes |
| 52 | + |
| 53 | +1. Push your changes to your fork |
| 54 | +2. Submit a pull request to the main repository |
| 55 | +3. Follow the pull request template |
| 56 | +4. Wait for review |
| 57 | + |
| 58 | +## Code of Conduct |
| 59 | + |
| 60 | +This project follows a Code of Conduct. Please review it in [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md). |
| 61 | + |
| 62 | +## Questions |
| 63 | + |
| 64 | +If you have questions, please create an issue in the repository. |
| 65 | + |
| 66 | +## License |
| 67 | + |
| 68 | +By contributing, you agree that your contributions will be licensed under the MIT License. |
| 69 | + |
| 70 | +## Security |
| 71 | + |
| 72 | +Please review our [Security Policy](SECURITY.md) for reporting security issues. |
0 commit comments