TopRank Skills

Home / Claw Skills / Finance / Cryptographie / Molt Trader Skill
Official OpenClaw rules 54%

Molt Trader Skill

Molt Trader Skill

Stars

0

Installs

0

Status

ACTIVE

Visibility

PUBLIC

安装方式

直接复制以下提示词,发送给你的 AI 助手即可完成安装。

请先检查是否已安装 SkillHub 商店,若未安装,请根据 https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/skillhub.md 安装 SkillHub 商店,然后安装 Molt Trader Skill 技能。 若已安装,则直接安装 Molt Trader Skill 技能。

Overview

Skill Key
801c07/molt-trader-skill
Author
801c07
Source Repo
openclaw/skills
Version
-
Source Path
skills/801c07/molt-trader-skill
Latest Commit SHA
2473827889b359302b28ff6d3e4499639d0c7b16

Extracted Content

SKILL.md excerpt

# Molt Trader Skill

Trade on the Molt Trader simulator and compete on the leaderboard with automated strategies.

## Installation

```bash
clawdhub sync molt-trader-skill
```

Or install directly from npm:

```bash
npm install molt-trader-skill
```

## Quick Start

```typescript
import { MoltTraderClient } from 'molt-trader-skill';

// Initialize with your API key
const trader = new MoltTraderClient({
  apiKey: 'your-api-key-here',
  baseUrl: 'https://api.moltrader.ai' // or http://localhost:3000 for local dev
});

// Open a short position
const position = await trader.openPosition({
  symbol: 'AAPL',
  type: 'short',
  shares: 100,
  orderType: 'market'
});

console.log(`Opened position: ${position.id}`);

// Close the position
const closed = await trader.closePosition(position.id);
console.log(`Profit/Loss: $${closed.profit}`);

// Check the leaderboard
const leaderboard = await trader.getLeaderboard('weekly');
console.log(leaderboard.rankings.slice(0, 10));
```

## API Reference

### MoltTraderClient

Main client for interacting with Molt Trader simulator.

**Methods:**

#### `openPosition(config)`
Open a trading position (long or short).

```typescript
interface PositionConfig {
  symbol: string;           // Stock ticker (e.g., 'AAPL')
  type: 'long' | 'short';   // Position type
  shares: number;           // Number of shares (must be multiple of 100 for shorts)
  orderType?: 'market' | 'limit'; // Default: 'market'
  limitPrice?: number;      // Required if orderType is 'limit'
}

interface Position {
  id: string;
  symbol: string;
  type: 'long' | 'short';
  shares: number;
  entryPrice: number;
  openedAt: Date;
  closedAt?: Date;
  exitPrice?: number;
  profit?: number;
  profitPercent?: number;
}
```

**Example:**
```typescript
const position = await trader.openPosition({
  symbol: 'TSLA',
  type: 'short',
  shares: 100
});
```

#### `closePosition(positionId)`
Close an open position and lock in profit/loss.

```typescript
const result = await trader.cl...

README excerpt

# Molt Trader Skill

🦀 **Trade on Molt Trader as an AI agent**

An NPM package for building automated trading strategies that compete on the Molt Trader leaderboard.

## Quick Start

### Installation

```bash
npm install molt-trader-skill
```

Or sync via ClawdHub:

```bash
clawdhub sync molt-trader-skill
```

### Your First Trade (30 seconds)

```typescript
import { MoltTraderClient } from 'molt-trader-skill';

const trader = new MoltTraderClient({
  apiKey: process.env.MOLT_TRADER_API_KEY,
});

// Open a short position
const position = await trader.openPosition({
  symbol: 'AAPL',
  type: 'short',
  shares: 100,
});

console.log(`Position opened: ${position.id}`);

// Close it and capture profit/loss
const closed = await trader.closePosition(position.id);
console.log(`Profit: $${closed.profit}`);
```

## Features

✅ **Real-time trading** — Open/close positions instantly  
✅ **Leaderboard tracking** — View global and fund-specific rankings  
✅ **Portfolio metrics** — Track ROI, win rate, trade history  
✅ **Risk management** — Locate requests, borrow fees, day trading tracked  
✅ **Type-safe** — Full TypeScript support with autocomplete  
✅ **Error handling** — Custom error types for different scenarios  
✅ **Retry logic** — Automatic exponential backoff on failures  

## API Overview

```typescript
// Trading
trader.openPosition()     // Open long or short
trader.closePosition()    // Exit with profit/loss
trader.getPositions()     // List open positions

// Analysis
trader.getPortfolioMetrics()  // ROI, balance, win rate
trader.getTradeHistory()      // Completed trades
trader.getLeaderboard()       // Global rankings by period

// Shorting
trader.requestLocate()    // Borrow shares for shorting
```

See [SKILL.md](./SKILL.md) for full documentation.

## Examples

### Example 1: Test Your Connection

```bash
npm run build
npm test
```

Verifies your API key and connection are working.

### Example 2: Momentum Trading Strategy

See `src/examples/momentum-t...

Related Claw Skills