From 5755ddc6291b17f94e82d406f00858a1823b61b3 Mon Sep 17 00:00:00 2001 From: massimiliano1991 Date: Fri, 4 Sep 2026 22:02:10 +0200 Subject: [PATCH] docs: document the `dex` HIP-3 parameter in Info method docstrings user_state, open_orders, frontend_open_orders, all_mids and meta all accept `dex: str = ""` and forward it to the API, but the Args section never mentions it, so HIP-3 support is only discoverable by reading the source. Add the parameter to each docstring; all_mids and meta had no Args section, so one is introduced with just `dex`. Docstring only, no behaviour change. Closes #286. --- hyperliquid/info.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/hyperliquid/info.py b/hyperliquid/info.py index 360d0588..5b20c692 100644 --- a/hyperliquid/info.py +++ b/hyperliquid/info.py @@ -91,6 +91,8 @@ def user_state(self, address: str, dex: str = "") -> Any: Args: address (str): Onchain address in 42-character hexadecimal format; e.g. 0x0000000000000000000000000000000000000000. + dex (str): HIP-3 DEX name, e.g. "xyz". Empty string "" + targets the standard Hyperliquid perp DEX. Returns: { assetPositions: [ @@ -138,6 +140,8 @@ def open_orders(self, address: str, dex: str = "") -> Any: Args: address (str): Onchain address in 42-character hexadecimal format; e.g. 0x0000000000000000000000000000000000000000. + dex (str): HIP-3 DEX name, e.g. "xyz". Empty string "" + targets the standard Hyperliquid perp DEX. Returns: [ { coin: str, @@ -159,6 +163,8 @@ def frontend_open_orders(self, address: str, dex: str = "") -> Any: Args: address (str): Onchain address in 42-character hexadecimal format; e.g. 0x0000000000000000000000000000000000000000. + dex (str): HIP-3 DEX name, e.g. "xyz". Empty string "" + targets the standard Hyperliquid perp DEX. Returns: [ { children: @@ -189,6 +195,9 @@ def all_mids(self, dex: str = "") -> Any: POST /info + Args: + dex (str): HIP-3 DEX name, e.g. "xyz". Empty string "" + targets the standard Hyperliquid perp DEX. Returns: { ATOM: float string, @@ -275,6 +284,9 @@ def meta(self, dex: str = "") -> Meta: POST /info + Args: + dex (str): HIP-3 DEX name, e.g. "xyz". Empty string "" + targets the standard Hyperliquid perp DEX. Returns: { universe: [