Skip to content
Start Trading

Accounts

Manage trading accounts, balances, and portfolio history.

Get Accounts
AccountGetAccountsResponse v1().accounts().getAccounts(AccountGetAccountsParamsparams = AccountGetAccountsParams.none(), RequestOptionsrequestOptions = RequestOptions.none())
GET/v1/accounts
Get Account By ID
AccountGetAccountByIdResponse v1().accounts().getAccountById(AccountGetAccountByIdParamsparams = AccountGetAccountByIdParams.none(), RequestOptionsrequestOptions = RequestOptions.none())
GET/v1/accounts/{account_id}
Patch Account By ID
AccountPatchAccountByIdResponse v1().accounts().patchAccountById(AccountPatchAccountByIdParamsparams = AccountPatchAccountByIdParams.none(), RequestOptionsrequestOptions = RequestOptions.none())
PATCH/v1/accounts/{account_id}
Get Account Balances
AccountGetAccountBalancesResponse v1().accounts().getAccountBalances(AccountGetAccountBalancesParamsparams = AccountGetAccountBalancesParams.none(), RequestOptionsrequestOptions = RequestOptions.none())
GET/v1/accounts/{account_id}/balances
Get Portfolio History
AccountGetPortfolioHistoryResponse v1().accounts().getPortfolioHistory(AccountGetPortfolioHistoryParamsparams, RequestOptionsrequestOptions = RequestOptions.none())
GET/v1/accounts/{account_id}/portfolio-history
ModelsExpand Collapse
class Account:

Represents a trading account

long id

The unique identifier for the account

formatint64
long accountHolderEntityId

The account holder entity identifier

formatint64
String fullName

The full legal name of the account

LocalDate openDate

The date the account was opened

formatdate
long optionsLevel

The options level of the account

formatint64
String shortName

The short name of the account

The current status of the account

One of the following:
ACTIVE("ACTIVE")
INACTIVE("INACTIVE")
CLOSED("CLOSED")

The sub-type of account

One of the following:
CASH("CASH")
MARGIN("MARGIN")
OTHER("OTHER")

The type of account

One of the following:
CUSTOMER("CUSTOMER")
OTHER("OTHER")
Optional<LocalDate> closeDate

The date the account was closed, if applicable When a null/undefined value is observed, it indicates it does not apply.

formatdate
class AccountBalances:

Represents the balance details for a trading account

long accountId

The unique identifier for the account

formatint64
String buyingPower

The total buying power available in the account.

String currency

Currency identifier for all monetary values.

String dailyChange

Difference between current equity and start-of-day equity.

String dailyPnl

Total profit or loss since start of day.

String dailyRealizedPnl

Realized profit or loss since start of day.

String dailyTotalPnl

Total profit or loss since start of day.

String dailyUnrealizedPnl

Total unrealized profit or loss across all positions relative to prior close.

String equity

The total equity in the account.

String longMarketValue

The total market value of all long positions.

MarginType marginType

The applicable margin model for the account

One of the following:
OTHER("OTHER")
NONE("NONE")
PORTFOLIO_MARGIN("PORTFOLIO_MARGIN")
RISK_BASED_HAIRCUT_BROKER_DEALER("RISK_BASED_HAIRCUT_BROKER_DEALER")
REG_T("REG_T")
RISK_BASED_HAIRCUT_MARKET_MAKER("RISK_BASED_HAIRCUT_MARKET_MAKER")
CIRO("CIRO")
FUTURES_NLV("FUTURES_NLV")
FUTURES_TOT_EQ("FUTURES_TOT_EQ")
String openOrderAdjustment

Signed buying-power correction from open orders.

String settledCash

The amount of cash that is settled and available for withdrawal or trading.

Start-of-day snapshot balances.

String buyingPower

Start-of-day buying power.

String equity

Start-of-day equity.

String longMarketValue

Start-of-day long market value.

String shortMarketValue

Start-of-day short market value.

Optional<LocalDate> asof

Timestamp for the start-of-day values. When a null/undefined value is observed, it indicates that there is no available data.

formatdate
DeprecatedOptional<String> dayTradeBuyingPower

Start-of-day day-trade buying power. When a null/undefined value is observed, it indicates it does not apply.

Optional<String> maintenanceMarginExcess

Start-of-day maintenance margin excess. When a null/undefined value is observed, it indicates it does not apply.

Optional<String> maintenanceMarginRequirement

Start-of-day maintenance margin requirement. When a null/undefined value is observed, it indicates it does not apply.

Optional<String> tradeCash

Start-of-day trade cash. When a null/undefined value is observed, it indicates it does not apply.

