Quickstart
Pick the integration shape that matches your stack. All four below are equivalent — same decision, same data source.
1. curl — no SDK
curl "https://ochk.io/api/check?addr=bc1q...&min_sats=100000&min_days=30"
Response:
{
"ok": true,
"sats": 125000,
"days": 47,
"score": 18.2,
"attestation_id": "a3f5b8c2…",
"identities": [
{ "protocol": "nostr", "identifier": "npub1alice…" },
{ "protocol": "github", "identifier": "alice" }
]
}
That's the whole API surface for most gates. Cached 60 seconds, free tier 60 req/min/IP.
2. TypeScript / Node
yarn add @orangecheck/sdk
import { check } from '@orangecheck/sdk';
const r = await check({
addr: 'bc1q...',
minSats: 100_000,
minDays: 30,
});
if (r.ok) {
// let them through
} else {
console.log('rejected:', r.reasons);
}
3. Python
pip install orangecheck
from orangecheck import check
r = check(addr="bc1q...", min_sats=100_000, min_days=30)
if r.ok:
... # let them through
else:
print("rejected:", r.reasons)
4. Express / Next / Fastify middleware
yarn add @orangecheck/gate
import { ocGate } from '@orangecheck/gate';
// Only users with ≥ 100k sats unspent for ≥ 30 days may post.
app.post(
'/post',
ocGate({
minSats: 100_000,
minDays: 30,
address: { from: 'header' }, // reads X-OC-Address
}),
postHandler,
);
When check() passes, req.orangecheck is populated with the full check result.
Test it live
Before writing any code, fire requests against the hosted API:
- Interactive playground — pick an endpoint, edit params, hit Run.
- Airdrop gate demo — paste candidate addresses, watch them filter live.
- Sign in with Bitcoin — end-to-end signed-challenge flow.
What to read next
- How it works — the three-step protocol in detail.
- API reference — every endpoint with full request/response schemas.
- Guides — working integrations you can clone for your stack.
A proof, once published, is offline-verifiable forever — or until you spend the bonded UTXOs.