pool_assets

function pool_assets(sender_blockchain_rid: byte_array, sender_id: byte_array, recipient_id: byte_array, asset: asset, amount: big_integer)(source)

This method ensures that a rule exists for the transfer defined by the parameters passed, and creates an account_creation_transfer entity representing that transfer.

This function does not check that the account does not exist, assuming it has been checked before calling this.

This function does not allow multiple transfers of the same asset to be transferred to the same account, regardless of sender.

Can only be called from an operation.

Throws "TRANSFER NOT ALLOWED" if:

  • no rule allows that transfer, or

  • a pending transfer to the same account ID with the same asset already exists

Parameters

sender_blockchain_rid

the ID of the blockchain where the transfer came from

sender_id

the sender account ID

recipient_id

the non-existing account that is being registered

asset

the asset that was transferred

amount

the amount of the asset that was transferred

See also

module_args_list_element

for a description of rules