Get Transactions
Fetch a paginated list of Stellar transactions using the Blux core SDK.
The getTransactions function returns a paginated list of Stellar transactions.
forAccount accepts G…, M…, SEP-2 federation, or .xlm; see
address resolution.
The return value contains two properties:
response— the records you can use directlybuilder— exposesnext()andprev()to paginate through results
Type
export type CallBuilderOptions = {
cursor?: string;
limit?: number;
network?: string;
order?: "asc" | "desc";
};
type GetTransactionsOptions = CallBuilderOptions & {
forAccount?: string; // G…/M…, SEP-2 address, or .xlm name
forClaimableBalance?: string;
forLedger?: string | number;
forLiquidityPool?: string;
includeFailed?: boolean;
};
type GetTransactionsResult = {
builder: TransactionCallBuilder;
response: Horizon.ServerApi.CollectionPage<Horizon.ServerApi.TransactionRecord>;
};Usage
import { core } from "@bluxcc/core";
const result = await core.getTransactions({ forAccount: "alice.xlm" });