Loading...
Loading...

๐Ÿ”ง Setup Guide

The quick-start used the yfinance data source (not production suitable) and signals-only mode, so no credentials were needed.
To paper-trade or go live you'll add two things:

  1. A broker (sends orders)
  2. A data provider (streams fresh market data)

The stratequeue setup wizard writes your keys to
~/.stratequeue/credentials.env, which is auto-loaded on every run.

๐Ÿ—๏ธ Credentials are stored locally in plain text.
If you prefer, export the variables in your shell instead and skip the wizard.

Setup Demo Interactive setup wizard walkthrough


1 ยท Run the interactive wizard

# Ensure questionary is installed (pulled in by default)
pip install stratequeue

# Launch the menu
stratequeue setup

Choose "Broker" first, then "Data Provider".
StrateQueue will confirm success and tell you to run stratequeue status.

Example session (Alpaca + Polygon)

๐Ÿ”ง StrateQueue Setup
โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
? What would you like to configure?  Broker (trading platform credentials)
? Select broker to configure:  Alpaca (US stocks, ETFs, crypto)

๐Ÿ“‹ Alpaca Setup
Get your API keys from: https://app.alpaca.markets/

? Select trading mode:  Paper Trading
? Paper API Key: โ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ข
? Paper Secret Key: โ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ข

๐Ÿ”’ Credentials saved to /Users/you/.stratequeue/credentials.env
โœ… Alpaca credentials saved.
๐Ÿ’ก Test your setup with: stratequeue status

2 ยท Manual & non-interactive options

Prefer to handle environment variables yourself or on a server?

export PAPER_KEY=pk_your_key
export PAPER_SECRET=ps_your_secret
export POLYGON_API_KEY=poly_key
export DATA_PROVIDER=polygon

StrateQueue looks for variables in this order:

  1. Variables already in the current shell
  2. .env in the project folder
  3. ~/.stratequeue/credentials.env

3 ยท Environment variables reference

Type Mode Required variables
Broker โ€“ Alpaca Paper (recommended) PAPER_KEY, PAPER_SECRET, PAPER_ENDPOINT (defaults to https://paper-api.alpaca.markets)
Broker โ€“ Alpaca Live (real money) ALPACA_API_KEY, ALPACA_SECRET_KEY, ALPACA_BASE_URL (defaults to https://api.alpaca.markets)
Data - Polygon โ€” POLYGON_API_KEY, DATA_PROVIDER=polygon
Data - CoinMarketCap โ€” CMC_API_KEY, DATA_PROVIDER=coinmarketcap
Data - Demo โ€” (no keys needed)

4 ยท Verify your setup

stratequeue status          # checks broker credentials
stratequeue deploy ...      # run your strategy with --paper or --live

If something is missing you'll see clear โŒ or โš ๏ธ messages along with a fix tip.


5 ยท Troubleshooting

Symptom Fix
โŒ Not detected: Missing required Alpaca environment variables Re-run the wizard or export the keys manually
Wizard complains about questionary pip install questionary
Credentials file ignored Remember that shell exports override .env & credentials.env

๐ŸŽ‰ You're ready!

Deploy with --paper for a dry-run, or --live once you're confident.