Tool reference
search_issues
Find issues in one repository using state, label and milestone filters.
Find issues in one repository using state, label and milestone filters. Every call targets one authorized repository and leaves its issues unchanged.
Parameters
Name | Type / required | Behavior |
|---|---|---|
repo | string · required | Nonempty owner/repository, for example acme/sdk. |
state | enum · optional | open, closed or all. Default open. |
label | string · optional | Exact label name; omission accepts any label. |
milestone | string · optional | Exact milestone title; omission includes unassigned issues. |
limit | integer · optional | Default 20; minimum 1, maximum 50. |
Example call
search_issues({
"repo": "acme/sdk",
"state": "open",
"label": "bug",
"limit": 50
})Example response
{
"repo": "acme/sdk",
"issues": [
{
"number": 412,
"title": "Retry loop continues after cancellation",
"state": "open",
"labels": [
"bug"
],
"milestone": "v2.0"
},
{
"number": 409,
"title": "Timeout option is ignored during reconnect",
"state": "open",
"labels": [
"bug"
],
"milestone": "v2.0"
},
{
"number": 405,
"title": "Empty response throws a parsing error",
"state": "open",
"labels": [
"bug"
],
"milestone": "v2.0"
},
{
"number": 398,
"title": "Request headers are lost after a redirect",
"state": "open",
"labels": [
"bug"
],
"milestone": "v2.0"
},
{
"number": 391,
"title": "Pagination repeats the last item",
"state": "open",
"labels": [
"bug"
],
"milestone": "v2.1"
},
{
"number": 384,
"title": "Streaming response does not close on abort",
"state": "open",
"labels": [
"bug"
],
"milestone": "v2.1"
},
{
"number": 377,
"title": "Error message omits the request ID",
"state": "open",
"labels": [
"bug"
],
"milestone": null
}
],
"returned_count": 7,
"truncated": false
}Limits and edge cases
All supplied filters are combined. Adding milestone v2.0 to this fixture returns #412, #409, #405 and #398. Use list_labels and list_milestones to discover exact names.
An unknown label or milestone yields an empty list. An unsupported state, unknown input field or invalid limit yields INVALID_ARGUMENT. A successful empty response still includes returned_count: 0 and truncated: false.
Results contain summary fields. Use get_issue for the full description. The fixture orders issues by descending number. There is no cursor or offset in this contract; narrow filters when truncated is true.
Errors and recovery
AUTH_REQUIRED means the credential is missing or no longer valid. ACCESS_DENIED means it cannot read the repository. INVALID_ARGUMENT means an input violates this schema. RATE_LIMITED and UPSTREAM_UNAVAILABLE need an upstream recovery step, not a broader permission grant.