I want to send some amount of ether(let say 0.1 ether) on every 1st of month to another address. I have a smart contract to send ethers from one address to another but it's a manual process. For every transfer, i need to confirm the trxn in metamask (i don't want to confirm trxn every time.) I want the functionality like an EMI payment(user signs/agree/confirms the trxn once and payment will happen every month till the no of instalment completes.
Eg. Account 1 = 0x1234
Account 2 = 0x9876
total amount to transfer = 1 ETH
no of instalments = 10
EMI amount per month => 1/10 = 0.1 ETH
Now Account1
will confirm/sign the trxn once at the starting and after that every month 0.1 ETH will be transferred to Account2
.
The approach i have that i can run a cron in JS and call transfer() function of my contract every month. But the problem is, it will pop the metamask and ask confirmation which i don't want. Also i can't ask wallet pvt key
from my users to submit it on my website.
Is there any way that i sign/confirm the trxn at the starting and trigger payment on every month.
Thanks in advance