Use cases
Release / commit signingLink to this section
Give every tagged release a Stamp envelope committed to the release artifact. Anyone downloading later can verify both authorship (signer's Bitcoin address) and priority (Bitcoin block at time of release).
npm i -g @orangecheck/stamp-cli
tar czf release.tar.gz ./dist/
# Shows the id, asks for your wallet's BIP-322 signature of it, writes
# release.tar.gz.stamp with a pending anchor.
stamp file release.tar.gz --addr bc1qalice...
git tag v1.2.3 -m "v1.2.3 release"
# An hour or more later, upgrade the pending anchor in place:
stamp anchor release.tar.gz.stamp
git-stamp tag v1.2.3 --addr bc1qalice... does the same for the tag itself and
writes .git/stamps/v1.2.3.stamp. Distribute release.tar.gz and
release.tar.gz.stamp together. Downstream consumers:
stamp verify release.tar.gz.stamp release.tar.gz --require-anchor
# ok: true
# id: 946fa89b…
# signer: bc1qalice...
# signed_at: 2026-04-24T06:47:00Z
# …
# content_checked: true
# anchor: confirmed at block 890123 (checked against the block header)
# signature_checked: true
The exit code is 2 if the signature, the bytes or the anchor do not check out,
and 1 if the file is not a stamp envelope at all (it names the field). With
--require-anchor it is 3 if the block header could not be read: nothing
failed, so run it again later (stamp-cli 0.3.0 and later).
Better than PGP keysigning because there's no keyserver rot — the Bitcoin address is the canonical identifier, checkable forever.
Long-form publishingLink to this section
Writer publishes an article at time T. Wants later-provable "I wrote this before X happened" without relying on a centralized blog platform or social-media timestamp.
import { readFile, writeFile } from 'node:fs/promises';
import { stamp } from '@orangecheck/stamp-core';
import {
fromStampOts,
mempoolHeaderSource,
submitToCalendars,
toStampOts,
upgradeProof,
} from '@orangecheck/stamp-ots';
declare const writerAddress: string;
declare function walletSign(message: string): Promise<string>; // your wallet's BIP-322 signer
const article = await readFile('./post.md');
const env = await stamp({
content: article,
mime: 'text/markdown',
signer: { address: writerAddress, signMessage: walletSign },
});
const anchored = { ...env, ots: toStampOts(await submitToCalendars(env.id)) };
await writeFile('./post.md.stamp', JSON.stringify(anchored));
// An hour or more later:
const proof = await upgradeProof(fromStampOts(anchored.ots), anchored.id, {
headerSource: mempoolHeaderSource(),
});
await writeFile(
'./post.md.stamp',
JSON.stringify({ ...anchored, ots: toStampOts(proof) })
);
Publish the article wherever (RSS, IPFS, Substack, personal blog). The .stamp
file is a separate self-contained proof that anyone can check against the
content. No reliance on the hosting platform.
Legal self-notarizationLink to this section
An agreement between two parties. Both sign the same content. Both stamps anchor to Bitcoin within the same window. No notary, no centralized service.
import { stamp } from '@orangecheck/stamp-core';
import { submitToCalendars, toStampOts } from '@orangecheck/stamp-ots';
type Wallet = { sign: (message: string) => Promise<string> }; // a BIP-322 signer
declare const agreementBytes: Uint8Array; // agreement.pdf
declare const aliceAddr: string, aliceWallet: Wallet;
declare const bobAddr: string, bobWallet: Wallet;
// Alice signs
const aliceStamp = await stamp({
content: agreementBytes,
mime: 'application/pdf',
signer: { address: aliceAddr, signMessage: aliceWallet.sign },
});
// Bob signs the same content
const bobStamp = await stamp({
content: agreementBytes,
mime: 'application/pdf',
signer: { address: bobAddr, signMessage: bobWallet.sign },
});
// Both anchor
const alice = {
...aliceStamp,
ots: toStampOts(await submitToCalendars(aliceStamp.id)),
};
const bob = {
...bobStamp,
ots: toStampOts(await submitToCalendars(bobStamp.id)),
};
// Store: agreement.pdf + alice.stamp + bob.stamp
console.log(alice.content.hash === bob.content.hash); // true: the same bytes
A third party verifying both stamps knows:
- Both addresses signed the same content (content hashes match).
- Both signings predate the anchor block.
- Neither party can later deny their signature (it's cryptographic).
If jurisdictional enforcement matters, this is the proof layer — you still need a legal framework that accepts cryptographic evidence.
DAO proposal authorshipLink to this section
DAO proposals are often submitted via a wallet that's not the proposer's actual identity (e.g., a multisig, a delegate wallet). Stamp separates proposer-identity from submitter-identity:
import { stamp } from '@orangecheck/stamp-core';
declare const proposalBytes: Uint8Array;
declare const proposerAddr: string;
declare const proposerWallet: { sign: (message: string) => Promise<string> };
// Proposer signs the proposal content
const proposalStamp = await stamp({
content: proposalBytes,
mime: 'text/markdown',
signer: { address: proposerAddr, signMessage: proposerWallet.sign },
});
// Then whoever has submit rights posts the proposal + the stamp on-chain
Voters verifying the proposal see both the on-chain submitter AND the cryptographic authorship chain back to the proposer's Bitcoin address.
Sybil-gated content feedsLink to this section
Embed an OC Attest reference in every Stamp envelope. Feed aggregators can then filter posts by signer stake:
import type { StampEnvelope } from '@orangecheck/stamp-core';
import { verifySignature } from '@orangecheck/bip322';
import { checkStake, parseStamp, stamp, verify } from '@orangecheck/stamp-core';
declare const postBytes: Uint8Array, authorAddr: string;
declare const authorWallet: { sign: (message: string) => Promise<string> };
declare const authorAttestationId: string; // the author's OC Attest id
declare const feed: { content: string; bytes: Uint8Array }[]; // incoming posts
declare function showPost(env: StampEnvelope, bytes: Uint8Array): void;
const post = await stamp({
content: postBytes,
mime: 'text/markdown',
signer: { address: authorAddr, signMessage: authorWallet.sign },
// Self-declared and unsigned; the aggregator re-checks it.
stake: {
attestation_id: authorAttestationId,
sats_bonded: 500_000,
days_unspent: 180,
},
});
// Aggregator:
for (const incoming of feed) {
// From the network, so parse it at the edge: parseStamp throws StampError
// (E_MALFORMED) for anything that is not an envelope.
let env;
try {
env = parseStamp(incoming.content);
} catch {
continue;
}
const r = await verify({
envelope: env,
content: incoming.bytes,
verifyBip322: async (msg, sig, addr) => verifySignature(addr, msg, sig),
});
if (!r.ok || !env.stake) continue;
const att = await fetch(
`https://attest.ochk.io/api/check?id=${env.stake.attestation_id}`
).then((res) => res.json());
// Only the signer's own attestation counts, at its current bond.
if (
checkStake(env, att.ok ? att : null, { minSats: 100_000, minDays: 30 })
.ok
) {
showPost(env, incoming.bytes);
}
}
Low-stake posts filter out at the firehose level; high-stake posts get shown. Combines the authorship + timestamp guarantees of Stamp with the sybil-resistance of Attest.
When Stamp is NOT the right toolLink to this section
- You need privacy. Stamp envelopes are public, anchored to a public chain. Use authenticated encryption (OC Lock) instead.
- You need continuous signing (streaming logs, per-keystroke provenance). Stamp is one-envelope-per-event; wrong granularity.
- You need proof-of-delivery. Stamp proves "this was signed before X"; it doesn't prove "this was seen by Y." Separate concerns.
See alsoLink to this section
- How it works — the sign + anchor flow
- OpenTimestamps anchor — the anchor step in detail
- OC Attest reference — the attestation a
stakefield points at