Julia interface to the Alpaca Trading API
Author dm13450
16 Stars
Updated Last
12 Months Ago
Started In
February 2022

Alpaca Markets

A work in progress Julia wrapper for the Alpaca Markets API.


Access Alpaca Markets market data API to retrieve stock and crypto market data.

Installation and Setup

AlpacaMarkets.jl is in the General Registry so you can simply install locally using Pkg.

You need to sign up to AlpacaMarkets to obtain your API keys. Once you've obtained the key and secret you can authenticate manually with

using AlpacaMarkets
AlpacaMarkets.auth(KEY, SECRET)

Rather than setting it manually each time I recommend you add it to your .julia/startup.jl or '.julia/config/startup.jl'


This is automatically be picked up by AlpacaMarkets.jl each time you start Julia.

Available Functions

All the historical market data API functions are available:

  • stock_bars, stock_quotes and stock_trades
  • stock_quotes_latest and stock_trades_latest
  • crypto_bars, crypto_quotes and crypto_trades

Plus the interface to their news API

  • news

Plus I've added helper functions to obtain data between two periods:

  • get_stock_quotes and get_stock_trades
  • get_crypto_trades

So you can pull some historical data as and when needed.

To Do

  • Integrate Trading API


Used By Packages

No packages found.