-
Notifications
You must be signed in to change notification settings - Fork 140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sponsored Fees #1068
base: main
Are you sure you want to change the base?
Sponsored Fees #1068
Conversation
Signed-off-by: Nana Essilfie-Conduah <[email protected]>
✅ Deploy Preview for hedera-hips ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
…types Signed-off-by: Nana Essilfie-Conduah <[email protected]>
Updated HIP with scope concept and fixed PR description with updated Abstract |
Would it be possible for sponsored fees to be optionally set towards spending by a smart contract, thus limiting the scope of the approval to executing only 1 particular smart contract. |
@tud0r6 I like this idea, to be clear, you mean that if I grant some hbar to Alice, I would be able to specify that Alice can only spend the hBar on executing transactions related to a specific contract, nothing else. She would not be able to execute another contract, or create an NFT, etc... Note, hbar in this case is gas for contracts, does the allowance extend to paying for gas (through the SDK and/or relay), or just native fees ? If only native fees, we may need to consider supporting gas payments. |
Great considerations @gregscullard and @tud0r6 . |
Indeed, I won't want to sponsor general-use gas(HBAR), rather application(SC)-specific gas(HBAR). |
Signed-off-by: Nana Essilfie-Conduah <[email protected]>
Signed-off-by: Nana Essilfie-Conduah <[email protected]>
@gregscullard and @tud0r6 I've added the gas scope but also added thoughts in the open questions section around some challenges here. |
Description:
This HIP proposes an expansion to the approval and allowance network logic (i.e. CryptoApproveAllowance, NftAllowance
and TokenAllowance) by allowing any account on the network to provide allowances that will sponsor the payment of the
fees for another account’s submitted transactions.
In this way account Alice may assign an HBAR / token transaction fee allowance for EOA account Bob or Contract account
Carol and pay the fees due to nodes, the network and accounts for any transactions they submit, thus allowing Bob or
Carol to have zero balance and still transact on chain.
This proposal extends the existing Approval and Allowance API by adding the concept of a scope that designates the type
of value transafer an allowance applies to.
The scopes will include CryptoTranafer, HAPI transsaction fee and token custom fees.
This enables value transfer and fee payments to another account without requiring one-off
approval for each transaction. This feature enhances flexibility and efficiency in managing transaction costs,
particularly for high volume applications.
Related issue(s):
Fixes #912
Notes for reviewer:
Expect more changes soon.
There's an outstanding item to condense the Allowances types to instead be scopes on the existing allowances as a cleaner API form
Checklist