Developers

Accounts and permissions

Main accounts, sub-accounts, users, wallets and API keys, and what each permission allows.

On this page

Most "not allowed" errors (2000 SignerUnauthorized, 1400 ErrNoTradePermission, 4015 ErrNoTransferPermission) mean a key or wallet is missing a permission. This page shows how accounts, wallets and permissions fit together.

Two levels of account

AccountGrvt web app nameIdentified byHolds
Main accountFunding Accountmain_account_id, a 0x addressdeposits and withdrawals; moves funds to its sub-accounts
Sub-accountTrading Accountsub_account_id, a numberorders, positions and margin

A main account has any number of sub-accounts. Its ID is the address of the wallet that created it. To trade, move funds to a sub-account with transfer.

Each main account also has an off-chain account ID that starts with ACC:. A login returns it without the ACC: prefix in the X-Grvt-Account-Id header (Authentication), and the referral calls show it with the prefix.

Users and wallets

Each person on Grvt has two credentials:

  • An email login (password or Google/Microsoft), for everything that doesn't move money: KYC (identity checks), referrals, viewing the portfolio. Referral data can also be read with an API key (Referrals).
  • A registered wallet. Anything that moves money or trades must be signed by a wallet registered on the account, with the right permission. Grvt never holds the wallet's private key.

A personal account has one user. A business account can have several, each with their own wallet and permissions.

API keys

An API key belongs to one account (usually a sub-account) and is tied to one wallet address. The key gets you a session (Authentication); that wallet's private key, the signing key, signs the writes. The API key has that wallet's permissions:

  • A sub-account key is either read-only (no permissions) or has Trade, optionally with Transfer.
  • A main-account key can have the main-account permissions below.
  • Every key can read, whatever its permissions.

To create a key in the Grvt web app, paste the address of a wallet you own, or let the browser generate a key pair and copy the signing key.

Watch out: if the browser generates the key pair, save the signing key right away. Grvt doesn't keep it.

Permissions

Permissions belong to a wallet on an account. Admin includes every other permission on the same account, and an admin of the main account has every permission on all its sub-accounts.

Main account

PermissionGrvt web app nameAllows
ADMINFunding Admineverything; creates sub-accounts, adds users, approves the actions below
INTERNAL_TRANSFERInternal Transfermoving funds between the main account and its sub-accounts
EXTERNAL_TRANSFERExternal Transfermoving funds to other Grvt main accounts in the transfer address book
WITHDRAWWithdrawalwithdrawing to wallets in the withdrawal address book
VAULT_INVESTORStrategy Investorinvesting in and redeeming from strategies
TRADETradetrading on all the sub-accounts, where Grvt has enabled it

Sub-account

PermissionGrvt web app nameAllows
ADMINTrading Admin ("Strategy Admin" on a strategy)everything on this sub-account; adds users to it
TRADETradeplacing and cancelling orders
TRANSFERTransfermoving funds out of this sub-account

Approvals by several admins

Some changes to a main account need signatures from several admins, up to the account's threshold (such as 2 of 3). Admins set the threshold, between one and the number of admins. It applies to:

  • adding or removing a user of the main account;
  • changing the threshold;
  • adding or removing wallets in the withdrawal address book;
  • adding or removing accounts in the transfer address book.

Adding a user to a single sub-account needs only that sub-account's admin.

esc

↑ ↓ move↵ open⇧↵ open .mdTry an error code like 2002

Keyboard shortcuts

⌘ K
Search the docs
/
Search
l
Next code language (Python → TypeScript → Go → Rust → curl → WebSocket)
j / k
Next / previous page
t
Light / dark theme
?
This help
Esc
Close dialogs and drawers