Skip to main content
Before trading on Hyperliquid, users must complete the provider’s setup descriptors. The SDK provides methods to discover, build, sign, and submit these. Post-setup tuning is exposed via the provider’s options descriptors (e.g. accountMode) — these never gate trading. The flow:
  1. CheckcheckSetup() returns the outstanding setup steps and whether the account is ready
  2. Run each stepexecuteProviderSetupAction() signs and submits one step end-to-end, routing it to the correct signer by shape
Parameters for checkSetup: Returns: ProviderSetup Parameters for executeProviderSetupAction: Returns: Promise<void> — resolves on success, throws PerpsError on venue rejection.

Setup descriptors

The following setup actions are returned in the setup array from GET /providers for Hyperliquid. The SDK executes them automatically during the setup flow.

approveAgent

Authorizes an agent wallet to sign trading operations on the user’s behalf. This is the one-time wallet signature that enables agent-based trading — once approved, the SDK-managed agent can place, cancel, and modify orders without wallet popups.

setReferrer

Applies the LI.FI referral code to the account, enabling 4% off fees for the account’s first $25M of trading volume. The step is signed by the SDK-managed agent rather than the user’s wallet, so it is sequenced after approveAgent.

approveBuilderFee

Approves the LI.FI builder fee on the user’s Hyperliquid account. Hyperliquid requires explicit builder fee approval before orders can be routed through third-party builders like LI.FI.

Options descriptors

The following options actions are returned in the options array from GET /providers for Hyperliquid. These never gate trading — they are post-setup tuning controls rendered behind a cog icon in the widget. The accepted parameter values are enumerated on each descriptor’s params[].values array.

accountMode

Switches the account’s operating mode between supported Hyperliquid abstraction variants. Every transition is USER-signed: the agent-side operation can only initialize a never-set mode and cannot safely change an existing account. Mode values: unifiedAccount (default), disabled (standard/manual mode), and portfolioMargin. The deprecated dexAbstraction value is no longer advertised; existing accounts using it remain readable. For a full explanation of what each mode means — balance unification behaviour, capital efficiency, and signing requirements — see Account Abstraction.

Low-Level API

Using the low-level API directly: