# Hooks & Store

For custom UIs that need widget data or actions:

**Hooks**

* `useEssential()` – wallet, network, consts (zo/sudo/usdz), accountData, refreshAccount
* `useWallet()`, `useNetwork()` – wallet and current network
* `usePosition(address, network)` – positions list, refresh, `dataUpdatedAt`
* `useOrder(address, network)` – orders list, refresh, `dataUpdatedAt`
* `useHistories(address, network)` – trade history
* `useFundingRate(symbol, network, lpToken)` – funding rate
* `usePositionConfig(network, { symbols })` – position config (fees, etc.)
* `useSymbolInfo(network)` – symbol info map (ZLP/SLP/USDZ)
* `useRpc()` – RPC list, custom URL, latency; used by `RpcSettings`
* `useSponsoredGasAvailability(address, network)` – gas sponsorship

**Store (Jotai)**

* `appStore` – same store instance must be used for the widget and your app (see Quick start).
* `currentSymbolAtom` – `{ symbolId, unit, icon }`; set when user picks a market.
* `tokenPriceAtom` – `{ tokenPrice: Record<string, number>, isLoading, error }` (Pyth oracle prices).
