What it can do
- POST /submit-tradeSubmit a trade for tax calculation. Computes net profit after fees, applies configured tax percentage, generates USDC transfer instruction to tax wallet, and returns full breakdown. Idempotent by trade_id. Tiered pricing: $0.005 for trades under $1K, $0.01 for $1K-$10K, $0.025 for $10K-$100K, $0.05 for $100K+.
- POST /configureSet or update user tax configuration including tax percentage, tax wallet address, minimum profit threshold, and auto-convert toggle. Configuration is stored per wallet address.
- GET /config/:walletRetrieve current tax configuration for a wallet address. Free endpoint, no payment required.
- GET /trade/:trade_idLook up a previously processed trade by trade_id. Returns full calculation breakdown. Free endpoint.
- GET /healthHealth check endpoint. Returns service status, uptime, and trade processing stats.