Overview & authentication

Introduction to the My Prop Journal REST API, API keys, and how to call the API.

Introduction

The My Prop Journal REST API provides programmatic access to your trading data, performance metrics, accounts, and playbooks. Build custom integrations, export your data, create analytics dashboards, or connect to AI tools like Claude Desktop.

Who can use the API:

  • Available to paid subscribers only
  • All data is automatically scoped to your account
  • Industry-standard REST architecture with JSON responses

What you can do:

  • Retrieve trades with advanced filtering (20+ filters including tags, strategies, outcomes)
  • Access comprehensive performance analytics (overview, detailed, calendar, grouped)
  • Manage trading accounts (prop and retail) with full filter support
  • Organize content with custom tags and tag groups
  • Track payouts with cumulative calculations
  • Upload and manage trading documents
  • Query playbooks and strategies
  • Create and manage trade plans, write-ups, and report cards
  • Work with content in JSON, HTML, or Markdown formats
  • Extract media URLs from your journal entries
  • Browse prop firm directory
  • Export your complete trading history

Quick start

1. Create an API key

Navigate to Settings → API Keys in your My Prop Journal account:

  1. Click "Create API Key"
  2. Enter a descriptive name (e.g., "Python Analytics Script")
  3. Copy the key immediately — it's shown only once
  4. Store it securely (treat it like a password)

2. Make your first request

curl https://app.mypropjournal.com/api/v1/trades \
  -H "Authorization: Bearer mpj_your_api_key_here"

Expected response:

{
  "data": [
    {
      "id": "fd07b82a-164c-4c24-885a-7f4db54dab62",
      "symbol": "NQ",
      "side": "short",
      "gross_pnl": 160,
      "net_pnl": 158,
      "entry_date": "2026-02-05",
      "status": "win"
    }
  ],
  "pagination": {
    "page": 1,
    "limit": 50,
    "total": 305,
    "totalPages": 7
  }
}

3. Explore the API

Browse the documentation sections in the left sidebar to learn about:

  • Accounts — Manage prop and retail accounts with advanced filters
  • Trades — CRUD operations with 20+ filters including tags and strategies
  • Performance — Analytics and statistics (overview, detailed, calendar, grouped)
  • Tags — Organize content with custom tag groups and tags
  • Payouts — Track prop firm withdrawals with cumulative calculations
  • Documents — Upload and manage trading documents (PDFs, images)
  • Prop Firms — Browse the prop firm directory
  • Content Formats — Multi-format content and media extraction
  • Trade Plans — Pre-trade planning and business plans
  • Trade Write-ups — Post-trade reviews and lessons
  • Strategies — Trading approaches and rules
  • Report Cards — Daily/weekly/monthly performance reviews
  • Chart Books — Organize chart screenshots
  • Playbooks — Query your trading strategies
  • Filters Reference — Comprehensive guide to all filters

Authentication

API key format

All API keys follow this structure:

  • Prefix: mpj_ (identifies My Prop Journal keys)
  • Format: mpj_[random_string]
  • Example: mpj_a1b2c3d4e5f6g7h8i9j0
  • Storage: Keys are bcrypt-hashed in the database
  • Security: Plain-text key is displayed only at creation time

Authorization header

Include your API key in every request using the Authorization header with the Bearer scheme:

GET /api/v1/trades HTTP/1.1
Host: app.mypropjournal.com
Authorization: Bearer mpj_your_api_key_here
Content-Type: application/json

Example implementations

JavaScript / Node.js:

const API_KEY = process.env.MPJ_API_KEY;
const BASE_URL = 'https://app.mypropjournal.com/api/v1';

async function getTrades() {
  const response = await fetch(`${BASE_URL}/trades`, {
    headers: {
      'Authorization': `Bearer ${API_KEY}`,
      'Content-Type': 'application/json'
    }
  });
  
  if (!response.ok) {
    throw new Error(`HTTP ${response.status}: ${response.statusText}`);
  }
  
  return response.json();
}

