alpacahq / Alpaca-API

The Alpaca API is a developer interface for trading operations and market data reception through the Alpaca platform.
https://alpaca.markets/
143 stars 13 forks source link

Market Clock to Return Information about Pre/extended Hours #252

Closed Chacoon3 closed 3 weeks ago

Chacoon3 commented 4 months ago

Is your feature request related to a problem? Please describe. This request is related to the v2/clock endpoint.

Describe the solution you'd like I hope that the endpoint can give information about whether or not it is pre-market, regular, or extended hours. It's basically a categorical variable which can be "pre-market", "regular", "extended", and "closed".

Additional context Currently the endpoint has the field "is_open" which is true during the regular hours and false otherwise. This does not tell application programs whether or not it is pre-market or extended hours. However, some application programs may need to execute outside the regular hours as well and the behavior varies according to the market hour state. So this feature can be very helpful.