Skip to main content
  • Home
  • Development
  • Documentation
  • Donate
  • Operational login
    • Web API

    • endpoints
swh logo
SoftwareHeritage
Software
Heritage
Archive
Features
  • Search

  • Downloads

  • Save code now

  • Add forge now

  • Help

Below you can find a list of the available endpoints for version 1 of the Software Heritage API. For a more general introduction please refer to the API overview.

Endpoints marked "available" are considered stable for the current version of the API; endpoints marked "upcoming" are work in progress that will be stabilized in the near future.

  • Archive
  • Batch download
  • External IDentifiers
  • Metadata
  • Provenance
  • Request archival
  • Miscellaneous

Archive

EndpointDescription
/api/1/content/

Get information about a content (aka a "blob") object

/api/1/content/raw/

Get the raw content of a content object (aka a "blob"), as a byte sequence.

/api/1/directory/

Get information about directory objects

/api/1/known/

Check if a list of objects are present in the Software Heritage archive

/api/1/origin/

Get information about a software origin.

/api/1/origin/search/

Search for software origins whose urls contain a provided string pattern

/api/1/origin/visit/

Get information about a specific visit of a software origin.

/api/1/origin/visit/latest/

Get information about the latest visit of a software origin.

/api/1/origin/visits/

Get information about all visits of a software origin

/api/1/origins/

Get list of archived software origins

/api/1/raw/

Get the object corresponding to the SWHID in raw form

/api/1/release/

Get information about a release in the archive

/api/1/resolve/

Resolve a SoftWare Hash IDentifier (SWHID)

/api/1/revision/

Get information about a revision in the archive

/api/1/revision/directory/

Get information about directory (entry) objects associated to revisions

/api/1/revision/log/

Get a list of all revisions heading to a given one, in other words show the commit log

/api/1/snapshot/

Get information about a snapshot in the archive

Batch download

EndpointDescription
/api/1/vault/directory/ (deprecated)

This endpoint was replaced by /api/1/vault/flat/

/api/1/vault/flat/

Request the cooking of a simple archive, typically for a directory

/api/1/vault/flat/raw/

Fetch the cooked archive for a flat bundle

/api/1/vault/git-bare/

Request the cooking of a git-bare archive or check its cooking status

/api/1/vault/git-bare/raw/

Fetch the cooked git-bare archive for a revision

/api/1/vault/gitfast/

Request the cooking of a gitfast archive for a revision or check its cooking status

/api/1/vault/gitfast/raw/

Fetch the cooked gitfast archive for a revision

/api/1/vault/revision/gitfast/ (deprecated)

This endpoint was replaced by /api/1/vault/gitfast/

External IDentifiers

EndpointDescription
/api/1/extid/

Get information about an external identifier

/api/1/extid/target/

Get information about external identifiers targeting an archived object

Metadata

EndpointDescription
/api/1/content/filetype/

Get information about the detected MIME type of a content object.

/api/1/content/language/

Get information about the programming language used in a content object

/api/1/content/license/

Get information about the license of a content object.

/api/1/extrinsic-metadata/origin/

Get extrinsic metadata of a software origin (as a JSON-LD/CodeMeta dictionary).

/api/1/intrinsic-metadata/origin/

Get intrinsic metadata of a software origin (as a JSON-LD/CodeMeta dictionary).

/api/1/origin/intrinsic-metadata/ (deprecated)

This route is deprecated; use /api/1/intrinsic-metadata/origin/ instead

/api/1/origin/metadata-search/

Search for software origins whose metadata (expressed as a JSON-LD/CodeMeta dictionary) match the provided criteria

/api/1/raw-extrinsic-metadata/origin/authorities/

Similar to /api/1/raw-extrinsic-metadata/swhid/authorities/ but to get metadata on origins instead of objects

/api/1/raw-extrinsic-metadata/swhid/

Returns raw extrinsic metadata collected on a given object.

/api/1/raw-extrinsic-metadata/swhid/authorities/

Returns a list of metadata authorities that provided metadata on the given target

/api/1/raw-intrinsic-metadata/citation/origin/

Get a software citation, given a format and a software origin

/api/1/raw-intrinsic-metadata/citation/swhid/

Get a software citation, given an object SWHID and a format.

/api/1/revision/vulnerabilities/

Get known vulnerabilities affecting the revision identified by sha1_git.

Provenance

EndpointDescription
/api/1/provenance/whereare/

Given a list of core SWHIDs return qualified SWHIDs with some provenance info

/api/1/provenance/whereis/

Given a core SWHID return a qualified SWHID with some provenance info:

Request archival

EndpointDescription
/api/1/add-forge/request/create

Create a new request to add a forge to the list of those crawled regularly by Software Heritage

/api/1/add-forge/request/get

Return all details about an add-forge request.

/api/1/add-forge/request/list

List add forge requests submitted by users.

/api/1/origin/save/

Request the saving of a software origin into the archive or check the status of previously created save requests

/api/1/origin/save/bulk/

Request the saving of multiple software origins into the archive

/api/1/origin/save/bulk/request/

Get feedback about loading statuses of origins submitted through a save bulk request

/api/1/origin/save/bulk/requests/

List previously submitted save bulk requests

/api/1/origin/save/webhook/bitbucket/

Webhook receiver for Bitbucket to request or update the archival of a repository when new commits are pushed to it

/api/1/origin/save/webhook/forgejo/

Webhook receiver for Forgejo to request or update the archival of a repository when new commits are pushed to it

/api/1/origin/save/webhook/gitea/

Webhook receiver for Gitea to request or update the archival of a repository when new commits are pushed to it

/api/1/origin/save/webhook/github/

Webhook receiver for GitHub to request or update the archival of a repository when new commits are pushed to it

/api/1/origin/save/webhook/gitlab/

Webhook receiver for GitLab to request or update the archival of a repository when new commits are pushed to it

/api/1/origin/save/webhook/gogs/

Webhook receiver for Gogs to request or update the archival of a repository when new commits are pushed to it

/api/1/origin/save/webhook/sourceforge/

Webhook receiver for SourceForge to request or update the archival of a repository when new commits are pushed to it

Miscellaneous

EndpointDescription
/api/1/graph/

Provide fast access to the graph representation of the Software Heritage archive

/api/1/ping/

A simple endpoint used to check if the API is working.

/api/1/stat/counters/

Get statistics about the content of the archive.

back to top

Software Heritage — Copyright (C) 2015–2026, The Software Heritage developers. License: GNU AGPLv3+.
The source code of Software Heritage itself is available on our development forge.
The source code files archived by Software Heritage are available under their own copyright and licenses.
Terms of use: Archive access, API— Content policy— Contact— JavaScript license information— Web API