Required packages:
safe-core-sdk
Raw transactions can be created by using directly the safe-core-sdk package or the safe-transactions-sdk.
const tx = await safe.createTransaction({
to,
data,
value
})
The RawTransactionBuilder
provides the possibility to create raw transactions.
safe: Safe
- the safe previously createdimport { RawTransactionBuilder } from '@rsksmart/safe-transactions-sdk'
const rawTransactionBuilder = new RawTransactionBuilder(safe)
to: string
- the transaction receiver addressvalue: string
- the amount we want to transferdata: string
- the data we want to send with the transactionconst tx = await rawTransactionBuilder.rawTransaction(to, value, data)
Go to top