Closed johngriffin closed 6 years ago
Hi @johngriffin =]
Have you thought about having a common interface for wallets to allow pull requests (withdraw money from user smart wallet, with pre-approval)?
Hi @gbarros, unless I'm misunderstanding you that is what this spec allows?
Hey all,
This is a specification that's based on @sb777's earlier spec. David Kobrosky and I have already started on an implementation of it and it's changed along the way as we've learned from that process. I submit it here as I think it's probably close to a minimum viable spec.
Purpose
I suggest the reason for this standard is interoperability - we want wallets to understand that you’re about to sign a recurring payment contract so that they can present you with a UI that summarises the agreement you’re about to enter into. As your wallet now knows you’ve entered into a subscription contract it can also provide appropriate UI for managing and cancelling your subscriptions in future.
Features
Known Issues
We plan to add the following:
be able to create reasonably accurate forecasts for upcoming subscriptions: Programatic checks that subscription accounts have available balance and that subscription is active.
Add isValidSubscription()
Limitations
The method of taking payment is for the subscriber to pre-authorise the contract to transfer ERC-20 tokens directly to the merchant. It is not possible for a contract to reach into the subscribers wallet and take ETH in the future so we do not support this, the only way to support payments in ETH would be for the subscriber to pre-fund the contract with multiple billing periods.
Any checks to ensure that the subscriber is creating a "valid" subscription are left to the implementation. When createSubscription() is called the contract will probably want to check that the attributes correspond to a valid plan.
Once a subscription has been created the merchant cannot update it's attributes.
Comparison with other PRs
8x
PiperMerriam