Skip to Content
Symmio Trading-SDK — the SDK surface for builders on HyperEVM
CoreSubgraphgetQuoteFunding

getQuoteFunding

Funding totals — paid, received, and net — for a batch of quotes, read from the analytics subgraph.

import { getQuoteFunding } from "@symmio/trading-core"; const { rows, missingQuoteIds } = await getQuoteFunding(config, { quoteIds: [42n, 43n], });

Parameters

quoteIdsreadonly bigint[]required

On-chain quote ids to read funding for.

chainIdnumberoptional

Optional chain override.

Returns

GetQuoteFundingReturnType
rowsQuoteFundingData[]
One row per quote id the subgraph returned. Each row is { quoteId, paid, received, net } — all amounts are 18-decimal-wei bigint, and net = paid − received (positive means the user net-paid funding over the position’s life; negative means net-received).
missingQuoteIdsbigint[]
The subset of input ids the subgraph did not return (indexing lag) — so the caller can distinguish “no funding” from “not yet indexed”.

Query options

import { getQuoteFundingQueryOptions } from "@symmio/trading-core"; import { useQuery } from "@tanstack/react-query"; useQuery(getQuoteFundingQueryOptions(config, { quoteIds: [42n] }));
Last updated on