checksum error in python login

Kite Connect authentication issue — persistent Invalid checksum

App type: Connect
App status: Active
Kite Connect subscription: Valid
API key: 16 characters
API secret: 32 characters
Python SDK: official KiteConnect
Fresh request token: 32 characters
Checksum: SHA256(api_key + request_token + api_secret)
generate_session() returns: TokenException: Invalid ‘checksum’

I tested this using a standalone script with the API key and API secret entered directly from the active Connect application, independent of my trading application. The login succeeds and produces a fresh request token, but /session/token rejects it with Invalid checksum.

Please verify whether there is an account/application-side issue with session-token generation for this Connect app.

The Invalid checksum error generally indicates that the api_key, api_secret, or request_token being used for the token exchange does not match.

We have verified this at our end and there is no issue with the APIs.

Please try generating a fresh request_token and exchanging it for an access_token immediately, since the request token is short-lived and can be used only once.

Also, please ensure that you are following the login flow exactly as outlined in the Kite Connect API documentation.

You may also refer to this similar discussion on the Kite Connect forum

1 Like