It looks like you're new here. If you want to get involved, click one of these buttons!
kiteconnect.exceptions.InputException: Invalid `api_key` or `access_token`
My codes for login and placing order are as below:kite = KiteConnect(api_key=api_key)
data = kite.generate_session(request_token, api_secret)
kite.set_access_token(data["access_token"])
latest_order = kite.place_order(tradingsymbol=scrip_name, exchange='NSE', quantity=1, transaction_type='BUY',
order_type='LIMIT', product='CNC', validity='DAY', variety='REGULAR', price=price,
tag='BUY NO ' + str(total_buys + 1))
Please help solve or clarify the issue.
You need to send variety as
regular
not as REGULAR. Go through required param detail here.