Badge - Get

Gets a badge that indicates the status of the most recent build for a definition.

GET https://{instance}/{collection}/_apis/public/build/definitions/{project}/{definitionId}/badge?api-version=4.1
GET https://{instance}/{collection}/_apis/public/build/definitions/{project}/{definitionId}/badge?branchName={branchName}&api-version=4.1

URI Parameters

Name In Required Type Description
collection
path True

string

The name of the Team Foundation Server collection.

definitionId
path True

integer

int32

The ID of the definition.

instance
path True

string

TFS server name ({server:port})

project
path True

string

uuid

The project ID or name.

api-version
query True

string

Version of the API to use. This should be set to '4.1' to use this version of the api.

branchName
query

string

The name of the branch.

Responses

Name Type Description
200 OK

string

successful operation

Security

accessToken

Personal access token. Use any value for the user name and the token as the password.

Type: basic