Skip to content

feat: hpphub topup setup — one-command credit auto-top-up - #3

Closed
nolnol3 wants to merge 5 commits into
mainfrom
feat/topup-setup
Closed

nolnol3 wants to merge 5 commits into
mainfrom
feat/topup-setup

Conversation

@nolnol3

@nolnol3 nolnol3 commented Jun 9, 2026

Copy link
Copy Markdown
Member

Refs #2 — testnet (HPP Sepolia) implementation. #2 stays open until mainnet infra is configured and verified.

Adds hpphub topup setup so enabling x402 credit auto-top-up is a single command for logged-in users, plus hpphub topup status to verify the wiring.

  • topup setup — writes the local policy + registers the bridge in the OpenClaw config from the existing login (no manual config editing). Resolves the delegate payment key (keep existing / import / generate). --enable-auto opts into periodic auto-top-up; --dry-run previews; re-runs are idempotent.
  • topup status — checks login, delegate key, Hub endpoint, on-chain balance, and gateway.
  • Network overrides — rpc / network / usdce / allowance are flag-overridable; defaults are HPP Sepolia (named mainnet preset is a follow-up).

Verified on testnet: build/vet, dry-run config generation, and a clean-room Docker run (install → setup → real on-chain top-up on HPP Sepolia). Mainnet verification pending.

nolnol3 added 5 commits June 8, 2026 19:41
Configures x402 credit auto-top-up from the user's existing login, so enabling
it no longer requires hand-editing config files:
- writes the local policy entry (auth header derived from the login)
- registers the bridge in the OpenClaw config (reusing any existing values)
- --enable-auto opts into periodic auto-top-up
- --dry-run previews; re-runs are idempotent

Remaining one-time on-chain wallet steps are printed as guidance.

Closes #2
…guidance

Empty optionals are dropped from the bridge env (an empty string fails the
bridge's validation; RESOURCE_SERVER_URL is optional now). Guidance covers
both direct-funded delegate and Safe-allowance options.
setup now ensures the delegate payment key (generates it in the OS keychain
via the bridge tool when missing) and surfaces its address for funding,
instead of leaving it to manual steps. Adds 'hpphub topup status' to verify
the wiring: login, delegate key, Hub credit endpoint, on-chain delegate
balance, and gateway health.
…ys generating

If a delegate key already exists, keep it (Enter) or paste a different
0x key to replace; if none, generate (Enter) or paste a key to import.
Non-interactive (piped/CI) keeps existing, else generates. Key is entered
via prompt/stdin, never argv.
All network params (rpc/network/usdce/allowance) are now flag-overridable, so
non-Sepolia networks work without code changes. Defaults stay HPP Sepolia;
named mainnet preset is a follow-up (mainnet not yet deployed).
@nolnol3

nolnol3 commented Jun 9, 2026

Copy link
Copy Markdown
Member Author

실수 머지 방지로 닫음 — 메인넷 인프라 구성 + 검증 후 (draft로) 재오픈 예정. 브랜치 feat/topup-setup 보존, 작업 손실 없음.

@nolnol3 nolnol3 closed this Jun 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant