fix: auth, wallet linking, Luca chat, and stablecoin USD pricing#217
Open
danbuildss wants to merge 1 commit into
Open
fix: auth, wallet linking, Luca chat, and stablecoin USD pricing#217danbuildss wants to merge 1 commit into
danbuildss wants to merge 1 commit into
Conversation
Both Alchemy and Etherscan providers were setting valueUsd: undefined, causing all financial intelligence snapshots to show $0 metrics. Add usd-pricer.ts that computes USD value for known stablecoins (USDC, USDT, DAI across Base/Ethereum/Arbitrum/Optimism/Polygon) by dividing rawValue by 10^decimals. Non-stablecoin assets remain undefined until a price oracle is wired up. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RjpGP3kYKnQuQAUoK6RZky
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
privy:<id>strings were being written toaccess_codes(UUID primary key) — silently failing for all Privy-authenticated users. Added routing to theuserstable (text PK) in/api/accessand/api/user/wallet./api/user/wallet— added it.@AskLucaBotvia the Hermes API (HERMES_API_URL+HERMES_API_KEYenv vars). Consistent with the Telegram bot.@AskLucaBot(not the community group@asklucaai).valueUsd: undefinedhardcoded. Addedusd-pricer.tsthat prices USDC/USDT/DAI across Base/Ethereum/Arbitrum/Optimism/Polygon deterministically (1:1 peg, raw value ÷ 10^decimals). Fixes financial intelligence snapshots always returning $0.Before merging
Run this in Supabase SQL editor if the
userstable doesn't exist yet:(Skip the policy line if it already exists.)
After merging
Re-index Skopos wallets then re-run the financial intelligence process endpoint to get real USD metrics from stablecoin transactions.
Generated by Claude Code