Badges

SVG badges for GitLab project badges and READMEs. No sign-in, no state: the URL, with your API key in it, is the badge.

Usage

GET /<api key>/<type>.svg?label=…&message=…

ParameterDefaultMeaning
labelemptyLeft text. Empty: message only.
messageemptyRight text. Label or message is required, each at most 100 characters.
colorblueMessage background: a name or hex (4c1, %23e05d44).
label_colorgreyLabel background, same format.
styledefaultSize, predefined per type (below).
radiusper styleCorner radius in px, 0..20. rounded=false is radius=0.

Colors by name: green, success, passed, yellowgreen, yellow, running, pending, orange, red, failed, blue, purple, grey, gray, lightgrey, lightgray, skipped, canceled, black, white. Text is white or dark, whichever reads better on the background.

Types and styles

gitlab

StyleHeightExample
small18pxpipeline: passed /API_KEY/gitlab.svg?label=pipeline&message=passed&color=green&style=small
default20pxpipeline: passed /API_KEY/gitlab.svg?label=pipeline&message=passed&color=green&style=default
large28pxpipeline: passed /API_KEY/gitlab.svg?label=pipeline&message=passed&color=green&style=large

More examples

/API_KEY/gitlab.svg?label=coverage&message=87.5%25&color=yellowgreen
/API_KEY/gitlab.svg?label=status&message=failed&color=failed
/API_KEY/gitlab.svg?message=custom&color=ff69b4
/API_KEY/gitlab.svg?label=docs&message=latest&label_color=%23333&color=white
/API_KEY/gitlab.svg?label=release&message=v1.2.3&rounded=false

In GitLab

Settings → General → Badges, Badge image URL, e.g. https://badges.neopoly.dev/API_KEY/gitlab.svg?label=project&message=%{project_path} . GitLab fills in its placeholders before requesting the image.