alpacahq / alpacahq/Alpaca-API

no account updates on submitted orders?

Đang mở
#75 5 bình luận 0 reaction 0 người được giao Xem trên GitHub
feature request
Ngôn ngữ chính
Không có dữ liệu ngôn ngữ
Star
174
Fork
17
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

(paper trading; v1)

Is it intentional that no account updates are sent when an order is submitted/filled?

According to [the documentation](https://docs.alpaca.markets/api-documentation/web-api/streaming/#account-updates):
> This stream provides clients with updates pertaining to their brokerage accounts at Alpaca, including balance information.

Yet, I don't get an updated when I submit an order and it is filled subsequently. Shouldn't the account balance change when doing that?

When I explicitly retrieve `/v1/account` information I see a difference in cash:
55279.74 USD beforehand, 54987.27 USD now

I have the following code for streaming updates:
```py
import alpaca_trade_api as tradeapi

conn = tradeapi.StreamConn()

@conn.on(r'account_updates')
async def on_account_updates(conn, channel, account):
print('account', account)

# blocks forever
conn.run(['account_updates'])
```

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.