Add a different deposit function with the Broker parameter #84
Replies: 4 comments 15 replies
-
Interesting point. Now I am thinking why should we even include a broker in the Open-ended? Perhaps we skip it in v1 and consider it for a future release if needed. My rationale is that, as you mentioned, deposits will be made multiple times in a stream. People can bypass broker fees by interacting directly with the Sablier UI or etherscan. The time to learn this is very low compared to the time to learn to create a stream. This logic doesn't apply to lockup streams, as creating a stream is more challenging than depositing into an open-ended stream. So what if we don't include it and find a new approach in the future - an approach that can prevent bypassing broker fees? |
Beta Was this translation helpful? Give feedback.
-
I am not sure I understand this. What do you mean by "bypass broker fees". Broker fees are good feature for UI integrators (of our contracts) who want to take a fee on their platform. The end user, who interacts through our app, doesn't even need to know what a broker is.
again, I am not sure I understand this point either, can you please reformulate? |
Beta Was this translation helpful? Give feedback.
-
I'm skeptical that broker fees will be helpful for integrators. I'm not aware of any integration that charges broker fees at the moment. It's also likely that an integrator would prefer to devise their own revenue generating mechanism to account for their compliance requirements. That said, as I've argued here, we can use the broker fees for charging fees in our UI. I think that this is the greatest benefit conferred by broker fees - that we can charge UI fees without asking the user to sign two txs, i.e. one for paying the broker fee and another for creating the stream. Additionally, having a broker fee system would allow us to shill it to investors. Thus, I'm in favor of implementing broker fees in OpenEnded. But I'm ambivalent about whether we implement a separate function or not. I will defer to your judgement here @andreivladbrg @smol-ninja. P.S. |
Beta Was this translation helpful? Give feedback.
-
@andreivladbrg one more question, lets say we keep functions like |
Beta Was this translation helpful? Give feedback.
-
Initially posted in the PR: #77
Since
create
anddeposit
are distinct operations, the most logical place to implement theBroker
logic is indeposit
because that is where theERC20
transfer occurs. Therefore, I suggest adding another function calleddepositWithBroker
instead of modifying the currentdeposit
function.The motivation is as follows: Unlike the
lockup
contracts, where thecreate
function (where the token transfer happens) is called once for a uniquestreamId,
here deposit might be called multiple times (the whole idea with OE is to have top-ups) for a unique ID. Therefore, to improve the DX—and since the broker param is most often set asaddress(0)
and 0%—let’s have a defaultdeposit
function (current version) and add another with theBroker
parameter. This way, we mentain the business improvements, by allowing other UIs to profit from our contract, without consuming extra gas for each regular top made through our app.Pros
Broker
param (e.g.createAndDeposit
orrestartAndDeposit
)`Cons
IMO, the pros outweigh the cons.
@sablier-labs/solidity @razgraf wdyt?
Beta Was this translation helpful? Give feedback.
All reactions