Summary
The current futarchy CLI is out of sync with the live API in a couple of important ways:
futarchy buy sends budget as a JSON number, but the API currently expects a string.
futarchy sell appears to have the same mismatch (amount is modeled as a float in the CLI, but the API schema expects a string).
- The API now exposes
GET /v1/me/activity, but the CLI has no command for account activity/history, so users cannot inspect their own trade history from the tool.
futarchy me only shows balance + locks/positions, which made it look like there was no trade history even when activity existed.
Reproduction
1. buy fails with 422
Using the currently installed CLI:
Result:
Error: HTTP 422: [{'type': 'string_type', 'loc': ['body', 'budget'], 'msg': 'Input should be a valid string', 'input': 1.0}]
The OpenAPI schema currently publishes:
BuyRequest.budget: string
SellRequest.amount: string
but the CLI implementation parses these as float and passes them through as numeric JSON values.
2. Account history exists in the API, but not in the CLI
The API publishes:
with description:
Get authenticated user's account activity with cursor pagination.
This endpoint returns the exact data users need to understand past trades, refunds, settlements, and credits. Example activity observed in production included:
- initial credits
- bought YES/NO
- resolved market loss
- void refund for YES/NO
However, the CLI currently exposes only:
markets
market
login
logout
update
me
buy
sell
There is no activity or history command, and me does not mention prior transactions.
Why this matters
buy is effectively broken against the live API unless users bypass the CLI and call the API directly.
sell is likely broken for the same reason.
- Users cannot audit what happened to their funds from the CLI, especially after market resolution / void events.
- This makes the CLI feel unreliable even when the backend has the right data.
Suggested fixes
- Serialize
budget and amount as strings before POSTing to the API.
- Add a
futarchy activity (or history) command backed by GET /v1/me/activity.
- Consider surfacing a short note in
futarchy me when recent account activity exists, or link users to the new history command.
- Add a CLI/API compatibility test so schema drift like this is caught earlier.
Extra context
I confirmed this against the live API on 2026-03-17:
GET /openapi.json includes /v1/me/activity
BuyRequest.budget is string
SellRequest.amount is string
- the CLI still posts numeric values for
buy/sell
Summary
The current
futarchyCLI is out of sync with the live API in a couple of important ways:futarchy buysendsbudgetas a JSON number, but the API currently expects a string.futarchy sellappears to have the same mismatch (amountis modeled as a float in the CLI, but the API schema expects a string).GET /v1/me/activity, but the CLI has no command for account activity/history, so users cannot inspect their own trade history from the tool.futarchy meonly shows balance + locks/positions, which made it look like there was no trade history even when activity existed.Reproduction
1.
buyfails with 422Using the currently installed CLI:
Result:
The OpenAPI schema currently publishes:
BuyRequest.budget: stringSellRequest.amount: stringbut the CLI implementation parses these as
floatand passes them through as numeric JSON values.2. Account history exists in the API, but not in the CLI
The API publishes:
with description:
This endpoint returns the exact data users need to understand past trades, refunds, settlements, and credits. Example activity observed in production included:
However, the CLI currently exposes only:
marketsmarketloginlogoutupdatemebuysellThere is no
activityorhistorycommand, andmedoes not mention prior transactions.Why this matters
buyis effectively broken against the live API unless users bypass the CLI and call the API directly.sellis likely broken for the same reason.Suggested fixes
budgetandamountas strings before POSTing to the API.futarchy activity(orhistory) command backed byGET /v1/me/activity.futarchy mewhen recent account activity exists, or link users to the new history command.Extra context
I confirmed this against the live API on 2026-03-17:
GET /openapi.jsonincludes/v1/me/activityBuyRequest.budgetisstringSellRequest.amountisstringbuy/sell