Please visit our API documentation page to get more information on market data examples.

Market Data Examples - Documentation | Alpaca
Alpaca API lets you build and trade with real-time market data for free.