Return proper 4XX status codes for client errors to prevent load balancers from misinterpreting input validation failures as server errors. Add centralized ApiResult type and ApiErrorCode enum for consistent handling.
This allows fetching historical asset prices from the blockchain.