# Account & trading

What is in your account, and the three tools that trade. Each trading tool works only if you let the AI app place orders, and tells you what it will do before it does it.

## list_exchange_connections

Lists your exchange connections and whether each is the test network or real.

Marks: Reads only.

### Inputs

Takes no inputs.

What the AI app reads: List the user's exchange connections (id, exchange, testnet or real). The trading tools need a connectionId from here.

## get_account

Balance, open positions and open orders on one connection.

Marks: Reads only.

### Inputs

- `connectionId`: id, required. From `list_exchange_connections`.

What the AI app reads: Balance, open positions and open orders for one exchange connection.

## place_order

Places a market or limit order. Real money on a real connection.

Marks: Only with May place orders on · Two steps: tells you first.

### Inputs

- `connectionId`: id, required. From `list_exchange_connections`.
- `symbol`: text (2–40 characters), required. A market as the exchange names it, like `BTC-PERP`, `HYPE-SPOT` or `xyz:AAPL-PERP`.
- `side`: one of `buy`, `sell`, required.
- `type`: one of `market`, `limit`, required.
- `size`: number (above 0), required.
- `price`: number (above 0).
- `reduceOnly`: `true` or `false`.
- `confirm`: `true` or `false`. Leave out the first time: the tool does nothing and asks the AI app to tell you exactly what it is about to do. It calls again with `true` once you have said yes. Default `false`.

What the AI app reads: Place an order on the exchange (real money on a real connection). This is a real trading action. Tell the user exactly what you are about to do, then call again with confirm: true.

## cancel_order

Cancels one open order.

Marks: Only with May place orders on · Two steps: tells you first.

### Inputs

- `connectionId`: id, required. From `list_exchange_connections`.
- `symbol`: text (2–40 characters), required. A market as the exchange names it, like `BTC-PERP`, `HYPE-SPOT` or `xyz:AAPL-PERP`.
- `orderId`: text (not empty, up to 100 characters), required.
- `confirm`: `true` or `false`. Leave out the first time: the tool does nothing and asks the AI app to tell you exactly what it is about to do. It calls again with `true` once you have said yes. Default `false`.

What the AI app reads: Cancel an open order by id. This is a real trading action. Tell the user exactly what you are about to do, then call again with confirm: true.

## close_position

Closes an open position at market.

Marks: Only with May place orders on · Two steps: tells you first.

### Inputs

- `connectionId`: id, required. From `list_exchange_connections`.
- `symbol`: text (2–40 characters), required. A market as the exchange names it, like `BTC-PERP`, `HYPE-SPOT` or `xyz:AAPL-PERP`.
- `confirm`: `true` or `false`. Leave out the first time: the tool does nothing and asks the AI app to tell you exactly what it is about to do. It calls again with `true` once you have said yes. Default `false`.

What the AI app reads: Close an open position at market. This is a real trading action. Tell the user exactly what you are about to do, then call again with confirm: true.

Updated: 2026-10-20

Web page: https://buildtrade.app/docs/tools/account-trading/
