Alpaca Setup
Alpaca is the simplest broker to connect to Ordertune. It uses API key authentication — no local gateway software required. Alpaca supports both paper trading (simulated) and live trading.
Start with paper trading to verify your setup before switching to a live account.
Requirements
- An Alpaca account (free to create at alpaca.markets (opens in a new tab))
- An active Ordertune subscription
Paper Trading Setup
Create Your Alpaca Account
Go to alpaca.markets (opens in a new tab) and sign up. You do not need to fund the account to use paper trading.
Switch to Paper Trading
In the Alpaca dashboard, ensure you are in the Paper Trading environment. Look for the toggle in the top-right corner of the Alpaca dashboard — it should show Paper mode.
Generate API Keys
Go to Paper Trading → API Keys in the left sidebar. Click Regenerate (or Generate if this is your first time). A dialog shows your:
- API Key ID — begins with
PKfor paper keys - Secret Key — shown only once; copy it immediately
Connect in Ordertune
- Log in to platform.ordertune.com (opens in a new tab)
- Open Settings (gear icon, top right)
- Go to the Broker tab
- Select Alpaca Paper from the broker dropdown
- Enter your API Key ID and Secret Key
- Click Connect
Verify the Connection
After connecting, click Test Connection. If successful, you will see your paper portfolio balance displayed. The broker status indicator turns green.
Your Secret Key is shown only once in Alpaca's dashboard. If you lose it, you must regenerate your keys.
Live Trading Setup
Live trading follows the same steps as paper trading, with two differences:
- In Alpaca, switch to the Live Trading environment using the toggle in the top-right
- Go to Live Trading → API Keys and generate live keys (begin with
AK) - In Ordertune Settings, select Alpaca Live from the broker dropdown and enter your live keys
Live keys interact with real capital. Verify your position size settings in Ordertune before submitting live orders.
API Endpoints
| Environment | API Base URL |
|---|---|
| Paper | https://paper-api.alpaca.markets |
| Live | https://api.alpaca.markets |
Ordertune selects the correct endpoint automatically based on whether you chose Alpaca Paper or Alpaca Live in settings.
Troubleshooting
"Invalid API key" error → Check that you copied both the Key ID and Secret Key correctly. Secret Keys are case-sensitive.
Balance shows $0 → Paper accounts start with a simulated $100,000. If your balance shows $0, confirm you are in Paper mode, not Live mode.
Orders not submitting → Check that your API keys have Trading permissions enabled in the Alpaca dashboard.