Back to list
unarmedpuppy

user-activity

by unarmedpuppy

0🍴 0📅 Jan 20, 2026

SKILL.md


name: user-activity description: Pull trading activity from Polymarket for any user when_to_use: When you need to analyze a Polymarket user's trading history, strategy, or patterns script: scripts/polymarket-user-activity.py

Polymarket User Activity Scraper

Pull trading activity from Polymarket's Data API for any user by username or wallet address.

Quick Start

# Analyze gabagool22's last 7 days of trading
python scripts/polymarket-user-activity.py gabagool22 --analyze

# Save to CSV
python scripts/polymarket-user-activity.py gabagool22 --days 7 --output data/gabagool22-trades.csv

# Save as JSON
python scripts/polymarket-user-activity.py gabagool22 --days 7 --output data/gabagool22-trades.json

# Use wallet address directly
python scripts/polymarket-user-activity.py 0x6031b6eed1c97e853c6e0f03ad3ce3529351f96d --analyze

Options

OptionDescriptionDefault
userUsername (e.g. gabagool22) or wallet address (0x...)Required
--days NNumber of days of history to fetch7
--limit NMaximum number of trades to fetch10000
--output PATHOutput file (CSV or JSON based on extension)None
--analyzePrint analysis summaryFalse
--jsonOutput raw JSON to stdoutFalse

Output Fields (CSV)

FieldDescription
datetimeISO timestamp
timestampUnix timestamp
sideBUY or SELL
outcomeUp or Down
titleMarket question
sizeNumber of shares
pricePrice per share
valuesize * price
slugMarket URL slug
eventSlugEvent identifier
conditionIdMarket condition hash
transactionHashOn-chain tx hash
proxyWalletTrader wallet

Analysis Summary

The --analyze flag prints:

  • Total trade count (BUY/SELL breakdown)
  • Total volume in USD
  • Date range covered
  • Up/Down position breakdown
  • Price statistics (avg/min/max)
  • Top 5 markets by trade count

Example Analysis Output

============================================================
TRADE ANALYSIS SUMMARY
============================================================

Total trades: 847
  - BUY: 623
  - SELL: 224

Total volume: $42,350.00

Date range: 2024-12-08 09:15 to 2024-12-15 14:30
  (7 days)

Outcome breakdown:
  - UP positions: 412
  - DOWN positions: 435

Price stats:
  - Average: $0.485
  - Min: $0.08
  - Max: $0.92

Top 5 markets by trade count:
  - Bitcoin up or down? (Dec 15, 2:00 PM ET)... (45 trades, $1,250.00)
  - Ethereum up or down? (Dec 15, 10:00 AM ET)... (38 trades, $980.00)
  ...
============================================================

API Details

Uses the Polymarket Data API:

  • Base URL: https://data-api.polymarket.com
  • Endpoint: /trades?user={wallet}&limit={n}&offset={n}
  • Rate limited: 0.5s delay between paginated requests

Strategy Analysis Tips

To analyze a trader's strategy:

  1. Pull their recent trades:

    python scripts/polymarket-user-activity.py gabagool22 --days 7 --output data/trades.csv
    
  2. Look for patterns:

    • Average position size
    • Entry price ranges (do they buy near 0.50 or closer to extremes?)
    • How often they add to positions vs close them
    • Time patterns (when do they trade most actively?)
    • Up/Down bias (do they favor one direction?)
  3. Compare to market conditions:

    • Do they trade more during high volatility?
    • How do they handle losing positions?

Score

Total Score

40/100

Based on repository quality metrics

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

0/10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

3ヶ月以内に更新がある

0/10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

0/5

Reviews

💬

Reviews coming soon