projectstatistics

package
v1.0.5 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package projectstatistics implements MCP tools for GitLab project statistics.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FormatMarkdown

func FormatMarkdown(out GetOutput) string

FormatMarkdown formats project statistics as markdown.

func RegisterMeta

func RegisterMeta(server *mcp.Server, client *gitlabclient.Client)

RegisterMeta registers the gitlab_project_statistics meta-tool.

func RegisterTools

func RegisterTools(server *mcp.Server, client *gitlabclient.Client)

RegisterTools registers all project statistics MCP tools on the given server.

Types

type DayStat

type DayStat struct {
	Date  string `json:"date"`
	Count int64  `json:"count"`
}

DayStat represents a single day's fetch count.

type GetInput

type GetInput struct {
	ProjectID toolutil.StringOrInt `json:"project_id" jsonschema:"Project ID or URL-encoded path,required"`
}

GetInput contains parameters for getting project statistics.

type GetOutput

type GetOutput struct {
	toolutil.HintableOutput
	TotalFetches int64     `json:"total_fetches"`
	Days         []DayStat `json:"days"`
}

GetOutput contains project statistics (last 30 days fetch data).

func Get

func Get(ctx context.Context, client *gitlabclient.Client, input GetInput) (GetOutput, error)

Get retrieves the last 30 days of project statistics.

Jump to

Keyboard shortcuts

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