warera-fetch: a CLI for the WarEra API

majimaApril 23, 2026news

If you saw my last post about documenting the WarEra API, the CLI I
mentioned there is now public too.

I'd been using it privately since before the docs. It's what I used to
call the endpoints and explore the responses while building that project.
Messy enough that sharing it would've meant a guided tour.

So I cleaned it up. Consistent flags across commands, proper auth
handling, retry logic. Same project underneath, just tidy enough to hand
to someone.

warera-fetch is a single Python file. First run installs its own
dependencies. After that you just call it.

The commands cover most of what the game tracks: battles, market prices,
rankings, events, user profiles, military units, parties, countries,
regions. The --url flag lets you pass a full WarEra URL and it extracts
the ID. --humanize makes the output readable instead of raw JSON. raw is
the escape hatch if you want to hit any endpoint the built-in commands
don't cover.

Auth is through WARERA_API_KEY or a .warera_token file. The client backs
off and retries on rate limit errors automatically.

Same disclaimer as the docs: unofficial, not affiliated with WarEra, could
go stale when the game updates. Source is at
github.com/majimawrks/warera-fetch. If you've got endpoints worth
wrapping, PRs are open.

warera-fetch: a CLI for the WarEra API | War Era