Installation & Setup
PIERRE_ORG and PIERRE_PRIVATE_KEY as shown in the
Quick Start. Pass them to the
client:
store.createRepo() or store.findOne() to get a repo object. store.findOne() returns
null if the repository does not exist.
In Go, import os to read the environment variables. SDK calls take a context.Context, and TTL
values are time.Duration (for example time.Hour).
Need to create a JWT without an SDK client? See Authentication → How to sign a JWT.
Token signing
The Python package exportsgenerate_jwt for code that needs a token without a GitStorage client.
The helper selects ES256 or RS256 from the key type.
Python
Error Handling
The SDK surfaces API failures asApiError and ref update failures as RefUpdateError.
Methods
Each method of the earlier SDK has its own page.Client methods
store.createGitCredential()store.createRepo()store.deleteGitCredential()store.deleteRepo()store.findOne()store.listRepos()store.updateGitCredential()
Repository methods
repo.appendNote()repo.createBranch()repo.createCommit()repo.createCommitFromDiff()repo.createNote()repo.createTag()repo.deleteBranch()repo.deleteNote()repo.deleteTag()repo.getArchiveStream()repo.getBlame()repo.getBranchDiff()repo.getCommit()repo.getCommitDiff()repo.getEphemeralRemoteURL()repo.getFileStream()repo.getImportRemoteURL()repo.getNote()repo.getRemoteURL()repo.grep()repo.headFile()repo.listBranches()repo.listCommits()repo.listFiles()repo.listFilesWithMetadata()repo.listTags()repo.merge()repo.previewMerge()repo.pullUpstream()repo.restoreCommit()