Skip to main content
GET
/
api
/
badges
/
projects
/
{project_slug}
/
environments
/
{environment_slug}
Get an environment status badge
curl --request GET \
  --url https://api.empirical.run/api/badges/projects/{project_slug}/environments/{environment_slug} \
  --header 'Authorization: Bearer <token>'
"<string>"

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

project_slug
string
required

Slug of the project that owns the environment.

Minimum string length: 1
environment_slug
string
required

Slug of the environment to render a badge for.

Minimum string length: 1

Query Parameters

branch
string

Restrict the badge to the latest run on this branch. Blank/whitespace is treated as unset (latest run across branches).

label
string

Left-hand label text on the badge. Blank/whitespace falls back to the default (empirical tests).

Response

The rendered SVG badge image.

SVG markup for the status badge.