@infantmen-labs/harbor-sdk 0.7.0 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +36 -3
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# harbor-sdk
|
|
1
|
+
# @infantmen-labs/harbor-sdk
|
|
2
2
|
|
|
3
3
|
TypeScript SDK for Harbor bonded refunds on Solana: PDA helpers,
|
|
4
4
|
instruction builders, receipt codec, ed25519 verify, account decoders.
|
|
@@ -28,8 +28,9 @@ const ok = verifyEd25519(signer, receiptMessageBytes(receipt), signature);
|
|
|
28
28
|
|
|
29
29
|
What it covers: `bondPda` / `bindingPda` / `disputePda` / `receiptPda` /
|
|
30
30
|
`treasuryPda` / `claimPda`, instruction builders for all 11 program
|
|
31
|
-
entrypoints, the
|
|
32
|
-
|
|
31
|
+
entrypoints, the receipt-v1 layout (249 bytes; `mint` + `programId`
|
|
32
|
+
domain separators appended — all v0 offsets unchanged), voucher bytes,
|
|
33
|
+
and zero-dependency account decoders. See `examples/bond-watch` for a
|
|
33
34
|
complete third-party monitor built on SDK + web3.js only.
|
|
34
35
|
|
|
35
36
|
## Buyer patterns (demand-side integration)
|
|
@@ -56,3 +57,35 @@ The proven demand-side flow:
|
|
|
56
57
|
4. **Resolve via any live keeper.** Any keeper watching the program
|
|
57
58
|
resolves matured disputes; verify onchain (dispute account closed,
|
|
58
59
|
claimant +95%). Operate your own for production (see keeper README).
|
|
60
|
+
|
|
61
|
+
## Live devnet endpoints
|
|
62
|
+
|
|
63
|
+
All on Solana devnet, live today — the docs site exposes the demo
|
|
64
|
+
merchant at its own /api (see harbor-orch.vercel.app/docs):
|
|
65
|
+
|
|
66
|
+
| What | Address |
|
|
67
|
+
|---|---|
|
|
68
|
+
| Harbor program | BuRyKLqCsTLcyLVFEjxTjmF4DryCT3LmVDjwqhduvB4H |
|
|
69
|
+
| Channels program | CHNLxYvVA28MJP9PrFuDXccuoGXAx7jBacfLEkahyGsX |
|
|
70
|
+
| tUSDC mint | HDwpthFfTBi4YyGo1zgd7zxyonE5CZsCizpVqURHGD54 |
|
|
71
|
+
| Demo merchant | GQyf8wvGfpaLZvfvbXonpdiEfAGRvRXz2P6PkWxQ4rLJ |
|
|
72
|
+
| Demo bond | 2G19xBTWXTYM8y6rQCs9ucMkQr36RDX1FucMf22jFLuP |
|
|
73
|
+
|
|
74
|
+
Devnet tUSDC for testing: POST https://harbor-orch.vercel.app/api/faucet
|
|
75
|
+
with {"address":"<wallet>"} — 50 per drip, 100 lifetime per address,
|
|
76
|
+
5/day per IP (the mint is closed, so this spends a funded pot).
|
|
77
|
+
|
|
78
|
+
## Receipt v1 migration (from 0.4.x)
|
|
79
|
+
|
|
80
|
+
receiptMessageBytes now requires two extra fields — mint and programId —
|
|
81
|
+
appended after signer (249 bytes total; every v0 offset unchanged).
|
|
82
|
+
Verification of a v0 receipt fails against the deployed v1 program by
|
|
83
|
+
construction, so migrate when you upgrade. Full layout:
|
|
84
|
+
docs/receipt-schema-v1.md in the repo.
|
|
85
|
+
|
|
86
|
+
## Docs
|
|
87
|
+
|
|
88
|
+
- Repo: https://github.com/infantmen-labs/harbor
|
|
89
|
+
- Buyer quickstart + live endpoints: docs/buyer-quickstart.md (repo)
|
|
90
|
+
- On-site integration guide: https://harbor-orch.vercel.app/docs
|
|
91
|
+
- Proof bundle (every claim explorer-clickable): docs/proof-bundle.md (repo)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@infantmen-labs/harbor-sdk",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.1",
|
|
4
4
|
"description": "TypeScript SDK for Harbor bonded refunds on Solana: PDA helpers, instruction builders, receipt codec, ed25519 verify, account decoders.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"keywords": [
|
|
@@ -11,7 +11,8 @@
|
|
|
11
11
|
"anchor"
|
|
12
12
|
],
|
|
13
13
|
"files": [
|
|
14
|
-
"dist"
|
|
14
|
+
"dist",
|
|
15
|
+
"README.md"
|
|
15
16
|
],
|
|
16
17
|
"main": "dist/src/index.js",
|
|
17
18
|
"types": "dist/src/index.d.ts",
|