Skip to content

Pull Request: Add GitLab Events API Tools - #235

Merged
zereight merged 2 commits into
zereight:mainfrom
owenjeon:feature/events
Sep 5, 2025
Merged

zereight merged 2 commits into
zereight:mainfrom
owenjeon:feature/events

Conversation

@owenjeon

Copy link
Copy Markdown
Contributor

📋 Summary

Added event monitoring capabilities to GitLab MCP by introducing new tools that allow users to track activity history for both users and projects.

🚀 New Features

  • list_events: List all events for the currently authenticated user
  • get_project_events: List all visible events for a specified project

✨ Key Capabilities

  • Filtering Options:
    • action: Filter by specific action types
    • target_type: Filter by target types (issue, merge_request, milestone, note, project, snippet, user, epic)
    • before/after: Date range filtering (YYYY-MM-DD format)
    • sort: Sort by creation date (asc/desc)
  • Pagination: Support for page and per_page parameters
  • Scope Control: Option to include events across all user projects

📁 Files Changed

  • README.md: Documentation for new tools
  • index.ts:
    • Implemented listEvents() and getProjectEvents() functions
    • Added tool definitions and request handlers
    • Added to read-only tools list
  • schemas.ts:
    • Added GitLabEventSchema and GitLabEventAuthorSchema
    • Added ListEventsSchema and GetProjectEventsSchema
    • Exported type definitions

🧪 Testing

  • Schema validation passes
  • API response parsing works correctly
  • Classified as read-only tools for safety

- Add list_events tool to list all events for authenticated user
- Add get_project_events tool to list events for specific project
- Support filtering by action, target_type, date range, and sorting
- Update README.md with new tools documentation
- Add comprehensive schemas for event data structures
Comment thread index.ts Outdated
Comment on lines +4110 to +4112
* @returns {Promise<GitLabEvent[]>} List of events
*/
async function listEvents(options: z.infer<typeof ListEventsSchema> = {}): Promise<any[]> {

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Thanks for your contributions. Is GitLabEvent a hard part to guess the type?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I missed Thanks! I missed that. I’ve pushed the fix.

@zereight

zereight commented Sep 5, 2025 •

Copy link
Copy Markdown
Owner

감사합니다~ 다른 PR도 머지되는대로 deploy하겠습니다. 🙏

@zereight
zereight merged commit c90b1aa into zereight:main Sep 5, 2025
7 checks passed
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.

2 participants