@nye I personally feel the alpaca-py SDK is missing things (eg ‘news’), cumbersome and certainly not documented very well. That said, one can actually make any endpoint call. The key is to create a generic RESTClient (the various built in clients such as StockHistoricalDataClient and TradingClient are based on this class). The problem with the built in StockHistoricalDataClient client is that it has “v2” as the endpoint version but the news API uses “v1beta1”. There isn’t a way to override that.
So, to fetch news with the alpaca-py SDK 1) create a “news_client” then 2) use the get method to execute the news endpoint call. Something like this
One could execute any API call like this (there are similar methods for post, patch, put, and delete). The get method ‘parameters’ is just a dictionary of the endpoint parameters you wish to specify. Ensure to put both the parameter name and value in quotes.