Is anyone aware of an automated DCA’ing “bot” for an Algorand DEX?
I’m toying with the idea of developing something but don’t want to bother if such a thing already exists.
I’m thinking the flow would be something along the lines of:
- Connect Wallet
- Specify source token (eg. USDC) and target token (eg. ALGO)
- Specify amount per period (eg. 100)
- Specify period (eg. daily)
- Optionally add an expires after (date of occurrences) - defaults to exhausted source token funds
- Optionally specify a target address - defaults to same wallet
- Sign & submit contract
More questions I have:
- Does that sound useful to anyone else?
- As an inexperienced web3 developer (but experienced web2), are there any red flags from someone who’s done something similar before I should think through before starting?
Assuming you have a backend that will send the transactions regularly to trigger the automated investing, this should work. (Smart contracts do not execute transactions by themselves but require a system to send an contract call.)
You have two options:
- Using a smart signature.
Pros: simpler to design and works with older DEX (such as TinyMan) that do not work with inner transactions
Cons: require the user to sign a smart signature, which is not possible using WalletConnect, as this can be extremely dangerous
- Using a smart contract
Pros: somewhat safer for the user and works seamlessly with WalletConnect
Cons: the user will need to transfer their fund to the smart contract application account and does not work with older DEX that do not work with inner transactions
The fees using a smart contract are also higher.
Hmmm… so if I understand correctly there’s no ideal way to do this and it’s a choice between the lesser of two evils.
On one side a user needs to sign a smart signature which I think is a dead-on-arrival option - I mean who would do this in their right mind?!?
Or use a smart contract but a user would need to transfer funds from their wallet into a smart contract - not a show stopper but… the DEX would need support for inner transactions which I’m not yet able to find one that does.
Hmmm… my wonderful new project may have stumbled at the first hurdle
I believe most of DEXes support that.
The reason Tinyman is not supporting it is because it uses smart signatures (which cannot be used inside inner transactions).
Okay cool, thanks for your help @fabrice. I’d better get reading!