Export timesheets from Harvest with currency conversion via Wise exchange rates.
nix shell github:numtide/freelancer-toolbox#harvest-exporterSet the following environment variables (or use CLI flags):
| Variable | Description |
|---|---|
HARVEST_ACCOUNT_ID |
Your Harvest account ID |
HARVEST_BEARER_TOKEN |
API token from Harvest Developers |
HARVEST_USER |
(Optional) Filter by user name |
Export the previous month (default):
harvest-exporterExport specific months:
harvest-exporter --months 3 # March of current year
harvest-exporter --months 1 2 3 # Q1
harvest-exporter --months 6 --year 2024Export date range:
harvest-exporter --start 20240101 --end 20240131harvest-exporter --user "Jane Doe" # Specific user
harvest-exporter --all-users # All users (not just authenticated user)harvest-exporter --client "Acme Corp"Convert to a different currency (applies Wise exchange rate):
harvest-exporter --currency CHF
harvest-exporter --currency USDOverride the rate from Harvest:
harvest-exporter --hourly-rate 100harvest-exporter --format humanreadable # Default, human-readable text
harvest-exporter --format json # JSON for piping to other tools
harvest-exporter --format csv # CSV format
harvest-exporter --format table # Rich table formatBy default, a numtide agency rate (75%) is applied. To disable:
harvest-exporter --agency none --client "Direct Client"JSON output contains entries with:
{
"user": "Jane Doe",
"client": "Acme Corp",
"task": "Development",
"rounded_hours": 40.5,
"source_currency": "USD",
"source_hourly_rate": 100,
"source_cost": 4050,
"target_currency": "EUR",
"target_hourly_rate": 92.5,
"target_cost": 3746.25,
"exchange_rate": 0.925,
"start_date": "20240101",
"end_date": "20240131",
"agency": "numtide"
}Pipe JSON output to invoice generators:
harvest-exporter --format json > harvest.json
sevdesk-invoicer --customer "1234" harvest.jsonSee also:
- sevdesk-invoicer - Generate SevDesk invoices
- quipu - Generate Quipu invoices
- Monthly Invoicing Workflow