i am trying to make a script that fetch data from nepse tms api using python.
almost done but the only problem that i am stuck is generating **Host-Session-Id** headers
base64 decoding gives **MTI=-8adedd0d-a2ef-4f9e-b68b-80d3851adc34**
now all i have to do is get this value which i don’t know how
​
https://preview.redd.it/wd5e8rx23cx71.png?width=687&format=png&auto=webp&s=cda7ddf269b1adba76a31a2468d65e074256bdb0
More at: r/NepalStock by Remarkable_League_25
2 comments
Kunche endpoint use gareko? AFAIK, they have already blocked that public API
You will need to convert the `suid` from local storage to Base64-encoded ASCII string to get the value for `Host-Session-Id`.
In JavaScript, you can do that with a single line of code.
`btoa(localStorage.getItem(‘suid’));`