Skip to main content
GET
/
tools
/
alpaca
/
get_account
{
  "provider": "<string>",
  "id": "<string>",
  "status": "<string>",
  "currency": "<string>",
  "cash": "<string>",
  "buying_power": "<string>",
  "equity": "<string>",
  "portfolio_value": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "provider_fields": {}
}

alpaca_get_account

tools = trading.alpaca(
    api_key=os.environ["ALPACA_KEY"],
    api_secret=os.environ["ALPACA_SECRET"],
    model="openai",
    paper=True,
    minimal=True,
    include=["alpaca_get_account"],
)
Options
  • include / exclude: filter which tools are exposed (use full names like alpaca_get_account).
  • minimal: omit provider and provider_fields when True.
  • paper: use Alpaca paper trading instead of live trading.

Body

application/json

This is a request to obtain information. Your API keys are required.

Response

Account (OpenTools trading schema).

provider
string | null

Trading provider identifier. Omitted when minimal=True.

id
string | null

Account ID.

status
string | null

Account status.

currency
string | null

Account currency (e.g. USD).

cash
string | null

Cash balance.

buying_power
string | null

Buying power.

equity
string | null

Equity.

portfolio_value
string | null

Portfolio value.

created_at
string<date-time> | null

Created timestamp.

provider_fields
object

Extra provider-specific fields (omitted when minimal=True).