feat(wallet): unified GET /wallet/heights (tip per chain)

The wallet's ChainProvider seam fetches all chain tips in one call
(getBlockchainHeights) and selects per asset; the backend exposed per-chain
height endpoints but no aggregate, so the client's call 404'd. Add a
best-effort /wallet/heights returning {btc,ltc,xmr,wow,grin} concurrently — a
disabled or unreachable chain is null, never failing the others. JWT-gated,
OpenAPI-annotated (drift clean).
This commit is contained in:
jwinterm
2026-06-28 22:01:14 -04:00
parent 56c8dd463a
commit ff89ca6584
4 changed files with 173 additions and 0 deletions
+2
View File
@@ -58,6 +58,7 @@ use utoipa::OpenApi;
crate::api::wallet::grin_relay::respond,
crate::api::wallet::grin_relay::finalize,
crate::api::wallet::grin_relay::cancel,
crate::api::wallet::heights::heights,
crate::api::nip05::well_known_nostr,
),
components(schemas(
@@ -132,6 +133,7 @@ use utoipa::OpenApi;
crate::api::wallet::grin_relay::SlateIdRequest,
crate::api::wallet::grin_relay::RelayEntry,
crate::api::wallet::grin_relay::PendingRelaysResponse,
crate::api::wallet::heights::HeightsResponse,
crate::api::nip05::WellKnownResponse,
)),
tags(