Sending Transactions
Send transactions from your users to other address
Sending a transaction from an address or multiple addresses to another address. This function will create a transaction
The createTransacion
function has the following properties.
property
description
required
network
specify which blockchain
required
from
specify which addresses to withdraw from. This is an array of strings.
required
amount
the amount to send.
required
to
the desired address
required
property
description
required
network
specify which blockchain
required
from
specify which addresses to withdraw from. This is an array of strings.
required
amount
the amount to send.
required
to
the desired address
required
import { Oumla } from "@oumla/sdk";
const client = new Oumla({
apiKey: process.env.API_KEY,
// Additional options...
});
const result = await client.transactions.create({
network: "BTC",
amount: 0.001,
from: [
"tb1qmkg9mcvlt6atwp5gugvwmyc8kj3sffn728rnghcsa4jvtl2ea0ks03fwlw"
],
to: "tb1qmkg9mcvlt6atwp5gugvwmyc8kj3sffn728rnghcsa4jvtl2ea0ks03fwlw"
});
console.log(result);
The expected output
{ status: 'confirmed' }
Last updated