Skip to content
This repository was archived by the owner on Mar 18, 2026. It is now read-only.

Commit 154bd09

Browse files
authored
Merge pull request #65 from aibtcdev/fix/rename-smart-wallet
Rename smart wallet
2 parents 33497d6 + 91f0cd1 commit 154bd09

File tree

6 files changed

+315
-315
lines changed

6 files changed

+315
-315
lines changed

Clarinet.toml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,15 +52,15 @@ path = 'contracts/aibtcdev-airdrop-2.clar'
5252
clarity_version = 2
5353
epoch = 3.0
5454

55-
# smart wallet and traits
55+
# agent account and traits
5656

57-
[contracts.aibtc-smart-wallet-traits]
58-
path = 'contracts/aibtc-smart-wallet-traits.clar'
57+
[contracts.aibtc-user-agent-account-traits]
58+
path = 'contracts/aibtc-user-agent-account-traits.clar'
5959
clarity_version = 3
6060
epoch = 3.1
6161

62-
[contracts.aibtc-user-agent-smart-wallet]
63-
path = 'contracts/aibtc-user-agent-smart-wallet.clar'
62+
[contracts.aibtc-user-agent-account]
63+
path = 'contracts/aibtc-user-agent-account.clar'
6464
clarity_version = 3
6565
epoch = 3.1
6666

contracts/aibtc-smart-wallet-traits.clar

Lines changed: 0 additions & 103 deletions
This file was deleted.

contracts/aibtc-smart-wallet-traits-v2.clar renamed to contracts/aibtc-user-agent-account-traits.clar

Lines changed: 26 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
;; title: aibtc-smart-wallet-traits
2-
;; version: 2.0.0
3-
;; summary: A collection of traits for user agent smart wallets.
1+
;; title: aibtc-user-agent-account-traits
2+
;; version: 1.0.0
3+
;; summary: A collection of traits for user agent accounts.
44

55
;; IMPORTS
66
(use-trait sip010-trait 'SP3FBR2AGK5H9QBDH3EEN6DF8EK8JY7RX8QJ5SVTE.sip-010-trait-ft-standard.sip-010-trait)
@@ -11,32 +11,32 @@
1111
(use-trait dao-faktory-dex .aibtc-dao-traits-v3.faktory-dex)
1212
(use-trait faktory-token .faktory-trait-v1.sip-010-trait)
1313

14-
;; SMART WALLET TRAITS
14+
;; ACCOUNT TRAITS
1515

16-
(define-trait aibtc-smart-wallet (
17-
;; deposit STX to the smart wallet
16+
(define-trait aibtc-account (
17+
;; deposit STX to the agent account
1818
;; @param amount amount of microSTX to deposit
1919
;; @returns (response bool uint)
2020
(deposit-stx (uint) (response bool uint))
21-
;; deposit FT to the smart wallet
21+
;; deposit FT to the agent account
2222
;; @param ft the fungible token contract
2323
;; @param amount amount of tokens to deposit
2424
;; @returns (response bool uint)
2525
(deposit-ft (<sip010-trait> uint) (response bool uint))
26-
;; withdraw STX from the smart wallet (user only)
26+
;; withdraw STX from the agent account (owner only)
2727
;; @param amount amount of microSTX to withdraw
2828
;; @returns (response bool uint)
2929
(withdraw-stx (uint) (response bool uint))
30-
;; withdraw FT from the smart wallet (user only)
30+
;; withdraw FT from the agent account (owner only)
3131
;; @param ft the fungible token contract
3232
;; @param amount amount of tokens to withdraw
3333
;; @returns (response bool uint)
3434
(withdraw-ft (<sip010-trait> uint) (response bool uint))
35-
;; approve an asset for deposit/withdrawal (user only)
35+
;; approve an asset for deposit/withdrawal (owner only)
3636
;; @param asset the asset contract principal
3737
;; @returns (response bool uint)
3838
(approve-asset (principal) (response bool uint))
39-
;; revoke approval for an asset (user only)
39+
;; revoke approval for an asset (owner only)
4040
;; @param asset the asset contract principal
4141
;; @returns (response bool uint)
4242
(revoke-asset (principal) (response bool uint))
@@ -48,12 +48,12 @@
4848
;; @param action the action contract
4949
;; @param parameters encoded action parameters
5050
;; @returns (response bool uint)
51-
(proxy-propose-action (<dao-action-proposals-trait> <dao-action-trait> (buff 2048) (optional (string-ascii 1024))) (response bool uint))
51+
(acct-propose-action (<dao-action-proposals-trait> <dao-action-trait> (buff 2048) (optional (string-ascii 1024))) (response bool uint))
5252
;; create a core proposal to the DAO (user or agent)
5353
;; @param core-proposals the core proposals contract
5454
;; @param proposal the proposal contract
5555
;; @returns (response bool uint)
56-
(proxy-create-proposal (<dao-core-proposals-trait> <dao-proposal-trait> (optional (string-ascii 1024))) (response bool uint))
56+
(acct-create-proposal (<dao-core-proposals-trait> <dao-proposal-trait> (optional (string-ascii 1024))) (response bool uint))
5757
;; vote on an action proposal (user or agent)
5858
;; @param action-proposals the action proposals contract
5959
;; @param proposalId the proposal ID
@@ -79,25 +79,28 @@
7979
(conclude-core-proposal (<dao-core-proposals-trait> <dao-proposal-trait>) (response bool uint))
8080
))
8181

82+
(define-trait faktory-dex-approval (
83+
;; approve a dex for trading an asset
84+
;; @param faktory-dex the faktory dex contract
85+
;; @returns (response bool uint)
86+
(acct-approve-dex (<dao-faktory-dex>) (response bool uint))
87+
;; revoke approval for a dex
88+
;; @param faktory-dex the faktory dex contract
89+
;; @returns (response bool uint)
90+
(acct-revoke-dex (<dao-faktory-dex>) (response bool uint))
91+
))
92+
8293
(define-trait faktory-buy-sell (
8394
;; buy an asset from a faktory dex
8495
;; @param faktory-dex the faktory dex contract
8596
;; @param asset the asset contract principal
8697
;; @param amount amount of tokens to buy
8798
;; @returns (response bool uint)
88-
(buy-asset (<dao-faktory-dex> <faktory-token> uint) (response bool uint))
99+
(acct-buy-asset (<dao-faktory-dex> <faktory-token> uint) (response bool uint))
89100
;; sell an asset to a faktory dex
90101
;; @param faktory-dex the faktory dex contract
91102
;; @param asset the asset contract principal
92103
;; @param amount amount of tokens to sell
93104
;; @returns (response bool uint)
94-
(sell-asset (<dao-faktory-dex> <faktory-token> uint) (response bool uint))
95-
;; approve a dex for trading an asset
96-
;; @param faktory-dex the faktory dex contract
97-
;; @returns (response bool uint)
98-
(approve-dex (<dao-faktory-dex>) (response bool uint))
99-
;; revoke approval for a dex
100-
;; @param faktory-dex the faktory dex contract
101-
;; @returns (response bool uint)
102-
(revoke-dex (<dao-faktory-dex>) (response bool uint))
105+
(acct-sell-asset (<dao-faktory-dex> <faktory-token> uint) (response bool uint))
103106
))

0 commit comments

Comments
 (0)