Sending Transactions
Deposit, transfers and withdrawals
Last updated
Was this helpful?
Deposit, transfers and withdrawals
Last updated
Was this helpful?
Send tokens to the privacy pool
amountGwei
- token amount to deposit into an account (in pool dimension)
signatureCallback
- a callback with which invoked when needed to ask user to sign data
fromAddress
- the 0x
-address which will be used to depositing funds
blockNumber
- the client waits until the internal provider becomes synced with the specified block before the input account balance (and allowance if applicable) validation. The waiting interval is hardcoded to 60 seconds. If the provider does not become synced within that interval the transaction is sent.
Promise
returns jobId
returned by relayer which can be use to monitor transaction
Transfer tokens inside a pool to the requested addresses. The function creates a set of transactions (needed to process requests), sends it to the relayer in sequence order and returns a set of job IDs assigned by relayer
transfers
- a set of transfer destinations. A single destination should contain the receiver shielded address and associated funds amount to transfer
Promise
returns array of job IDs (each sent transaction associated with the unique job ID assigned by relayer)
Withdraw tokens to the 0x
-address. The function creates a set of transactions (needed to process withdraw), sends it to the relayer and returns a set of job IDs assigned by relayer
address
- a 0x
destination address to the sending withdrawn tokens
amountGwei
- tokens amount to be withdrawn (in pool dimension)
swapAmount
- part of amountGwei
which requested to swap to the native coins on withdrawal (in pool dimension)
Promise
returns array of job IDs (each sent transaction associated with the unique job ID assigned by relayer)
relayerFee
- a raw which will be used to estimate total transaction fee (will requested under the hood when undefined)
This routine may produce several transactions in rare cases when you have a lot of unspent notes. It can increase overall fee needed for transferring requested funds amount. Please refer to the examples described to better understanding notes aggregation flow
relayerFee
- a raw which will be used to estimate total transaction fee (will requested under the hood when undefined)
This routine may produce several transactions in rare cases when you have a lot of unspent notes. It can increase overall fee needed for the funds withdrawal. Please refer to the examples described to better understanding notes aggregation flow
Swap ability doesn't supported on the each pool. Use method to request how many tokens you can swap on the waithdrawal transaction
relayerFee
- a raw which will be used to estimate total transaction fee (will requested under the hood when undefined)