String tradeCash

Trade-date effective cash.

String unrealizedPnl

Total unrealized profit or loss across all open positions.

String unsettledCredits

Trade-date unsettled cash credits.

String unsettledDebits

Trade-date unsettled cash debits.

String withdrawableCash

The amount of cash currently available to withdraw.

Optional<MarginDetails> marginDetails

Margin-account-only details. When a null/undefined value is observed, it indicates it does not apply.

Deprecatedlong dayTradeCount

The number of day trades executed over the 5 most recent trading days.

formatint32
minimum0
String initialMarginExcess

Initial margin excess for trade-date balances.

String initialMarginRequirement

Initial margin requirement for trade-date balances.

MarginSessionDetails intradayDetails

Intraday session margin calculation details.

String buyingPower

Maximum buying power available in the account during the session.

Optional<String> multiplier

Effective multiplier for margin calculations during the session.

String maintenanceMarginExcess

Maintenance margin excess for trade-date balances.

String maintenanceMarginRequirement

Maintenance margin requirement for trade-date balances.

MarginSessionDetails overnightDetails

Overnight session margin calculation details.

String buyingPower

Maximum buying power available in the account during the session.

Optional<String> multiplier

Effective multiplier for margin calculations during the session.

Deprecatedboolean patternDayTrader

true if the account is currently flagged as a PDT, otherwise false.

DeprecatedOptional<String> dayTradeBuyingPowerUsage

The amount of day-trade buying power used during the current trading day. When null/undefined, the value should be assumed to be zero. The field is omitted to simplify the response.

Optional<List<MarginTopContributor>> topContributors

Optional top margin contributors, returned only when explicitly requested.

DeprecatedString dayTradeBuyingPowerUsage

Day-trade buying power consumed by fills against this underlying on the current trade date. Populated only for pattern day trader accounts.

String initialMarginRequirement

Initial margin requirement attributable to this underlying.

String maintenanceMarginRequirement

Maintenance margin requirement attributable to this underlying.

String marketValue

Net market value attributable to this underlying.

String underlyingInstrumentId

UUID of the underlying security contributing to margin requirement.

formatuuid
Optional<MarginDetailsUsage> usage

Current usage totals. When a null/undefined value is observed, it indicates that there is no available data.

String total

The total margin available in the current model.

String used

The amount of margin that is currently being utilized.

Optional<String> multiplier

Applied multiplier for margin calculations. When a null/undefined value is observed, it indicates it does not apply.

Optional<String> shortMarketValue

The total market value of all short positions. When null/undefined, the value should be assumed to be zero. The field is omitted to simplify the response.

class AccountBalancesSod:
String buyingPower

Start-of-day buying power.

String equity

Start-of-day equity.

String longMarketValue

Start-of-day long market value.

String shortMarketValue

Start-of-day short market value.

Optional<LocalDate> asof

Timestamp for the start-of-day values. When a null/undefined value is observed, it indicates that there is no available data.

formatdate
DeprecatedOptional<String> dayTradeBuyingPower

Start-of-day day-trade buying power. When a null/undefined value is observed, it indicates it does not apply.

Optional<String> maintenanceMarginExcess

Start-of-day maintenance margin excess. When a null/undefined value is observed, it indicates it does not apply.

Optional<String> maintenanceMarginRequirement

Start-of-day maintenance margin requirement. When a null/undefined value is observed, it indicates it does not apply.

Optional<String> tradeCash

Start-of-day trade cash. When a null/undefined value is observed, it indicates it does not apply.

class AccountSettings:
Optional<RiskSettings> risk

Risk settings for the account When a null/undefined value is observed, it indicates that there is no available data.

Optional<String> maxNotional

The maximum notional value available to the account When a null/undefined value is observed, it indicates that there is no available data.

enum AccountStatus:

Account status

ACTIVE("ACTIVE")
INACTIVE("INACTIVE")
CLOSED("CLOSED")
enum AccountSubtype:

Account subtype classification providing more granular categorization

CASH("CASH")
MARGIN("MARGIN")
OTHER("OTHER")
enum AccountType:

Account type classification

CUSTOMER("CUSTOMER")
OTHER("OTHER")
class MarginDetails:
Deprecatedlong dayTradeCount

The number of day trades executed over the 5 most recent trading days.

formatint32
minimum0
String initialMarginExcess

Initial margin excess for trade-date balances.

String initialMarginRequirement

Initial margin requirement for trade-date balances.

MarginSessionDetails intradayDetails

Intraday session margin calculation details.

String buyingPower

Maximum buying power available in the account during the session.

