A command-line application for fetching and querying Steam Financial Partner data via the IPartnerFinancialsService API.
- Fetches financial data from Steam Partner API
- Stores data in a local SQLite database
- Query sales data by date, country, app, package, or custom SQL
- Debug tools for inspecting API data and troubleshooting
- Steam Financial API key from the Steamworks Partner portal
- Create a Financial API Group to get your API key
- See the IPartnerFinancialsService documentation for details
Download a pre-built binary from the GitHub Releases page:
-
Download the zip file for your platform
-
Extract the archive
-
Linux/macOS: Make the binary executable:
chmod +x steam-financial
-
macOS Gatekeeper Warning: If you see a warning that "Apple could not verify 'steam-financial' is free of malware", remove the quarantine attribute:
xattr -d com.apple.quarantine steam-financial
-
Run the executable:
steam-financial --help steam-financial --version
-
Clone this repository:
git clone https://github.com/RadialGames/steam-financial-cli.git cd steam-financial-cli -
Run the build script:
./build.sh
-
The executable will be available at
dist/steam-financial
This app stores your information in a local database file. This defaults to steam-financial.db, but you can specify a file with every command:
steam-financial --db my_db_name.dbThis is useful if you are managing multiple data sets or API keys.
init stores your Steam Financial API key and creates the designated database file. If you omit it, you will be prompted.
steam-financial init MY_API_KEYOptions:
--include-view-grants true|false: Include view grant data (default: true). Set to false to only fetch data owned by the partner.
steam-financial fetchFetches all new data since the last run. Options:
--force: reprocess all data from the beginning--date YYYY-MM-DD: fetch and overwrite data for a single date
For debugging or inspecting data flows:
--workers N: number of parallel workers (1-50, default: 50)--limit N: limit number of dates to process--highwatermark VALUE: override the highwatermark value
If you omit --start-date and/or --end-date for stats queries, the command defaults to the full available date range in the database.
# Total sales
steam-financial stats total-sales
# Total sales (explicit date range)
steam-financial stats total-sales --start-date 2025-01-01 --end-date 2025-01-31
# Sales by country
steam-financial stats by-country
# Sales by app
steam-financial stats by-app
# Sales by package
steam-financial --db ./steam-financial.db stats by-package --start-date 2025-01-01 --end-date 2025-01-31
# Custom SQL queries
steam-financial query "SELECT date, SUM(CAST(net_sales_usd AS REAL)) AS net_sales_usd FROM sales_data GROUP BY date ORDER BY date DESC LIMIT 10"
steam-financial query "SELECT * FROM sales_data WHERE date = '2025-01-01' LIMIT 10"Debug commands help troubleshoot issues with data fetching:
# Show changed dates from API without processing
steam-financial changed-dates
# Show changed dates with custom highwatermark
steam-financial changed-dates --highwatermark 123456
# Inspect API data for a specific date (shows breakdown by country, package, etc.)
steam-financial inspect-date 2025-01-15
# Include raw JSON sample in output
steam-financial inspect-date 2025-01-15 --rawThe inspect-date command is useful for understanding dates with many records. It shows breakdowns by:
- Line item type (Package, Bundle, etc.)
- Partner (your data vs. view grants from other publishers)
- Platform (Windows, Mac, Linux)
- Currency and country
- Package, app, and discount
By default, output is colorized only when running interactively (TTY).
--color auto(default): color only on TTY--color always: force ANSI colors (even when piped)--color never: disable colors and dynamic progress UI
Check the version number:
steam-financial --versionMIT