Smart Wallet tools provide functionality for deploying, managing, and interacting with Smart Wallets, which are programmable wallets that can hold assets and interact with various contracts on the Stacks blockchain.
Tool Overview
Tool Name
Description
Key Features
smartwallet_deploy_smart_wallet
Deploy a new smart wallet
Owner assignment, DAO token linking
smartwallet_deposit_stx
Deposit STX to a smart wallet
Transaction creation, balance update
smartwallet_withdraw_stx
Withdraw STX from a smart wallet
Transaction creation, balance update
smartwallet_deposit_ft
Deposit fungible tokens to a smart wallet
Token transfers, balance update
smartwallet_withdraw_ft
Withdraw fungible tokens from a smart wallet
Token transfers, balance update
smartwallet_approve_asset
Approve an asset for use with the smart wallet
Asset authorization
smartwallet_revoke_asset
Revoke an asset from the smart wallet
Asset deauthorization
smartwallet_approve_dex
Approve a DEX for use with the smart wallet
DEX authorization
smartwallet_revoke_dex
Revoke a DEX from the smart wallet
DEX deauthorization
smartwallet_set_agent_can_buy_sell
Set whether agent can buy/sell assets
Permission management
smartwallet_buy_asset
Buy an asset from a DEX
Trading functionality
smartwallet_sell_asset
Sell an asset to a DEX
Trading functionality
smartwallet_proxy_propose_action
Propose an action to a DAO
Governance participation
smartwallet_proxy_create_proposal
Create a proposal in a DAO
Governance participation
smartwallet_vote_on_action_proposal
Vote on an action proposal
Governance participation
smartwallet_vote_on_core_proposal
Vote on a core proposal
Governance participation
smartwallet_conclude_action_proposal
Conclude an action proposal
Governance participation
smartwallet_conclude_core_proposal
Conclude a core proposal
Governance participation
smartwallet_get_balance_stx
Get the STX balance from a smart wallet
Current balance
smartwallet_is_approved_asset
Check if an asset is approved in the smart wallet
Asset status
smartwallet_is_approved_dex
Check if a DEX is approved in the smart wallet
DEX status
smartwallet_get_configuration
Get the configuration of a smart wallet
Comprehensive wallet info
Tool Details
smartwallet_deploy_smart_wallet
Deploys a new smart wallet for a user.
Input Parameters:
owner_address: Stacks address of the wallet owner
agent_address: Stacks address of the agent
dao_token_contract: Contract principal of the DAO token
dao_token_dex_contract (optional): Contract principal of the DAO token DEX
Deploy a new smart wallet with the following details:
- owner_address: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM
- agent_address: ST2CY5V39NHDPWSXMW9QDT3HC3GD6Q6XX4CFRK9AG
- dao_token_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
- dao_token_dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
smartwallet_deposit_stx
Deposits STX into a smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
Deposit STX to a smart wallet with the following details:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- amount: 1000000
smartwallet_withdraw_stx
Withdraws STX from a smart wallet. Only the owner can withdraw.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
Withdraw STX from a smart wallet with the following details:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- amount: 1000000
smartwallet_deposit_ft
Deposits fungible tokens into a smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
ft_contract: Contract principal of the fungible token
Deposit fungible tokens to a smart wallet with the following details:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- ft_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
- amount: 100
smartwallet_withdraw_ft
Withdraws fungible tokens from a smart wallet. Only the owner can withdraw.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
ft_contract: Contract principal of the fungible token
Withdraw fungible tokens from a smart wallet with the following details:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- ft_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
- amount: 100
smartwallet_approve_asset
Approves an asset for use with the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
asset_contract: Contract principal of the asset to approve
Approve an asset for use with the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
smartwallet_revoke_asset
Revokes an asset from the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
asset_contract: Contract principal of the asset to revoke
Revoke an asset from the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
smartwallet_approve_dex
Approves a DEX for use with the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
dex_contract: Contract principal of the DEX to approve
Approve a DEX for use with the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
smartwallet_revoke_dex
Revokes a DEX from the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
dex_contract: Contract principal of the DEX to revoke
Revoke a DEX from the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
smartwallet_set_agent_can_buy_sell
Sets whether the agent can buy/sell assets through the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
can_buy_sell: Boolean indicating whether the agent can buy/sell (true/false)
Set whether the agent can buy/sell assets through the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- can_buy_sell: true
smartwallet_buy_asset
Buys an asset from a DEX through the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
dex_contract: Contract principal of the DEX
asset_contract: Contract principal of the asset to buy
Buy an asset from a DEX through the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
- amount: 100
smartwallet_sell_asset
Sells an asset to a DEX through the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
dex_contract: Contract principal of the DEX
asset_contract: Contract principal of the asset to sell
Sell an asset to a DEX through the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
- amount: 100
smartwallet_proxy_propose_action
Proposes an action to a DAO through the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
action_proposals_contract: Contract principal of the action proposals extension
action_contract: Contract principal of the action to propose
parameters: Parameters for the action (format depends on the action)
Propose an action to a DAO through the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- action_proposals_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-action-proposals-v2
- action_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-action-send-message
- parameters: "Hello, DAO!"
smartwallet_proxy_create_proposal
Creates a proposal in a DAO through the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
core_proposals_contract: Contract principal of the core proposals extension
proposal_contract: Contract principal of the proposal to create
dao_token_contract: Contract principal of the DAO token
Create a proposal in a DAO through the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- core_proposals_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-core-proposals-v2
- proposal_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.proposal-add-extension
- dao_token_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
smartwallet_vote_on_action_proposal
Votes on an action proposal through the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
action_proposals_contract: Contract principal of the action proposals extension
proposal_id: ID of the proposal to vote on
vote: Boolean indicating vote (true for yes, false for no)
Check if an asset is approved in the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
smartwallet_is_approved_dex
Checks if a specific DEX is approved in the smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
dex_contract: Contract principal of the DEX to check
Check if a DEX is approved in the smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
smartwallet_get_configuration
Gets the configuration of a smart wallet.
Input Parameters:
smart_wallet_contract: Contract principal of the smart wallet
Get the configuration of a smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
Smart Wallet Workflow Examples
Asset Management Workflow
Deploy a new smart wallet
Deploy a new smart wallet with the following details:
- owner_address: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM
- agent_address: ST2CY5V39NHDPWSXMW9QDT3HC3GD6Q6XX4CFRK9AG
- dao_token_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
- dao_token_dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
Deposit STX to the smart wallet
Deposit STX to my smart wallet with the following details:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- amount: 1000000
Approve an asset for use with the smart wallet
Approve a token for use with my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
Check if an asset is approved
Check if the token is approved for my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
Get the smart wallet configuration
Get the configuration of my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
DEX Trading Workflow
Approve a DEX for trading
Approve a DEX for use with my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
Allow agent to buy/sell assets
Allow my agent to buy/sell assets through my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- can_buy_sell: true
Buy tokens from the DEX
Buy tokens from the DEX through my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
- amount: 100
Sell tokens to the DEX
Sell tokens to the DEX through my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- dex_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token-dex
- asset_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
- amount: 50
DAO Governance Workflow
Propose an action to the DAO
Propose an action to the DAO through my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- action_proposals_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-action-proposals-v2
- action_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-action-send-message
- parameters: "Hello, DAO!"
Vote on an action proposal
Vote on an action proposal through my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- action_proposals_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-action-proposals-v2
- proposal_id: 123
- vote: true
Create a core proposal
Create a core proposal through my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- core_proposals_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-core-proposals-v2
- proposal_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.proposal-add-extension
- dao_token_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
Vote on a core proposal
Vote on a core proposal through my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- core_proposals_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-core-proposals-v2
- proposal_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.proposal-add-extension
- vote: true
Conclude a proposal
Conclude a core proposal through my smart wallet:
- smart_wallet_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-smart-wallet-ST1PQ-PGZGM-ST2CY-RK9AG
- core_proposals_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-core-proposals-v2
- proposal_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.proposal-add-extension
- dao_token_contract: ST1PQHQKV0RJXZFY1DGX8MNSNYVE3VGZJSRTPGZGM.aibtc-token
Error Handling
All Smart Wallet tools return standardized error responses when operations fail: