美股歷史委託
Longbridge US 賬戶
此方法僅適用於美國數據中心賬戶。
查詢美股賬戶的歷史委託和待成交委託,支持分頁和篩選。
SDK Links
Parameters
SDK 方法參數。
| 名稱 | 類型 | 必填 | 描述 |
|---|---|---|---|
| symbol | string | 否 | 按標的篩選,例如 AAPL.US |
| action | int | 否 | 方向篩選:0=全部,1=買入,2=賣出(默認:0) |
| start_at | int64 | 否 | 開始時間(Unix 秒);0 = 最近 90 天 |
| end_at | int64 | 否 | 結束時間(Unix 秒);0 = 當前時間 |
| query_type | int32 | 否 | 0=全部,1=待成交,2=已成交(默認:0) |
| page | int32 | 否 | 頁碼,從 1 開始(默認:1) |
| limit | int32 | 否 | 每頁數量(默認:20) |
Request Example
Response
Response Example
json
{
"orders": [
{
"id": "701276261045858304",
"symbol": "AAPL.US",
"action": "Buy",
"order_type": "LO",
"status": "Filled",
"price": "185.00",
"quantity": "10",
"submitted_at": 1751866334,
"updated_at": 1751866400
}
],
"total_count": 1
}Response Status
| 狀態碼 | 描述 | 結構 |
|---|---|---|
| 200 | 成功 | QueryUSOrdersResponse |
| 400 | 請求錯誤 | None |
Schemas
QueryUSOrdersResponse
| 名稱 | 類型 | 必填 | 描述 |
|---|---|---|---|
| orders | USOrder[] | 是 | 符合篩選條件的委託列表 |
| total_count | int | 是 | 滿足條件的委託總數 |
USOrder
| 名稱 | 類型 | 描述 |
|---|---|---|
| id | string | 委託 ID |
| symbol | string | 交易標的,如 AAPL.US |
| action | string | 方向:Buy 或 Sell |
| order_type | string | 委託類型 |
| status | string | 委託狀態 |
| price | string | 委託價格 |
| quantity | string | 委託數量 |
| submitted_at | int64 | 提交時間(Unix 秒) |
| updated_at | int64 | 最後更新時間(Unix 秒) |