mcpserver

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 30, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

SPDX-License-Identifier: MIT Package mcpserver exposes the commit-query capability as an MCP tool over a stdio transport, so an LLM agent can ask for an author's recent commits.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(cfg config.Config) (*mcp.Server, error)

New builds an MCP server exposing the get_commits tool, configured from cfg.

func ReadOnlyTools

func ReadOnlyTools() []string

ReadOnlyTools lists the names of tools whose ReadOnlyHint is true. It is the single source of truth for which tools an installer may safely auto-approve, so the install permissions snippet cannot drift from what the server marks read-only. Every tool sting exposes is read-only by design.

Types

type GetCommitsInput

type GetCommitsInput struct {
	Author       string   `json:"author" jsonschema:"GitHub username (login) whose commits to retrieve"`
	Since        string   `json:"since,omitempty" jsonschema:"start of window, RFC3339 or YYYY-MM-DD; if omitted, window is used"`
	Until        string   `json:"until,omitempty" jsonschema:"end of window, RFC3339 or YYYY-MM-DD; defaults to now"`
	Window       string   `json:"window,omitempty" jsonschema:"look-back window when since is omitted, e.g. 7d, 2w, 48h; defaults to the server default"`
	Scope        string   `` /* 220-byte string literal not displayed */
	Repos        []string `` /* 149-byte string literal not displayed */
	Org          string   `` /* 160-byte string literal not displayed */
	IncludeStats bool     `json:"include_stats,omitempty" jsonschema:"fetch per-commit line additions/deletions (extra API calls)"`
}

GetCommitsInput is the argument schema for the get_commits tool. The jsonschema descriptions are surfaced to the calling agent.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL