pi-currencies

Show AI cost in your local currencies — extends the pi footer with real‑time exchange rates from frankfurter.dev

Packages

Package details

extension

Install pi-currencies from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:pi-currencies
Package
pi-currencies
Version
1.0.0
Published
Jun 16, 2026
Downloads
not available
Author
hommesauvage
License
MIT
Types
extension
Size
25.1 KB
Dependencies
0 dependencies · 3 peers
Pi manifest JSON
{
  "extensions": [
    "./extensions/index.ts"
  ]
}

Security note

Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.

README

pi-currency

Show your AI costs in local currencies — right in the pi footer.

Replaces the built-in pi footer with one that appends real‑time currency conversions after the USD cost using exchange rates from frankfurter.dev (European Central Bank data).

Before:

~/project (main)
↑25k ↓13k R1.8M CH99.6% $0.029 4.7%/128k (auto)

After:

~/project (main)
↑25k ↓13k R1.8M CH99.6% $0.029 MYR0.13 CNY0.21 EUR0.026 4.7%/128k (auto)

Install

pi install npm:pi-currencies

Or try it without installing:

pi -e npm:pi-currencies

Configuration

By default the extension shows no currencies — you add what you want.

Use /currency-add CODE at runtime, or set PI_CURRENCY_LIST to pre‑configure a comma‑separated list of ISO 4217 codes:

PI_CURRENCY_LIST=MYR,CNY,THB,IDR,INR pi

Commands

Command Description
/currency-refresh Force‑refresh exchange rates from frankfurter.dev
/currency-list Show the configured currency list and current rates
/currency-add Interactive picker — search & select currencies to add
/currency-remove Interactive picker — select active currencies to remove

How it works

  1. On startup, the extension fetches live rates from https://api.frankfurter.dev/latest?base=USD.
  2. Rates are cached on disk (~/.pi/agent/data/pi-currency-rates.json) for 24 hours.
  3. A custom footer component renders the same stats as the built‑in footer, plus currency conversions after the $0.029 cost.
  4. The footer updates automatically after every turn.

License

MIT