Historical Data API - Unable to form the Request

Swarochisha
Hi
I enabled historical data API this morning. I am unable to get any data for the below command. Could you please help ?
The same access token works fine for my live API calls for today.

curl "https://api.kite.trade/instruments/historical/5633/minute?from=2020-04-17+09:30:00&to=2020-04-17+12:00:00" -H "X-Kite-Version: 3" -H "Authorization:q728j3xrxx1tu777 api_key:ewBF0ZAd81Ffm6O0TsL7wrFT9EkQ000"

The below is the error I get:
{"status":"error","message":"unknown Authorization scheme","data":null,"error_type":"InputException"}

I swap the Authorization and api_key values above, and I get the same error. Please help.
(I removed last 3 characters of my actual keys for security reasons...)

Can you please help ?

Also, the documenation show it as below: What is 'token' (After Authorization) and what is 'access token' (after api_key) ? api_key is something thats tied down to my active application and is available in my account ? So, why should access_token be passed against the api_key key in the below syntax ?

curl "https://api.kite.trade/instruments/historical/5633/minute?from=2015-12-28+09:30:00&to=2016-01-01+10:30:00"
-H "X-Kite-Version: 3" \
-H "Authorization: token api_key:access_token" \


  • sujith
    You need to send auth header like this "Authorization:token <api_key>:<access_token>"

    You need to send text token and then api_key and access_token.

    If you have subscribed to historical data today then make sure to create a new access token since permissions are assigned while creating access token.
  • Swarochisha
    Thanks @Sujith. The depiction above using <> for variable-to-substitute really helped.
This discussion has been closed.