-
Notifications
You must be signed in to change notification settings - Fork 542
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding Para pregenerated wallet #303
base: main
Are you sure you want to change the base?
Conversation
Added Para SDK integration with the following features: - Create pre-generated wallets - Get pre-generated wallets - Update pre-generated wallets - Added necessary environment variables - Updated package dependencies
Changes: - Added useParaPregenWallet action and tool - Modified Para integration files - Updated package dependencies
Changes: - Added deactivateParaPregenWallet and claimParaPregenWallet actions - Updated agent methods to support new Para wallet management features - Modified import and export statements in relevant files - Updated action and tool implementations for new wallet operations
Changes: - Refactored createParaPregenWallet to remove agent-specific userShare mapping - Updated useParaPregenWallet to accept userShare instead of email - Modified action and tool schemas to use userShare - Removed unnecessary agent method modifications - Updated input handling in Para-related tools and actions
Removes previously added claimParaPregenWallet action, tool, and related methods across multiple files. This appears to be a cleanup of an unused or deprecated feature in the Para wallet management integration.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please run the lint command so that files can be properly formatted
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
@@ -0,0 +1,48 @@ | |||
import { Para as ParaServer, Environment, WalletType } from "@getpara/server-sdk"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please verify that the server sdk works in the browser as well as some people might want to use the Solana Agent kit in React, Solidjs or vanilla JS in the browser
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will end up not being compatible with V2. Is there a more modular way to do this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i saw the v2 and its actually what im looking for, i actually overriding the sendTransaction method of solanaAgentKit.connection.sendTransaction and i think its too hacky and now that you make sendTransaction modular it is much more better i will check em out and see what i can do, but it actually pretty compatible i can make it modular
Removes deactivateParaPregenWallet functionality and replaces it with switchParaToMainWallet across multiple files. This refactoring simplifies the Para wallet management flow and provides a more semantically clear method for transitioning wallet contexts.
Pull Request Description
This PR adds integrate Para SDK to create, retrieve, update and use para pregenerated wallet with solana agent kit
Related Issue
Fixes # (issue number)
Changes Made
Implementation Details
Transaction executed by agent
Example transaction:
The prompt:
https://explorer.solana.com/tx/vpajh3Swtb9qPhEVq7mnu6hUFoFTZuhVbPi25RADTmkMW2ZvYgxnkdGgvHvDZpjrHLPTcPhU8XN79cKjvTcqBsS?cluster=devnet
Prompt Used
Additional Notes
This integration requires the PARA_API_KEY environment variable to be properly configured. The functionality allows for creating, retrieving, updating, and using Para pre-generated wallets, enhancing the wallet management capabilities of the application. The github repo for the demo: https://github.com/uratmangun/agent-stdio
You can see the demo with client MCP server here:

Checklist