GetOrders() throws KiteConnect.DataException "The input string '' was not in a correct format"

sukantary
Hi Team,

Since 15-Jul-2026, I have started getting an exception while calling GetOrders() using the latest Tech.Zerodha.KiteConnect v5.2.0 NuGet package.

Environment:
SDK: Tech.Zerodha.KiteConnect 5.2.0
Framework: .NET 10
API:

Kite kite = new Kite(apiKey, AccessToken: accessToken, Debug: false);
var orders = kite.GetOrders();

Exception:

KiteConnect.DataException: 'The input string '' was not in a correct format. {"placed_by":"XXXXXX","account_id":"XXXXXX","order_timestamp":"2026-07-16 13:36:08","order_id":"260716191041454","exchange_order_id":"1700000097508329","parent_order_id":null,"status":"COMPLETE","status_message":null,"status_message_raw":null,"exchange_update_timestamp":"2026-07-16 13:36:08","exchange_timestamp":"2026-07-16 13:36:05","variety":"regular","modified":false,"auction_number":"","exchange":"NFO","tradingsymbol":"BANKNIFTY26JUL58600CE","instrument_token":15847170,"order_type":"LIMIT","transaction_type":"BUY","validity":"DAY","validity_ttl":0,"product":"NRML","quantity":90,"disclosed_quantity":0,"price":279.05,"trigger_price":0,"average_price":279.05,"filled_quantity":90,"pending_quantity":0,"cancelled_quantity":0,"market_protection":0,"meta_raw":null,"meta":{},"tag":null,"guid":"01X7HPYW3HZVKkI"}'

Root Cause:

After decompiling KiteConnect.dll v5.2.0, I found that the Order constructor contains the following code:

AuctionNumber = 0;

if (data.ContainsKey("auction_number"))
{
AuctionNumber = Convert.ToInt32(data["auction_number"]);
}

However, the API is now returning: "auction_number": ""

As a result, Convert.ToInt32("") throws: Input string '' was not in a correct format.

Questions:
1. Has there been any recent change in the Orders API response where auction_number is now returned as an empty string?
2. Is this a known issue in SDK v5.2.0?
3. Will a patched NuGet package be released?

Please fix the issue asap or help me find a workaround.

Thank you.
Sign In or Register to comment.