Python:

import os
import requests

API_KEY = os.environ['MPJ_API_KEY']
BASE_URL = 'https://app.mypropjournal.com/api/v1'

def get_trades():
    headers = {
        'Authorization': f'Bearer {API_KEY}',
        'Content-Type': 'application/json'
    }
    response = requests.get(f'{BASE_URL}/trades', headers=headers)
    response.raise_for_status()
    return response.json()

trades_data = get_trades()
print(f"Total trades: {trades_data['pagination']['total']}")

cURL:

export MPJ_API_KEY="mpj_your_api_key_here"

curl https://app.mypropjournal.com/api/v1/trades \
  -H "Authorization: Bearer $MPJ_API_KEY" \
  -H "Content-Type: application/json"

Base URL

All API endpoints are prefixed with /api/v1:

https://app.mypropjournal.com/api/v1

Available endpoints:

Core Resources:

  • /api/v1/accounts — Trading accounts (prop & retail)
  • /api/v1/trades — Trade management with advanced filtering
  • /api/v1/performance — Performance analytics (overview, detailed, calendar, grouped)

Organization & Planning:

  • /api/v1/tags — Tag groups and tags for content organization
  • /api/v1/trade-plans — Pre-trade planning and business plans
  • /api/v1/trade-writeups — Post-trade analysis and reviews
  • /api/v1/strategies — Trading strategies and approaches
  • /api/v1/report-cards — Performance reviews (daily/weekly/monthly)
  • /api/v1/chart-books — Chart screenshot organization
  • /api/v1/playbooks — Strategy playbooks

Financial & Documentation:

  • /api/v1/payouts — Prop firm payout tracking
  • /api/v1/documents — Document uploads and management
  • /api/v1/prop-firms — Prop firm directory (read-only)

API key management

Multiple keys

You can create multiple API keys for different use cases:

  • MCP Server — For Claude Desktop integration
  • Python Analytics — For custom scripts
  • Mobile App — For iOS/Android applications
  • Backup Script — For automated exports

Each key is tracked independently with:

  • Creation timestamp
  • Last used timestamp
  • Descriptive name for identification

Revoking keys

Revoke any API key instantly from Settings → API Keys:

  1. Locate the key in your list
  2. Click the "Revoke" button
  3. Confirm the deletion

Note: Revoked keys stop working immediately. Any requests using a revoked key will receive a 401 Unauthorized response.

Security best practices

  • Never commit API keys to source control (git, GitHub, etc.)
  • Use environment variables to store keys in your applications
  • Rotate keys regularly if they're used in multiple places
  • Create separate keys for different applications or scripts
  • Monitor "last used" timestamps to identify unused keys
  • Revoke immediately if a key is compromised

Key features

Multi-format content support

All journal entries (trade plans, write-ups, strategies, report cards) support three content formats:

# Get content as Markdown (ideal for MCP servers and LLMs)
GET /api/v1/trade-plans/123?format=markdown

# Get content as HTML (ready for web display)
GET /api/v1/trade-writeups/456?format=html

# Get all formats at once (default)
GET /api/v1/strategies/789

Benefits:

  • ✅ No TipTap library required
  • ✅ Work with Markdown for external tools
  • ✅ Get HTML for immediate display
  • ✅ Submit content in any format (JSON/HTML/Markdown)

Learn more: Content Formats

Media URL extraction

Automatically extract all image and video URLs from your content:

GET /api/v1/trade-plans/123?include_media=true

Response includes:

{
  "data": {
    "title": "My Plan",
    "media": {
      "images": ["https://example.com/chart1.jpg"],
      "videos": [{"src": "...", "originalUrl": "..."}],
      "all": ["https://example.com/chart1.jpg", "..."]
    }
  }
}

Use cases:

  • Build image galleries
  • Download all media assets
  • Check for broken links
  • Create preview thumbnails

Next steps

Now that you understand authentication, explore the specific endpoints:

Need help? Check the Use Cases section for integration examples.