Note: the ACL features are only available on testnets only as of May 2, 2022.
Note: If you set a flow rate allowance equal to the maximum flow rate then this value is never deducted. In solidity, the maximum flow rate could be represented bytype(int96).max
updateFlowOperatorPermissions
allows you to set granular permissions for operators over streams.authorizeFlowOperatorWithFullControl
allows you to grant full access over streams to an operator. Also note that, if an operator is granted full access via this function, their flow allowance will not be deducted after increasing flowRates of the sender or creating flows on behalf of the senderrevokeFlowOperatorWithFullControl
allows you to remove all access to stream operation from your operatortoken
, and flowOperator
parameters are straightforward, but the permissions
and flowRateAllowance
parameters require more explanation.permissions
value is a bit mask which represents a specific level of access over streams. This may be a single permission (i.e. create, update, or delete) or some combination of permissions (i.e. create and update, update and delete, create and delete, or create, update and delete). When passing in a value, you will use a decimal value which represents a level of access. . The below table shows the binary representation of the permission value, and its associated decimal value. When calling the updateFlowOperatorPermissions
function, you will pass in the decimal value associated with each permission level:NOTE: passing in any number other than one of the numbers below will cause the transaction to revert
flowRateAllowance
parameter allows you to define the total increase in flow rates your operator is allowed to make. Your operator’s flowRateAllowance
is not impacted by deleting streams or updating streams with a new flow rate which is less than the previous flow rate (i.e. by reducing stream flow rates).flowRateAllowance
will decrease by the amount equal to the flowRate
of the newly created stream. In the case of flow updates, the operator’s flowRateAllowance
will be decreased by an amount equal to the delta between the new higher flow rate and previous flow rate.385802469135802
tokens per second). If our operator creates a stream on our behalf with a flowRate
of 500 tokens per month, then the operator’s remaining flowRateAllowance
becomes 500 tokens per month (1000/month - 500/month
). Then, if our operator updates another one of our streams that is already outstanding by increasing our flowRate
by 250 tokens per month, then our operator’s flowRateAllowance
will decrease by another 250 tokens per month, leaving the remaining flowRateAllowance at 250 tokens per month (500/month - 250/month
).flowRates
do not impact a flowOperator’s allowance at all. If, in the previous example, our operator were to delete flow #1 and update flow #2 by reducing the flowRate
by 100 tokens per month, these actions would each not impact the flowRateAllowance
. The operator would still have a flow rate allowance of 250 tokens per month remaining. But, if they were to increase it by 50 tokens per month after decreasing, their new flow rate allowance would now be 200 tokens per month.ByOperator
suffix to perform these operations: