Skip to content

Comments

Add GitHub Copilot instructions for repository conventions and structure#41

Merged
baruchiro merged 7 commits intomainfrom
copilot/set-up-copilot-instructions
Jan 18, 2026
Merged

Add GitHub Copilot instructions for repository conventions and structure#41
baruchiro merged 7 commits intomainfrom
copilot/set-up-copilot-instructions

Conversation

Copy link

Copilot AI commented Jan 16, 2026

Setup Copilot Instructions for paperless-mcp

Based on GitHub Copilot best practices, created comprehensive Copilot instructions:

  • Create .github/copilot-instructions.md with repository-wide guidelines
    • Define project structure and overview
    • Document build, test, and development commands
    • Specify TypeScript and code style conventions
    • Define boundaries and areas to avoid
    • Include MCP server-specific guidelines
  • Address all code review feedback
    • Combine Zod validation and error handling into single complete example
    • Update document enhancement documentation with correct file path and details
    • Correct SSE transport status with full endpoint details including sessionId parameter
    • Add guidance about using test instances for development
    • Update dependencies with accurate version numbers
    • Add note about TypeScript being listed as production dependency
  • Address PR review feedback
    • Add documentation about Paperless_ngx_REST_API.yaml OpenAPI spec file
    • Include guidance about chunking/parsing the large file
    • Add comprehensive changesets workflow documentation
    • Include changesets in common task workflows (adding tools, modifying API)
    • Document automated release process via GitHub Actions
  • Final review and validation complete

Summary

Created comprehensive Copilot instructions at .github/copilot-instructions.md including:

  • Project Overview: MCP server for Paperless-NGX with tech stack details
  • Repository Structure: Clear mapping of source code organization
  • Build Commands: All npm scripts documented
  • Code Style: Complete tool registration pattern with Zod and error handling
  • MCP Guidelines: All three transport modes (STDIO, HTTP, SSE) with accurate endpoint details
  • Security: Protected areas, API token handling, destructive operation guidelines
  • Testing: Manual testing guidance with test instance recommendations
  • Dependencies: All packages with accurate versions from package.json
  • Common Tasks: Step-by-step workflows for adding tools and modifying APIs
    • Includes changeset creation as required step for all changes
  • Changesets Workflow: Dedicated section explaining the required process
    • How to create changesets with npx changeset
    • Version bump types (patch/minor/major)
    • Automated release process via GitHub Actions
    • Configuration location and automation details
  • Related Documentation: Links to Paperless-NGX docs, MCP docs, and the detailed OpenAPI spec file (10,000+ lines)

All examples verified against actual implementation in the codebase.

Original prompt

This section details on the original issue you should resolve

<issue_title>✨ Set up Copilot instructions</issue_title>
<issue_description>Configure instructions for this repository as documented in Best practices for Copilot coding agent in your repository.

</issue_description>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.


Note

Introduces repository-wide guidance for contributors and AI assistants in /.github/copilot-instructions.md.

  • Defines project overview and src/ structure, with tool registration patterns using Zod + withErrorHandling
  • Documents build/run commands, STDIO/HTTP/SSE transport modes and endpoints, and environment-based config
  • Specifies TypeScript standards, naming conventions, and MCP tool naming
  • Clarifies security boundaries ("Never Touch" paths), API token handling, and destructive-operation confirmations
  • Provides testing guidance (manual via npm run inspect), error validation expectations, and use of test instances
  • Lists dependency versions and common tasks (adding tools, modifying API) with consistent API/client patterns
  • Establishes mandatory changesets workflow (creation, types, config, automation) and publishing via GitHub Actions
  • Links related docs, including Paperless_ngx_REST_API.yaml with guidance to chunk/parse due to file size

Written by Cursor Bugbot for commit dd2ed93. This will update automatically on new commits. Configure here.

@changeset-bot
Copy link

changeset-bot bot commented Jan 16, 2026

⚠️ No Changeset found

Latest commit: dd2ed93

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai
Copy link

coderabbitai bot commented Jan 16, 2026

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.


Comment @coderabbitai help to get the list of available commands and usage tips.

Copilot AI and others added 4 commits January 16, 2026 12:35
Co-authored-by: baruchiro <17686879+baruchiro@users.noreply.github.com>
Co-authored-by: baruchiro <17686879+baruchiro@users.noreply.github.com>
Co-authored-by: baruchiro <17686879+baruchiro@users.noreply.github.com>
Co-authored-by: baruchiro <17686879+baruchiro@users.noreply.github.com>
Copilot AI changed the title [WIP] Configure Copilot instructions for the repository Add GitHub Copilot instructions for repository conventions and structure Jan 16, 2026
Copilot AI requested a review from baruchiro January 16, 2026 12:44
Comment on lines +196 to +200
### Modifying API Client
1. Update method in `src/api/PaperlessAPI.ts`
2. Update type definitions in `src/api/types.ts`
3. Ensure error handling includes useful context
4. Maintain consistent request/response patterns
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mention the paperlessAPI swagger Jason file in the root project folder. This file describes the available APIs in paperless, it is the most detailed documentation that exists.

Although it is a huge file and the read it you should chunk it or use parsing tools to query it.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added documentation about the Paperless_ngx_REST_API.yaml file to the Related Documentation section with guidance about chunking/parsing due to its size (10,000+ lines, 264KB). Commit: 837c850

Co-authored-by: baruchiro <17686879+baruchiro@users.noreply.github.com>
Copy link
Owner

@baruchiro baruchiro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need also to describe the changesets tool required process.
Use web search to understand the tool, and read the project workflows and configs to understand the required structure.

You will need to generate a changeset file for every change you're suggesting.

Co-authored-by: baruchiro <17686879+baruchiro@users.noreply.github.com>
Copy link
Author

Copilot AI commented Jan 18, 2026

You need also to describe the changesets tool required process.
Use web search to understand the tool, and read the project workflows and configs to understand the required structure.
...

Added comprehensive changesets documentation including:

  • Dedicated "Creating Changesets (Required for All Changes)" section with step-by-step workflow
  • Version bump types explanation (patch/minor/major)
  • Automated GitHub Actions release process details
  • Integrated changeset creation into "Adding a New Tool" and "Modifying API Client" workflows
  • Configuration and automation details from .changeset/config.json and .github/workflows/release.yml

Commit: dd2ed93

@baruchiro baruchiro marked this pull request as ready for review January 18, 2026 06:04
Copilot AI review requested due to automatic review settings January 18, 2026 06:04
@baruchiro baruchiro enabled auto-merge (squash) January 18, 2026 06:06
@baruchiro baruchiro disabled auto-merge January 18, 2026 06:06
@baruchiro baruchiro enabled auto-merge (squash) January 18, 2026 06:06
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds comprehensive Copilot instructions to help GitHub Copilot better understand the repository's conventions, structure, and development workflows for the Paperless-NGX MCP server project.

Changes:

  • Created .github/copilot-instructions.md with detailed repository guidelines covering project structure, build commands, code conventions, MCP-specific patterns, security guidelines, dependencies, and development workflows
  • Documented the changesets workflow as a required step for all code changes
  • Included comprehensive technical details about TypeScript configuration, tool registration patterns, transport modes, and API client usage

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@baruchiro baruchiro disabled auto-merge January 18, 2026 06:10
@baruchiro baruchiro merged commit 6eda6e3 into main Jan 18, 2026
10 checks passed
@baruchiro baruchiro deleted the copilot/set-up-copilot-instructions branch January 18, 2026 06:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

✨ Set up Copilot instructions

2 participants