@zereight/mcp-gitlab 1.0.19 → 1.0.21

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/build/index.js CHANGED
@@ -1307,22 +1307,7 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
1307
1307
  }
1308
1308
  case "list_projects": {
1309
1309
  const args = ListProjectsSchema.parse(request.params.arguments);
1310
- const url = new URL(`${GITLAB_API_URL}/projects`);
1311
- // Add query parameters for filtering
1312
- Object.entries(args).forEach(([key, value]) => {
1313
- if (value !== undefined) {
1314
- url.searchParams.append(key, value.toString());
1315
- }
1316
- });
1317
- const response = await fetch(url.toString(), {
1318
- method: "GET",
1319
- headers: DEFAULT_HEADERS,
1320
- });
1321
- // Handle errors
1322
- await handleGitLabError(response);
1323
- // Parse and return the data
1324
- const data = await response.json();
1325
- const projects = z.array(GitLabProjectSchema).parse(data);
1310
+ const projects = await listProjects(args);
1326
1311
  return {
1327
1312
  content: [{ type: "text", text: JSON.stringify(projects, null, 2) }],
1328
1313
  };
package/build/schemas.js CHANGED
@@ -303,7 +303,7 @@ export const GitLabMergeRequestSchema = z.object({
303
303
  assignees: z.array(GitLabUserSchema).optional(),
304
304
  source_branch: z.string(),
305
305
  target_branch: z.string(),
306
- diff_refs: GitLabMergeRequestDiffRefSchema.optional(),
306
+ diff_refs: GitLabMergeRequestDiffRefSchema.nullable().optional(),
307
307
  web_url: z.string(),
308
308
  created_at: z.string(),
309
309
  updated_at: z.string(),
@@ -316,10 +316,10 @@ export const GitLabMergeRequestSchema = z.object({
316
316
  work_in_progress: z.boolean().optional(),
317
317
  blocking_discussions_resolved: z.boolean().optional(),
318
318
  should_remove_source_branch: z.boolean().nullable().optional(),
319
- force_remove_source_branch: z.boolean().optional(),
319
+ force_remove_source_branch: z.boolean().nullable().optional(),
320
320
  allow_collaboration: z.boolean().optional(),
321
321
  allow_maintainer_to_push: z.boolean().optional(),
322
- changes_count: z.string().optional(),
322
+ changes_count: z.string().nullable().optional(),
323
323
  merge_when_pipeline_succeeds: z.boolean().optional(),
324
324
  squash: z.boolean().optional(),
325
325
  labels: z.array(z.string()).optional(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zereight/mcp-gitlab",
3
- "version": "1.0.19",
3
+ "version": "1.0.21",
4
4
  "description": "MCP server for using the GitLab API",
5
5
  "license": "MIT",
6
6
  "author": "zereight",