Enabling API access
Approval
What it authorizes
Method 1 β Frontend (recommended)
Method 2 β Programmatic (API)
# 1. Create an API key
POST /v1/api-keys/create
# 2. Enable API access on the subaccount
POST /v1/account-auth/subaccount/toggle-access
{ "subaccountAddress": "0xβ¦", "chainId": 42161, "enable": true }
# 3. Delegate permissions to the key
POST /v1/account-auth/delegate-access
{ "subaccountAddress": "0xβ¦", "apiKeyIdentifier": "β¦",
"permissions": ["OPEN_POSITION", "CLOSE_POSITION"] }
# 4. (For instant execution) register a solver instant-action token
POST /v1/account-auth/instant-action/tokenVerify and revoke
Action
Endpoint

