Quickstart

Get your OCSE Trader agent up and running in under 5 minutes

Installation

Follow these steps to set up your local development environment.

1. Clone the Repository

git clone https://github.com/OnChainStockExchange/ocse-agent.git
cd ocse-agent

2. Install Dependencies

npm install

3. Configure Environment Variables

Create a .env.local file in the root directory and add your API keys.

ANTHROPIC_API_KEY=sk-ant-...
BRAVE_API_KEY=...
SOLANA_PRIVATE_KEY=...
NEXT_PUBLIC_SOLANA_RPC_URL=https://api.mainnet-beta.solana.com

Never share your SOLANA_PRIVATE_KEY. Ensure it is added to your .gitignore.

Running the Application

OCSE Trader consists of two main components: the Dashboard and the Agent.

Start the Dashboard

The dashboard provides a visual interface for reports and portfolio tracking.

npm run dev

The dashboard will be available at http://localhost:3000.

Start the Agent Loop

The agent runs the autonomous trading logic in the background.

npm run start-agent

Next Steps

Now that your agent is running, you can explore the architecture: