Softwareheritage
v0.2.1Software Heritage MCP.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
origin_search
Search the Software Heritage archive for archived origins (repository URLs) whose URL matches a substring or pattern. Returns each matching origin with its visit count and the date it was last captured. Use this to find the archived URL for a project before asking about its status — the archive keys everything on the ORIGIN URL, so "torvalds/linux" finds the GitHub origin and any separately archived copy of the same project on another forge. Sourced from the Software Heritage archive.
| Parameter | Type | Description |
|---|---|---|
query * | string | Substring of the repository URL to match (e.g. "torvalds/linux", "pallets/flask", "gitlab.com/inkscape"). |
limit | number | Maximum origins to return, 1-1000 (default 10). |
with_visit | boolean | When true, return only origins that have actually been visited and archived (default true). False also returns origins that are merely known. |
origin_status
Report whether one repository URL is archived, and as of when. Returns the most recent visit that produced a usable snapshot: the visit date, the snapshot id, and the visit type (git, hg, svn, npm, pypi…). This is the tool that answers "is this code safe" — a repository that vanishes tomorrow is recoverable from the snapshot named here. Pass the origin URL exactly as it appears in origin_search; the archive treats a differing URL as a different origin. Sourced from the Software Heritage archive.
| Parameter | Type | Description |
|---|---|---|
url * | string | Full origin URL as archived (e.g. "https://github.com/torvalds/linux"). |
origin_visits
List the archive's visit history for one repository URL, newest first: when each capture ran, what it produced, and whether it succeeded ("full"), partially succeeded, or failed ("not_found" — the origin was unreachable at that moment). Use this to see how continuously a project has been captured, and to distinguish "never archived" from "archived for years and unreachable this week". Sourced from the Software Heritage archive.
| Parameter | Type | Description |
|---|---|---|
url * | string | Full origin URL as archived (e.g. "https://github.com/torvalds/linux"). |
limit | number | Maximum visits to return, 1-100 (default 10). |
revision
Fetch one archived commit by its Software Heritage revision id (the 40-hex id, which for a git repository is the git commit sha). Returns the commit message, author and committer with their dates, the directory id of the tree it points at, and its parent commits. Accepts a bare hex id or a full SWHID ("swh:1:rev:<hex>"). Because the archive is content-addressed, this keeps resolving after the repository it came from has been renamed, moved or deleted. Sourced from the Software Heritage archive.
| Parameter | Type | Description |
|---|---|---|
id * | string | Revision id — a 40-character hex sha ("309cf37fe2a781279b7675d4bb7173198e532867") or a SWHID ("swh:1:rev:309cf37f…"). |