account
Get account by an account's index, or L1 address
get/api/v1/account
Query parameters
bystring · enumRequiredPossible values:
Field used to identify the requested record.
valuestringRequired
Identifier corresponding to the selected by field.
active_onlybooleanOptionalDefault:
Hide markets for which leverage and margin settings are present (meaning the account traded it at least once), but with no active position.
falsecursorstringOptional
Opaque pagination cursor returned by the previous response; pass it unchanged.
Responses
200
A successful response.
application/json
Fields with zero or empty values may be omitted; handle optional properties when decoding responses.
codeinteger · int32RequiredExample:
200messagestringOptional
totalinteger · int64RequiredExample:
1next_cursorstringOptional
400
Bad request
application/json
get/api/v1/account
GET /api/v1/account?by=index&value=text HTTP/1.1
Host: mainnet.zklighter.elliot.ai
Accept: */*
{
"code": 200,
"message": "text",
"total": 1,
"accounts": [
{
"code": 200,
"message": "text",
"account_type": 1,
"account_trading_mode": 1,
"index": 1,
"l1_address": "0x70997970C51812dc3A010C7d01b50e0d17dc79C8",
"cancel_all_time": 1640995200,
"total_order_count": 100,
"total_isolated_order_count": 100,
"pending_order_count": 100,
"available_balance": "19995",
"status": 1,
"collateral": "46342",
"account_index": 1,
"name": "text",
"description": "text",
"can_invite": true,
"referral_points_percentage": "text",
"positions": [
{
"market_id": 1,
"symbol": "ETH",
"initial_margin_fraction": "20.00",
"open_order_count": 3,
"pending_order_count": 3,
"position_tied_order_count": 3,
"sign": 1,
"position": "3.6956",
"avg_entry_price": "3024.66",
"position_value": "3019.92",
"unrealized_pnl": "17.521309",
"realized_pnl": "2.000000",
"liquidation_price": "3024.66",
"total_funding_paid_out": "34.2",
"margin_mode": 1,
"allocated_margin": "46342",
"total_discount": "text",
"margin_set_flag": 1
}
],
"assets": [
{
"symbol": "USDC",
"asset_id": 1,
"balance": "1000",
"locked_balance": "1000",
"margin_balance": "1000",
"margin_mode": "enabled",
"multiplier": "1.000000000000000000"
}
],
"total_asset_value": "19995",
"cross_asset_value": "19995",
"pool_info": {
"status": 0,
"operator_fee": "100",
"min_operator_share_rate": "200",
"total_shares": 100000,
"operator_shares": 20000,
"annual_percentage_yield": 20.5,
"daily_returns": [
{
"timestamp": 1640995200,
"daily_return": 0.0001
}
],
"share_prices": [
{
"timestamp": 1640995200,
"share_price": 0.0001
}
],
"sharpe_ratio": 1,
"strategies": [
{
"collateral": "text"
}
]
},
"shares": [
{
"public_pool_index": 1,
"shares_amount": 3000,
"entry_usdc": "3000",
"entry_timestamp": 1,
"principal_amount": "text"
}
],
"created_at": 1,
"transaction_time": 1,
"pending_unlocks": [
{
"unlock_timestamp": 1,
"asset_index": 1,
"amount": "text"
}
],
"approved_integrators": [
{
"account_index": 54621,
"name": "Integrator1",
"max_perps_taker_fee": 10,
"max_perps_maker_fee": 1,
"max_spot_taker_fee": 10,
"max_spot_maker_fee": 1,
"approval_expiry": 1640995200
}
],
"can_rfq": true,
"cross_initial_margin_requirement": "5998.500000",
"cross_maintenance_margin_requirement": "2999.250000",
"can_rfq_market_ids": [
"text"
],
"metadata": {
"color": "text"
},
"agent_enabled": true,
"bo_positions": [
{
"market_id": 1,
"entry_quote": "text",
"avg_entry_price": "text",
"sign": -1,
"size": "text"
}
],
"instance": "text"
}
],
"next_cursor": "text"
}Last updated
Was this helpful?