Skip to content

List labels for issues in a milestone

GET
/repos/{owner}/{repo}/milestones/{milestone_number}/labels

Lists labels for issues in a milestone.

API method documentation

owner
required
string

The account owner of the repository. The name is not case sensitive.

repo
required
string

The name of the repository without the .git extension. The name is not case sensitive.

milestone_number
required
integer

The number that identifies the milestone.

per_page
integer
default: 30

The number of results per page (max 100). For more information, see “Using pagination in the REST API.”

page
integer
default: 1

The page number of the results to fetch. For more information, see “Using pagination in the REST API.”

Response

Media type application/json
Array<object>
Label

Color-coded labels help you categorize and filter your issues (just like labels in Gmail).

object
id
required

Unique identifier for the label.

integer format: int64
node_id
required
string
url
required

URL for the label

string format: uri
name
required

The name of the label.

string
description
required

Optional description of the label, such as its purpose.

string
nullable
color
required

6-character hex code, without the leading #, identifying the color

string
default
required

Whether this label comes by default in a new repository.

boolean
Examples
Example default
[
{
"id": 208045946,
"node_id": "MDU6TGFiZWwyMDgwNDU5NDY=",
"url": "https://api.github.com/repos/octocat/Hello-World/labels/bug",
"name": "bug",
"description": "Something isn't working",
"color": "f29513",
"default": true
},
{
"id": 208045947,
"node_id": "MDU6TGFiZWwyMDgwNDU5NDc=",
"url": "https://api.github.com/repos/octocat/Hello-World/labels/enhancement",
"name": "enhancement",
"description": "New feature or request",
"color": "a2eeef",
"default": false
}
]
Link
string
Example
<https://api.github.com/resource?page=2>; rel="next", <https://api.github.com/resource?page=5>; rel="last"