GitLab integration

The reviewer, not the team chat

GitLab's own Telegram integration posts into a shared channel, and a merge request waits until somebody happens to look. WardenPoint reads the same webhook and reaches the reviewer the merge request itself names.

Setup
Project webhook
Auth
X-Gitlab-Token
Reaches
One named person

Anatomy of a merge request page

LIVE
GitLab → webhook
MR !42 · reviewer @sjones · new commits
WardenPoint
read reviewers · match the login · page that person
Telegram
Voice call
Email

Setup

Three steps in GitLab

One webhook per project, or per group on GitLab Premium. The secret goes in GitLab's own «Secret token» field and arrives in the X-Gitlab-Token header.

  1. 1Step 1

    Add the webhook

    In the project go to Settings → Webhooks → Add new webhook. Paste your WardenPoint endpoint into the URL field.

    $ Settings › Webhooks › Add new webhook
  2. 2Step 2

    Paste the secret

    Put the integration secret into «Secret token». GitLab sends it as X-Gitlab-Token on every delivery, and a delivery without it is refused.

    $ Secret token
  3. 3Step 3

    Tick merge request events

    Under Trigger, tick «Merge request events» and save. Nothing else is needed — pipeline, push and comment events are ignored. If you check it with GitLab's Test button, pick «Merge request events» there too — a test of any other kind is dropped the same way, and the project needs at least one merge request for the test to have anything to send.

    $ Trigger › Merge request events

Wire format

Merge request webhook

GitLab names the reviewers in the body. WardenPoint reads why the event happened — assigned, new commits, review requested again — and pages the people that reason concerns.

GitLab → WardenPoint
merge-request.jsonJSON
// merge request webhook (X-Gitlab-Event: Merge Request Hook)
{
"object_kind": "merge_request",
"user": { "id": 1, "username": "root" },
"project": { "id": 15, "path_with_namespace": "acme/api" },
"object_attributes": {
"iid": 42,
"title": "Fix login redirect",
"action": "open",
"draft": false,
"author_id": 1,
"source_branch": "fix/login",
"target_branch": "main",
"url": "https://gitlab.com/acme/api/-/merge_requests/42"
},
"reviewers": [
{ "id": 25, "username": "sjones", "state": "unreviewed", "re_requested": false }
]
}
WardenPoint fan-out
WardenPoint response202
{
"status": "queued",
"notification_uuid": "notif_8h2k7yQrxJp",
"channels_planned": [
"telegram_voice",
"voice_call",
"email"
],
"escalation_chain_id": "esc_4j2k9bMcvL"
}

Routing recipes

Four rules a new integration comes with

They arrive already written. Change a set, add a condition or delete one — the first matching rule wins, and the last rule keeps everything else quiet.

Assigned

Someone put you on a merge request

Opening a merge request with reviewers, adding one later, or lifting the draft flag all reach the same people: everyone currently reviewing, minus the author and minus whoever performed the action.

match
reason = assigned
→ route
everyone reviewing
Commits

The author pushed after your comments

A push to the source branch or an applied suggestion pages only reviewers who already looked at the diff. Someone who has not opened it yet will see the changes when they do.

match
reason = new_commits
→ route
those who already looked
Re-request

You were asked to look again

GitLab marks a reviewer as asked again, and only that person is paged. One caveat: if the same edit also adds a new reviewer, the event reports itself as an assignment — the added reviewer wins, and the re-requested one is reached by the «Asked again» set rather than by this rule.

match
reason = re_requested
→ route
the asked reviewer

GitLab FAQ

Common questions about merge request alerts

The webhook names reviewers by their GitLab username. On the integration page you bind each username to a recipient once; every username the webhook mentions shows up there on its own, so there is no list to prepare in advance. If none of the people an event names is bound, the merge request lands in the triage inbox saying exactly which logins are missing. If some are bound and some are not, the bound ones are paged and the rest keep waiting on the integration page.
Free plan

Wire one project and open a merge request

Add the webhook, put yourself in as a reviewer and watch the message arrive. No credit card, no production risk.

  • Reaches a named person
  • Respects quiet hours
  • Draft and merged stay silent