GET
github_search_code.py
Requires
repo, read:user. Pages by number: page with per_page.Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Search code across GitHub. Only default branches are indexed and only files under 384 KB. The query needs a real search term, not just qualifiers. This endpoint allows ten requests per minute and returns at most 1,000 results.
from charter.packs import github
result = await github.search_code.ainvoke({"q": ...})
repo, read:user. Pages by number: page with per_page.| Field | Type | Description |
|---|---|---|
perPage | integer | The number of results per page (max 100). Defaults to 30. ≥ 1; ≤ 100; defaults to 30 |
page | integer | The page number of the results to fetch. Defaults to 1. ≥ 1; defaults to 1 |
q * | string | The search query. Combine a term with qualifiers: ‘retry in:file language:python repo:owner/name’. Useful qualifiers are in:file, in:path, language:, repo:, org:, user:, path:, filename:, extension:, size:. |
Was this page helpful?