ioki-mobility / summaraizer

Summarizes comments from a variety of sources, such as GitHub issues, Slack threads, Reddit posts, and more using AI models from different providers, such as Ollama, OpenAI, and more.
https://ioki-mobility.github.io/summaraizer/
MIT License
1 stars 0 forks source link

Support for GitLab tickets/merge requests #11

Closed chb-ioki closed 3 months ago

chb-ioki commented 5 months ago

Analogous to the github ticket/PR integration, we could also support the GitLab Issues API.

StefMa commented 4 months ago

API: https://xxx.com/api/v4

To get the issue itself:

/projects/:id/issues/:number

While projectId equals to the repo encoded. Eg ioki/summaraizer is ioki%2Fsummaraizer https://docs.gitlab.com/ee/api/issues.html#single-project-issue

To get comments (notes in gitlab):

/projects/:id/issues/:number/notes

https://docs.gitlab.com/ee/api/notes.html#list-project-issue-notes (they are paginated, only 20 notes per request)

It seems that comments/notes requires an token. This can be done via the header PRIVATE-TOKEN: [TOKEN]

Because curl 'https://gitlab.com/api/v4/projects/wireshark%2Fwireshark/issues/19603/notes' is not working. While curl 'https://gitlab.com/api/v4/projects/wireshark%2Fwireshark/issues/19603 is working just fine.

StefMa commented 3 months ago

Fixed via #25