MCPcopy Index your code
hub / github.com/google/go-github / Labels

Method Labels

github/search.go:292–300  ·  view source on GitHub ↗

Labels searches labels in the repository with ID repoID via various criteria. GitHub API docs: https://docs.github.com/rest/search/search?apiVersion=2022-11-28#search-labels meta:operation GET /search/labels

(ctx context.Context, repoID int64, query string, opts *SearchOptions)

Source from the content-addressed store, hash-verified

290//
291//meta:operation GET /search/labels
292func (s *SearchService) Labels(ctx context.Context, repoID int64, query string, opts *SearchOptions) (*LabelsSearchResult, *Response, error) {
293 var result *LabelsSearchResult
294 resp, err := s.search(ctx, "labels", &searchParameters{RepositoryID: &repoID, Query: query}, opts, &result)
295 if err != nil {
296 return nil, resp, err
297 }
298
299 return result, resp, nil
300}
301
302// Helper function that executes search queries against different
303// GitHub search types (repositories, commits, code, issues, users, labels)

Callers 2

TestSearchService_LabelsFunction · 0.80

Calls 1

searchMethod · 0.95

Tested by 2

TestSearchService_LabelsFunction · 0.64