SDK Core
Stream money with the Constant Flow Agreement using the SDK Core
The ConstantFlowAgreementV1
class provides access to the ConstantFlowAgreementV1
smart contract, allowing you to create/update/delete flows, update ACL permissions for an operator and modify flows on behalf of another account as an operator. You can access this class via the Framework
class (sf.cfaV1
) or initialize this as a standalone class.
Accessing the CFAv1 Contract
Using SDK Core Framework Object
Direct Initialization
Methods
Read Methods
getFlow
: Get data on a stream between two accounts
getNetFlow
: Get the net flow rate of an account for a certain Super Token
getAccountFlowInfo
: Get summed flow data of an account for a certain Super Token
Write Methods
Create, Update, Delete
createFlow
: Starts a stream from a sender to a chosen receiver
updateFlow
: Updates an existing stream from a sender to a chosen receiver
deleteFlow
: Cancels an existing stream from a sender to a chosen receiver
Create, Update, Delete with ACL Permissions
createFlowByOperator
: Starts a stream between two accounts using ACL permissions
updateFlowByOperator
: Updates a stream between two accounts using ACL permissions
deleteFlowByOperator
: Deletes a stream between two accounts using ACL permissions
Manage ACL Permissions
updateFlowOperatorPermissions
: Lets a sender set the ACL permissions of another account
revokeFlowOperatorPermissions
: Revokes all ACL permissions that an account has over the sender's account
Example Usage
Last updated
Was this helpful?