Basket margin always returns zero

Kalai241
I have tried getting margin required for option basket order, I'm getting the response with in valid formats, but all the values are zero.

I have tried both python client and direct api, results are same

margins = kite.basket_order_margins(params=[
{
"exchange": day_config["exchange_fo"],
"tradingsymbol": pe_option_symbol_hedge,
"order_type": kite.ORDER_TYPE_MARKET,
"price": 0,
"trigger_price": 0,
"quantity": lot_count * lot_size,
"transaction_type": kite.TRANSACTION_TYPE_SELL,
"variety": kite.VARIETY_REGULAR,
"product": kite.PRODUCT_NRML,
},
{
"exchange": day_config["exchange_fo"],
"tradingsymbol": pe_option_symbol,
"order_type": kite.ORDER_TYPE_MARKET,
"price": 0,
"trigger_price": 0,
"quantity": lot_count * lot_size,
"transaction_type": kite.TRANSACTION_TYPE_SELL,
"variety": kite.VARIETY_REGULAR,
"product": kite.PRODUCT_NRML,
}
])
  • Kalai241
    Same response

    {
    "charges": {
    "brokerage": 0,
    "exchange_turnover_charge": 0,
    "gst": {
    "cgst": 0,
    "igst": 0,
    "sgst": 0,
    "total": 0
    },
    "sebi_turnover_charge": 0,
    "stamp_duty": 0,
    "total": 0,
    "transaction_tax": 0,
    "transaction_tax_type": ""
    },
    "final": {
    "additional": 0,
    "bo": 0,
    "cash": 0,
    "charges": {
    "brokerage": 0,
    "exchange_turnover_charge": 0,
    "gst": {
    "cgst": 0,
    "igst": 0,
    "sgst": 0,
    "total": 0
    },
    "sebi_turnover_charge": 0,
    "stamp_duty": 0,
    "total": 0,
    "transaction_tax": 0,
    "transaction_tax_type": ""
    },
    "exchange": "",
    "exposure": 0,
    "leverage": 0,
    "option_premium": 0,
    "pnl": {
    "realised": 0,
    "unrealised": 0
    },
    "span": 0,
    "total": 0,
    "tradingsymbol": "",
    "type": "",
    "var": 0
    },
    "initial": {
    "additional": 0,
    "bo": 0,
    "cash": 0,
    "charges": {
    "brokerage": 0,
    "exchange_turnover_charge": 0,
    "gst": {
    "cgst": 0,
    "igst": 0,
    "sgst": 0,
    "total": 0
    },
    "sebi_turnover_charge": 0,
    "stamp_duty": 0,
    "total": 0,
    "transaction_tax": 0,
    "transaction_tax_type": ""
    },
    "exchange": "",
    "exposure": 0,
    "leverage": 0,
    "option_premium": 0,
    "pnl": {
    "realised": 0,
    "unrealised": 0
    },
    "span": 0,
    "total": 0,
    "tradingsymbol": "",
    "type": "",
    "var": 0
    },
    "orders": [
    {
    "additional": 0,
    "bo": 0,
    "cash": 0,
    "charges": {
    "brokerage": 0,
    "exchange_turnover_charge": 0,
    "gst": {
    "cgst": 0,
    "igst": 0,
    "sgst": 0,
    "total": 0
    },
    "sebi_turnover_charge": 0,
    "stamp_duty": 0,
    "total": 0,
    "transaction_tax": 0,
    "transaction_tax_type": ""
    },
    "exchange": "",
    "exposure": 0,
    "leverage": 0,
    "option_premium": 0,
    "pnl": {
    "realised": 0,
    "unrealised": 0
    },
    "span": 0,
    "total": 0,
    "tradingsymbol": "",
    "type": "",
    "var": 0
    },
    {
    "additional": 0,
    "bo": 0,
    "cash": 0,
    "charges": {
    "brokerage": 0,
    "exchange_turnover_charge": 0,
    "gst": {
    "cgst": 0,
    "igst": 0,
    "sgst": 0,
    "total": 0
    },
    "sebi_turnover_charge": 0,
    "stamp_duty": 0,
    "total": 0,
    "transaction_tax": 0,
    "transaction_tax_type": ""
    },
    "exchange": "",
    "exposure": 0,
    "leverage": 0,
    "option_premium": 0,
    "pnl": {
    "realised": 0,
    "unrealised": 0
    },
    "span": 0,
    "total": 0,
    "tradingsymbol": "",
    "type": "",
    "var": 0
    }
    ]
    }
  • Kalai241
    Params:

    [{'exchange': 'NFO', 'tradingsymbol': 'NIFTY28OCT2525150PE', 'order_type': 'MARKET', 'price': 0, 'trigger_price': 0, 'quantity': 750, 'transaction_type': 'SELL', 'variety': 'regular', 'product': 'NRML'}, {'exchange': 'NFO', 'tradingsymbol': 'NIFTY28OCT2526200PE', 'order_type': 'MARKET', 'price': 0, 'trigger_price': 0, 'quantity': 750, 'transaction_type': 'SELL', 'variety': 'regular', 'product': 'NRML'}]
  • Kalai241
    Found it, symbol format is wrong, working fine after providing proper symbol
This discussion has been closed.