Are you an LLM? Read llms.txt for a summary of the docs, or llms-full.txt for the full context.
Skip to content

volume

A user's cumulative trading volume in USD. Used for fee-tier resolution.

Drives the volume-tiered fee schedule (maker/taker rates) and the lifetime volume gate for opting in as a referrer (min_referrer_volume). The 30-day rolling volume of a referrer's direct referees additionally determines their commission tier — see protocol book: perps/6-referral §6b.

Signature

def volume(self, user: Addr, *, since: int | None = None) -> str

Example

from dango.info import Info
from dango.utils.constants import MAINNET_API_URL
from dango.utils.types import Addr
 
info = Info(MAINNET_API_URL, skip_ws=True)
lifetime = info.volume(Addr("0x..."))
print("lifetime volume USD:", lifetime)

Parameters

userAddr. The user's account address.

sinceint | None, optional. Nanosecond-timestamp lower bound (matches Dango's Timestamp wire format). Default: None (lifetime).

Returns

str — a 6-decimal UsdValue string. Parse with Decimal(...) if you need arithmetic.

See also