Skip to main content
POST
userRole | Hyperliquid Info API

Credit Cost

1 per call

Processing

Realtime
The Hyperliquid info endpoint with type: "userRole" is used to fetch a user’s account role.
Estimate your monthly cost for this API using the Pricing Calculator.
  • Wire-equal to POST api.hyperliquid.xyz/info with {"type": "userRole", "user": "..."}.
  • The role value is one of missing, user, agent, vault, or subAccount.
  • The subAccount and agent roles additionally carry a data object identifying the controlling master account.
Returns the role a wallet plays on HyperCore. Most trading wallets are plain user accounts; this type also distinguishes API agent wallets, vault addresses, and subAccounts. For a subAccount (and for an agent), a nested data object carries the master account address that controls the wallet. User-keyed.

Endpoint

Request

string
required
Always "userRole".
string
required
The wallet address (lowercase 0x-prefixed hex).

Example

Response

A single object with a role discriminator. A plain trading wallet returns {"role": "user"}; a sub-account additionally returns its controlling master under data.

Field descriptions

string
Account role. One of:
  • missing - the address has never interacted with HyperCore.
  • user - an ordinary trading account.
  • agent - an API agent (API wallet) that signs on behalf of a master.
  • vault - a vault address.
  • subAccount - a sub-account owned by a master account.
object
Present only for the subAccount and agent roles.
Last reviewed: 2026-07-24