GetBlob
Returns the contents of a blob object referenced by its object ID. Uses streaming to return arbitrarily large binary responses in chunks.Request
The repository containing the blob
Object ID (SHA1) of the blob to retrieve
Maximum number of bytes to receive. Use -1 to get the full blob regardless of size. Default is 0.
Response (Stream)
Total blob size in bytes. Only present in the first response message.
Chunk of blob data
Object ID of the blob. Only present in the first response message. Empty if no blob was found.
Example
GetBlobs
Retrieves multiple blobs by revision/path pairs.Request
The repository containing the blobs
Array of revision/path pairs identifying the blobs to retrieve
The revision (commit, branch, tag) to retrieve the blob from
Path to the file within the revision
Maximum number of bytes to receive per blob. Use -1 for no limit.
Response (Stream)
Blob size. Only present on the first message per blob.
Chunk of blob data. May span multiple messages.
Object ID of the blob. Only present on the first message per blob. Empty if no blob was found.
Whether this is a submodule
File mode (e.g., 0644)
The revision this blob was retrieved from
The path this blob was retrieved from
The type of the object
Example
ListBlobs
Lists all blobs reachable from a given set of revisions by doing a graph walk.Request
The repository to enumerate blobs from
List of revisions to retrieve blobs from. Supports pseudo-revisions
--all and --not as well as negated revisions via ^revision. Must not be empty.Maximum number of blobs to return. If set to 0 (default), all found blobs will be returned.
Maximum number of bytes to receive for each blob. If set to 0, no blob data will be sent. If -1, all blob data will be sent without limits.
Whether paths of blobs should be returned on a best-effort basis. A path will only exist if the blob was traversed via a tree.
Response (Stream)
Array of blobs found. If blob contents exceed the maximum gRPC message size, the blob will be split across multiple responses.
Object ID of the blob. Only set for the first message of each specific blob.
Size of the blob in bytes. Only set for the first message of each specific blob.
Contents of the blob. Optional and depends on bytes_limit parameter.
Path of the blob. May be unset depending on how the blob was traversed.
Example
ListAllBlobs
Retrieves all blobs in the repository, including those not reachable by any reference.Request
The repository to enumerate blobs from
Maximum number of blobs to return. If set to 0 (default), all found blobs will be returned.
Maximum number of bytes to receive for each blob. If set to 0, no blob data will be sent. If -1, all blob data will be sent without limits.
Response (Stream)
Array of blobs found. If blob contents exceed the maximum gRPC message size, the blob will be split across multiple responses.
Object ID of the blob. Only set for the first message of each specific blob.
Size of the blob in bytes. Only set for the first message of each specific blob.
Contents of the blob. Optional and depends on bytes_limit parameter.
GetLFSPointers
Retrieves LFS pointers from a given set of object IDs. This RPC filters all requested objects and only returns those which refer to a valid LFS pointer.Request
The repository to retrieve LFS pointers from
List of blob IDs to check for LFS pointers. Must be non-empty.
Response
List of LFS pointers found
Size of the LFS pointer blob (not the size of the LFS object it points to)
Raw data of the LFS pointer blob in the format specified by the LFS project
Object ID of the blob
Example
ListLFSPointers
Retrieves LFS pointers reachable from a given set of revisions by doing a graph walk. This includes both normal revisions like an object ID or branch, but also the pseudo-revisions “—all” and “—not”. Revisions which don’t reference any LFS pointers are ignored.Request
The repository to retrieve LFS pointers from
List of revisions to retrieve LFS pointers from. Must be non-empty.
Maximum number of LFS pointers to return. 0 means no limit.
Response (Stream)
List of LFS pointers found
Size of the LFS pointer blob
Raw data of the LFS pointer blob
Object ID of the blob
Example
ListAllLFSPointers
Retrieves all LFS pointers in the repository, including those not reachable by any reference.Request
The repository to retrieve LFS pointers from
Maximum number of LFS pointers to return. 0 means no limit.
Response (Stream)
List of LFS pointers found
Size of the LFS pointer blob
Raw data of the LFS pointer blob
Object ID of the blob