🐧  pfp
🐧
@mintcloud
Can Frames support use cases that involve a token swap (buy token A with token B)? My 3 favorite ideas in the replies will get 20 USDC each @bountybot
4 replies
0 recast
0 reaction

eric pfp
eric
@tintin
AFAIK not really. The concept of signing within a Frame is in the context of a unique generated key, which is independent on your connected wallet address. Thus it has no funds and can't make approvals / token transfers. However with some additional setup I think it could be possible... cont.
2 replies
0 recast
0 reaction

eric pfp
eric
@tintin
A very simple example would be a permissioned router. You approve this contract from your connected wallet address (so that it can swap for you), and you trust an off chain service (i.e. the frames backend) to trigger the swap to happen. There must be correct permissions on who can "trigger" the swap to happen... cont.
1 reply
0 recast
0 reaction

eric pfp
eric
@tintin
Since it can lead to loss of funds depending on how the contracts are written. You can remove some trust in the off chain service by checking that the signer of the message received in the Frame, but at the end of the day you'll still have a centralized off chain entity controlling the swapping contract so not ideal.
1 reply
0 recast
0 reaction