Optional<String> multiplier

Effective multiplier for margin calculations during the session.

String maintenanceMarginExcess

Maintenance margin excess for trade-date balances.

String maintenanceMarginRequirement

Maintenance margin requirement for trade-date balances.

MarginSessionDetails overnightDetails

Overnight session margin calculation details.

String buyingPower

Maximum buying power available in the account during the session.

Optional<String> multiplier

Effective multiplier for margin calculations during the session.

Deprecatedboolean patternDayTrader

true if the account is currently flagged as a PDT, otherwise false.

DeprecatedOptional<String> dayTradeBuyingPowerUsage

The amount of day-trade buying power used during the current trading day. When null/undefined, the value should be assumed to be zero. The field is omitted to simplify the response.

Optional<List<MarginTopContributor>> topContributors

Optional top margin contributors, returned only when explicitly requested.

DeprecatedString dayTradeBuyingPowerUsage

Day-trade buying power consumed by fills against this underlying on the current trade date. Populated only for pattern day trader accounts.

String initialMarginRequirement

Initial margin requirement attributable to this underlying.

String maintenanceMarginRequirement

Maintenance margin requirement attributable to this underlying.

String marketValue

Net market value attributable to this underlying.

String underlyingInstrumentId

UUID of the underlying security contributing to margin requirement.

formatuuid
Optional<MarginDetailsUsage> usage

Current usage totals. When a null/undefined value is observed, it indicates that there is no available data.

String total

The total margin available in the current model.

String used

The amount of margin that is currently being utilized.

class MarginDetailsUsage:
String total

The total margin available in the current model.

String used

The amount of margin that is currently being utilized.

class MarginSessionDetails:
String buyingPower

Maximum buying power available in the account during the session.

Optional<String> multiplier

Effective multiplier for margin calculations during the session.

class MarginTopContributor:
DeprecatedString dayTradeBuyingPowerUsage

Day-trade buying power consumed by fills against this underlying on the current trade date. Populated only for pattern day trader accounts.

String initialMarginRequirement

Initial margin requirement attributable to this underlying.

String maintenanceMarginRequirement

Maintenance margin requirement attributable to this underlying.

String marketValue

Net market value attributable to this underlying.

String underlyingInstrumentId

UUID of the underlying security contributing to margin requirement.

formatuuid
enum MarginType:

An account’s margin type

OTHER("OTHER")
NONE("NONE")
PORTFOLIO_MARGIN("PORTFOLIO_MARGIN")
RISK_BASED_HAIRCUT_BROKER_DEALER("RISK_BASED_HAIRCUT_BROKER_DEALER")
REG_T("REG_T")
RISK_BASED_HAIRCUT_MARKET_MAKER("RISK_BASED_HAIRCUT_MARKET_MAKER")
CIRO("CIRO")
FUTURES_NLV("FUTURES_NLV")
FUTURES_TOT_EQ("FUTURES_TOT_EQ")
class PortfolioHistoryResponse:
LocalDate date

The date for this segment

formatdate
String eodEquity

The equity at the end of the trading day.

String realizedPnl

Sum of the profit and loss realized from position closing trading activity.

String sodEquity

The equity at the start of the trading day.

String unrealizedPnl

Sum of the profit and loss from market changes.

Optional<String> boughtNotional

Amount bought MTM

Optional<String> dayPnl

Sum of the profit and loss from intraday trading activities for the trading day.

Optional<String> netPnl

P&L after netting all realized and unrealized P&L, adjustments, dividends, change in accruals, income and expenses

Optional<String> positionPnl

P&L attributable to start-of-day (carried) positions from market movement during this trading day.

Optional<String> soldNotional

Amount sold MTM

class PortfolioHistorySegment:
LocalDate date

The date for this segment

formatdate
String eodEquity

The equity at the end of the trading day.

String realizedPnl

Sum of the profit and loss realized from position closing trading activity.

String sodEquity

The equity at the start of the trading day.

String unrealizedPnl

Sum of the profit and loss from market changes.

Optional<String> boughtNotional

Amount bought MTM

Optional<String> dayPnl

Sum of the profit and loss from intraday trading activities for the trading day.

Optional<String> netPnl

P&L after netting all realized and unrealized P&L, adjustments, dividends, change in accruals, income and expenses

Optional<String> positionPnl

P&L attributable to start-of-day (carried) positions from market movement during this trading day.

Optional<String> soldNotional

Amount sold MTM

class RiskSettings:

Risk settings for an account

Optional<String> maxNotional

The maximum notional value available to the account When a null/undefined value is observed, it indicates that there is no available data.