standup-mr 0.3.3 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,27 @@ All notable changes to standup-mr are recorded here. The format follows
4
4
  [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the project uses
5
5
  [semantic versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [0.4.0] - 2026-09-01
8
+
9
+ ### Added
10
+
11
+ - **The MCP tool takes arguments.** `get_standup_data` exposed an empty input
12
+ schema, so an MCP client could not pick a provider, point at a self-hosted
13
+ host, or ask for Turkish date labels — all of which the CLI has always
14
+ allowed. `provider` (`github` / `gitlab`), `host` and `lang` (`en` / `tr`)
15
+ are now declared options, each with a description. The two enums replace
16
+ free strings, so an unsupported language is rejected instead of silently
17
+ falling back to English.
18
+
19
+ No token argument, deliberately: credentials come from the environment or a
20
+ logged-in `gh` / `glab` session, and a tool argument would end up in the
21
+ transcript.
22
+
23
+ ### Changed
24
+
25
+ - `zod` is a direct dependency rather than one borrowed from the MCP SDK's
26
+ dependency tree.
27
+
7
28
  ## [0.3.3] - 2026-09-01
8
29
 
9
30
  ### Fixed
@@ -5,6 +5,7 @@ import { realpathSync } from "fs";
5
5
  import { pathToFileURL } from "url";
6
6
  import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
7
7
  import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
8
+ import { z } from "zod";
8
9
 
9
10
  // src/manifest/manifest.ts
10
11
  import { existsSync, readFileSync } from "fs";
@@ -1043,16 +1044,32 @@ async function collect(options = {}) {
1043
1044
  const provider = options.providerImpl ?? connect({ provider: options.provider, host: options.host, token: options.token });
1044
1045
  return buildReport(provider, /* @__PURE__ */ new Date(), options.lang ?? "en");
1045
1046
  }
1047
+ var STANDUP_TOOL_SCHEMA = {
1048
+ provider: z.enum(["github", "gitlab"]).optional().describe(
1049
+ "Which provider to read. Omit to auto-detect, in this order: a recognisable host, STANDUP_PROVIDER, a GITHUB_*/GITLAB_* environment pair, then whichever of the gh / glab CLIs is logged in."
1050
+ ),
1051
+ host: z.string().optional().describe(
1052
+ "Self-hosted host, without a scheme, e.g. gitlab.example.com or github.example.com. GitHub defaults to github.com; GitLab has no default, so self-hosted GitLab needs this or GITLAB_HOST."
1053
+ ),
1054
+ lang: z.enum(["en", "tr"]).optional().describe(
1055
+ "Language for the date labels inside the returned JSON. Defaults to en. Only the labels change \u2014 the standup note itself is written by the caller."
1056
+ )
1057
+ };
1058
+ async function runStandupTool(args, collector = collect) {
1059
+ const report = await collector({
1060
+ provider: args.provider,
1061
+ host: args.host,
1062
+ lang: args.lang
1063
+ });
1064
+ return { content: [{ type: "text", text: JSON.stringify(report) }] };
1065
+ }
1046
1066
  async function main() {
1047
1067
  const server = new McpServer({ name: "standup-mr", version: packageVersion(import.meta.url) });
1048
1068
  server.tool(
1049
1069
  "get_standup_data",
1050
- "Collect merge-request-based standup data from GitLab or GitHub. Returns the previous working day activity, open merge requests or pull requests bucketed by state (ready / blocked / draft / stale), pending reviews, and the error lines from any failed pipeline or check.",
1051
- {},
1052
- async () => {
1053
- const report = await collect();
1054
- return { content: [{ type: "text", text: JSON.stringify(report) }] };
1055
- }
1070
+ "Collect merge-request-based standup data from GitLab or GitHub. Returns the previous working day activity, open merge requests or pull requests bucketed by state (ready / blocked / draft / stale), pending reviews, and the error lines from any failed pipeline or check. Credentials come from the environment or a logged-in gh / glab session, never from an argument.",
1071
+ STANDUP_TOOL_SCHEMA,
1072
+ async (args) => await runStandupTool(args)
1056
1073
  );
1057
1074
  await server.connect(new StdioServerTransport());
1058
1075
  }
@@ -1071,6 +1088,8 @@ if (entryUrl && import.meta.url === entryUrl) {
1071
1088
  });
1072
1089
  }
1073
1090
  export {
1091
+ STANDUP_TOOL_SCHEMA,
1074
1092
  collect,
1075
- main
1093
+ main,
1094
+ runStandupTool
1076
1095
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "standup-mr",
3
- "version": "0.3.3",
3
+ "version": "0.4.0",
4
4
  "mcpName": "io.github.Jubstaaa/standup-mr",
5
5
  "description": "Standup notes from merge request state, not commit logs.",
6
6
  "keywords": [
@@ -14,7 +14,7 @@
14
14
  ],
15
15
  "license": "MIT",
16
16
  "author": {
17
- "name": "\u0130lker Balc\u0131lar",
17
+ "name": "İlker Balcılar",
18
18
  "email": "ilkerbalcilartr@gmail.com"
19
19
  },
20
20
  "repository": {
@@ -60,7 +60,8 @@
60
60
  "prepublishOnly": "tsup"
61
61
  },
62
62
  "dependencies": {
63
- "@modelcontextprotocol/sdk": "^1.0.0"
63
+ "@modelcontextprotocol/sdk": "^1.0.0",
64
+ "zod": "^4.4.3"
64
65
  },
65
66
  "devDependencies": {
66
67
  "@types/bun": "^1.0.0",