Tracking Crypto Portfolio
Overview
Track cryptocurrency holdings with real-time CoinGecko valuations, allocation analysis, P&L tracking, and concentration risk alerts.
Prerequisites
- Python 3.8+ installed
- Dependencies:
pip install requests
- Internet connectivity for CoinGecko API access
- A portfolio JSON file with your holdings (see
references/implementation.md for format)
Instructions
Assess user intent - determine what portfolio view is needed:
- Quick check: total value and top holdings
- Holdings list: full breakdown of all positions
- Detailed analysis: allocations, P&L, risk flags
- Export: JSON or CSV for external tools
Run the portfolio tracker with appropriate options:
# Quick portfolio summary
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json
# Full holdings breakdown
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --holdings
# Detailed analysis with P&L and allocations
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --detailed
Export results for analysis tools or tax reporting:
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --format json --output portfolio_export.json
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --format csv --output portfolio.csv
Present results to the user:
- Show total portfolio value prominently
- Highlight 24h and 7d changes
- Explain allocation percentages
- Flag any concentration risks (positions > 25% allocation by default)
Output
Summary showing total value, 24h/7d changes, per-asset allocation, and concentration warnings for positions exceeding threshold:
==============================================================================
CRYPTO PORTFOLIO TRACKER Updated: 2026-01-14 15:30 # 2026 - current year timestamp
==============================================================================
PORTFOLIO SUMMARY: My Portfolio
------------------------------------------------------------------------------
Total Value: $125,450.00 USD
24h Change: +$2,540.50 (+2.07%)
7d Change: +$8,125.00 (+6.92%)
Holdings: 8 assets
TOP HOLDINGS
------------------------------------------------------------------------------
Coin Quantity Price Value Alloc 24h
BTC 0.500 $95,000.00 $47,500.00 37.9% +2.5%
ETH 10.000 $3,200.00 $32,000.00 25.5% +1.8%
SOL 100.000 $180.00 $18,000.00 14.4% +4.2%
WARNING: BTC (37.9%) exceeds 25% threshold
==============================================================================
Error Handling
| Error |
Cause |
Solution |
| Portfolio file not found |
Invalid path |
Check file path exists |
| Invalid JSON |
Malformed file |
Validate JSON syntax |
| Coin not found |
Unknown symbol |
Check symbol spelling, use standard symbols |
| API rate limited |
Too many requests |
Wait and retry, use caching |
See ${CLAUDE_SKILL_DIR}/references/errors.md for comprehensive error handling.
Examples
Portfolio tracking workflows from quick checks to detailed analysis and export:
# Basic portfolio check
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio ~/crypto/holdings.json
# All holdings sorted by allocation
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --holdings --sort allocation
# Detailed analysis with custom 15% threshold
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --detailed --threshold 15
# Export for tax software
python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --format csv --output tax_export.csv
Resources
${CLAUDE_SKILL_DIR}/references/implementation.md - Portfolio file format, CLI options, allocation thresholds, JSON format
${CLAUDE_SKILL_DIR}/references/errors.md - Comprehensive error handling
${CLAUDE_SKILL_DIR}/references/examples.md - Detailed usage examples
- CoinGecko API: https://www.coingecko.com/en/api
${CLAUDE_SKILL_DIR}/config/settings.yaml - Configuration options
1---
2name: tracking-crypto-portfolio
3description: |
4 Track cryptocurrency portfolio with real-time valuations, allocation analysis, and P&L tracking.
5 Use when checking portfolio value, viewing holdings breakdown, analyzing allocations, or exporting portfolio data.
6 Trigger with phrases like "show my portfolio", "check crypto holdings", "portfolio allocation", "track my crypto", or "export portfolio".
7
8allowed-tools: Read, Write, Bash(crypto:portfolio-*)
9version: 2.0.0
10author: Jeremy Longshore <jeremy@intentsolutions.io>
11license: MIT
12compatible-with: claude-code, codex, openclaw
13tags: [crypto, tracking-crypto]
14metadata:
15 source: https://skillmd.com/skills/aibot88/tracking-crypto-portfolio
16---
17
18# Tracking Crypto Portfolio
19
20## Overview
21
22Track cryptocurrency holdings with real-time CoinGecko valuations, allocation analysis, P&L tracking, and concentration risk alerts.
23
24## Prerequisites
25
261. **Python 3.8+** installed
272. **Dependencies**: `pip install requests`
283. Internet connectivity for CoinGecko API access
294. A portfolio JSON file with your holdings (see `references/implementation.md` for format)
30
31## Instructions
32
331. **Assess user intent** - determine what portfolio view is needed:
34 - Quick check: total value and top holdings
35 - Holdings list: full breakdown of all positions
36 - Detailed analysis: allocations, P&L, risk flags
37 - Export: JSON or CSV for external tools
38
392. **Run the portfolio tracker** with appropriate options:
40 ```bash
41 # Quick portfolio summary
42 python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json
43
44 # Full holdings breakdown
45 python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --holdings
46
47 # Detailed analysis with P&L and allocations
48 python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --detailed
49 ```
50
513. **Export results** for analysis tools or tax reporting:
52 ```bash
53 python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --format json --output portfolio_export.json
54 python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --format csv --output portfolio.csv
55 ```
56
574. **Present results** to the user:
58 - Show total portfolio value prominently
59 - Highlight 24h and 7d changes
60 - Explain allocation percentages
61 - Flag any concentration risks (positions > 25% allocation by default)
62
63## Output
64
65Summary showing total value, 24h/7d changes, per-asset allocation, and concentration warnings for positions exceeding threshold:
66
67```
68==============================================================================
69 CRYPTO PORTFOLIO TRACKER Updated: 2026-01-14 15:30 # 2026 - current year timestamp
70==============================================================================
71
72 PORTFOLIO SUMMARY: My Portfolio
73------------------------------------------------------------------------------
74 Total Value: $125,450.00 USD
75 24h Change: +$2,540.50 (+2.07%)
76 7d Change: +$8,125.00 (+6.92%)
77 Holdings: 8 assets
78
79 TOP HOLDINGS
80------------------------------------------------------------------------------
81 Coin Quantity Price Value Alloc 24h
82 BTC 0.500 $95,000.00 $47,500.00 37.9% +2.5%
83 ETH 10.000 $3,200.00 $32,000.00 25.5% +1.8%
84 SOL 100.000 $180.00 $18,000.00 14.4% +4.2%
85
86 WARNING: BTC (37.9%) exceeds 25% threshold
87
88==============================================================================
89```
90
91## Error Handling
92
93| Error | Cause | Solution |
94|-------|-------|----------|
95| Portfolio file not found | Invalid path | Check file path exists |
96| Invalid JSON | Malformed file | Validate JSON syntax |
97| Coin not found | Unknown symbol | Check symbol spelling, use standard symbols |
98| API rate limited | Too many requests | Wait and retry, use caching |
99
100See `${CLAUDE_SKILL_DIR}/references/errors.md` for comprehensive error handling.
101
102## Examples
103
104Portfolio tracking workflows from quick checks to detailed analysis and export:
105
106```bash
107# Basic portfolio check
108python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio ~/crypto/holdings.json
109
110# All holdings sorted by allocation
111python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --holdings --sort allocation
112
113# Detailed analysis with custom 15% threshold
114python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --detailed --threshold 15
115
116# Export for tax software
117python ${CLAUDE_SKILL_DIR}/scripts/portfolio_tracker.py --portfolio holdings.json --format csv --output tax_export.csv
118```
119
120## Resources
121
122- `${CLAUDE_SKILL_DIR}/references/implementation.md` - Portfolio file format, CLI options, allocation thresholds, JSON format
123- `${CLAUDE_SKILL_DIR}/references/errors.md` - Comprehensive error handling
124- `${CLAUDE_SKILL_DIR}/references/examples.md` - Detailed usage examples
125- CoinGecko API: https://www.coingecko.com/en/api
126- `${CLAUDE_SKILL_DIR}/config/settings.yaml` - Configuration options