git-scm.com APIgit-scm.com ↗
Access Git command documentation, versioned reference pages, Pro Git book chapters, and the Git glossary via a structured JSON API with 9 endpoints.
No input parameters required.
curl -X GET 'https://api.parse.bot/scraper/8b5ba661-798d-4e0b-ad04-a0eae3fd8286/get_homepage' \ -H 'X-API-Key: $PARSE_API_KEY'
Get homepage content including navigation links, content blocks, and the latest Git version number.
No input parameters required.
{
"type": "object",
"fields": {
"title": "string, page title",
"content_blocks": "object containing page content sections keyed by section name (e.g. masthead, front_content)",
"latest_version": "string, latest Git release version number",
"navigation_links": "array of navigation link objects with text, url, and description"
},
"sample": {
"data": {
"title": "Git",
"content_blocks": {
"masthead": "Git is a free and open source distributed version control system..."
},
"latest_version": "2.54.0",
"navigation_links": [
{
"url": "/about",
"text": "About",
"description": "Git's performance and ecosystem"
},
{
"url": "/learn",
"text": "Learn",
"description": "Pro Git book, videos, tutorials, and cheat sheet"
}
]
},
"status": "success"
}
}About the git-scm.com API
The git-scm.com API exposes 9 endpoints covering Git command references, versioned documentation, the Pro Git book table of contents and chapter text, and the full Git glossary. Use get_command_doc to retrieve every documentation section for a named command like git-rebase or git-log, or call get_book_chapter with a chapter slug to pull the full prose of any Pro Git section as plain text.
Command Reference
get_reference_index returns all Git commands organized into named categories, each with a commands array. For a flat list suitable for iteration, get_all_commands_list returns a total count plus every command's name, category, and url. Once you have a command name, get_command_doc retrieves its full documentation as a sections object — keys are section names (Synopsis, Description, Options, Examples, etc.) and values are the corresponding text. To target a specific Git release, get_command_doc_by_version accepts both a command and a version string (e.g. 2.40.0); if the exact version isn't available, the response reflects the nearest available version rather than returning an error.
Pro Git Book
get_book_toc returns the full table of contents as a chapters array, each entry carrying a chapter title and a sections array with slugs you can pass directly to get_book_chapter. That endpoint returns the chapter's title and content as a plain-text string, making it straightforward to index or display book sections programmatically.
Search and Glossary
search_docs accepts a case-insensitive query string and returns results across both the command reference index and the Git glossary, with each result typed as either glossary or command. get_glossary returns the entire glossary as a flat object where each key is a term name and the value is an HTML description string — useful for building offline reference tools or documentation search indexes.
Homepage and Navigation
get_homepage exposes the latest_version string alongside navigation_links (each with text, url, and description) and content_blocks keyed by section name. This is the simplest way to programmatically check the current stable Git release number without parsing a release page.
- Build a CLI tool that fetches the Options section of any Git command via
get_command_docand displays it inline in the terminal. - Track when git-scm.com updates the
latest_versionfield on the homepage to trigger downstream version-bump automation. - Generate a searchable offline Git reference by combining
get_all_commands_listwith per-command calls toget_command_doc. - Diff documentation between two Git releases using
get_command_doc_by_versionwith differentversioninputs for the same command. - Index every Pro Git book chapter for full-text search by iterating slugs from
get_book_tocand fetching content viaget_book_chapter. - Populate a Git glossary tooltip system using the term-to-HTML mapping returned by
get_glossary. - Power a documentation search feature that queries both commands and glossary terms through
search_docs.
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 250 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does git-scm.com have an official developer API?+
What does `get_command_doc_by_version` return when the requested version doesn't exist?+
version field in the response reflects what was requested, so you should check the returned title or sections to confirm which version's content was actually served.Does the API cover Git documentation in languages other than English?+
Does `search_docs` support filtering results to only commands or only glossary terms?+
search_docs endpoint returns a combined results array where each item has a type field set to either glossary or command. Filtering to one type requires client-side filtering on that field. The API currently does not accept a type filter parameter; you can fork it on Parse and revise it to add that parameter.Are man page sections like CONFIGURATION or NOTES always present in the `sections` object from `get_command_doc`?+
sections object keys vary by command — simpler commands may only have Synopsis, Description, and Options, while commands like git-config include additional sections. Always check for key existence before accessing a specific section in your code.