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.
Relates to: N/A
Risks
Low. Only agents with this plugin enabled would be affected.
Background
What does this PR do?
Replaces the old not-quite-working Starknet wallet provider with a new (more aptly named) portfolio provider. Also cleans up some of the Starknet plugin code.
What kind of change is this?
Feature + refactor.
Why are we doing this? Any context or related work?
The old Starknet walletProvider.ts was based on the Solana one, but wasn't fully functioning. This new one is.
Because there's no free API that returns the whole portfolio of a wallet for Starknet, I'm using a whitelist of tokens (
PORTFOLIO_TOKENS
) and Coingecko API to get the USD prices. An alternative would be to use BlastAPI's Builder API -> getWalletTokenBalances but that would require additional setup (Blast API key).The output of the new plugin is sth like this:
Documentation changes needed?
None that I'm aware of since there's no docs for this plugin.
Testing
Where should a reviewer start?
Detailed testing steps
None, automtated tests are fine.
Discord username
milan3774