feat: expose commit signature and payload on getCommit#32
Merged
Conversation
The GET /repos/commit endpoint now returns optional `signature` (armored OpenPGP/SSH block from the commit's gpgsig header) and `payload` (the exact signed bytes) fields for signed commits. Surface them across all three SDKs via a new CommitInfoWithSignature type; both are absent for unsigned commits. Bumps minor versions: Go 0.9.0 -> 0.10.0, Python 1.10.0 -> 1.11.0, TypeScript 1.9.0 -> 1.10.0.
…CommitInfo Avoid the source-breaking change of swapping GetCommitResult.Commit's type (Go consumers using the field as a CommitInfo value would no longer compile). Instead add optional signature/payload directly onto CommitInfo and revert GetCommitResult to hold a plain CommitInfo, dropping CommitInfoWithSignature. The fields are populated only by getCommit for signed commits and remain empty/undefined/absent everywhere else, so the change is purely additive in all three SDKs.
Expose the new `verify-sig` push policy op (OpVerifySig / OP_VERIFY_SIG) alongside no-push / no-force-push so callers can require signed commits on matching refs when minting JWTs / remote URLs. Ops pass through to the refs claim unchanged. Adds per-language tests and documents the op in SKILL.md.
unknwon
commented
Jun 3, 2026
| Size int64 `json:"size"` | ||
| LastCommitSHA string `json:"last_commit_sha"` | ||
| Type string `json:"type,omitempty"` | ||
| Type string `json:"type"` |
Contributor
Author
There was a problem hiding this comment.
omitempty is redundant on the unmarshalling side
evict
approved these changes
Jun 3, 2026
Contributor
Author
|
Merging as-is, happy to address post-merge feedback! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Surfaces the new commit-signature verification feature in all three SDKs.
1.
verify-sigref-policy opAdds the new push policy op alongside
no-push/no-force-push, so callers can require that every commit introduced to a matching ref carries a valid signature from a signing key registered for the tenant:storage.OpVerifySigOP_VERIFY_SIGOP_VERIFY_SIGUsed like the other ops in
refPolicieswhen minting JWTs / remote URLs; the op passes through to the JWTrefsclaim unchanged.2. Signature/payload on
getCommitGET /repos/commitnow returns two optional fields for signed commits:signature— the armored OpenPGP/SSH block from the commit'sgpgsigheaderpayload— the exact signed bytes (raw commit object with thegpgsigheader removed)These are exposed as optional fields on the existing
CommitInfotype (not a type swap onGetCommitResult.commit), so the change is purely additive / non-breaking in all three SDKs. They are populated only bygetCommitfor signed commits and are empty/undefined/absent otherwise.Version bumps (minor)
code-storage-go)pierre-storage)@pierre/storage)Docs updated:
skills/code-storage/SKILL.md(ops table + response shape) and TS/Python READMEs.Test plan
All 3 SDKs tested e2e against locally running servers.