Unofficial lookup for historical SBI TT buy/sell forex rates, with nearest-prior-date fallback. Not affiliated with SBI. Data may be inaccurate, use at your own risk.
Project description
sbi-tt-rates
Lookup historical SBI TT (Telegraphic Transfer) buy/sell forex rates, with automatic fallback to the nearest prior trading day when a date has no published rate (weekends, holidays, no-publish days).
⚠️ Disclaimer: This is an unofficial, community-maintained package. It is not affiliated with, endorsed by, or sourced directly from the State Bank of India. Data is pulled from a third-party open-source archive (see below), which itself scrapes publicly published SBI rate sheets, it is not a live or guaranteed-accurate feed. Rates may be missing, delayed, or wrong due to upstream parsing errors or gaps. Use at your own risk. Always cross-check against an official SBI source before relying on this for tax filings, compliance, or any financial decision.
Data source: sahilgupta/sbi-fx-ratekeeper (not affiliated with SBI or the upstream repo author this package is a thin, cached wrapper around that repo's published CSVs).
Install
pip install sbi-tt-rates
Usage
from sbi_tt_rates import get_rate
result = get_rate("2021-02-20", currency="USD", rate_type="tt_buy")
print(result)
# RateResult(requested_date='2021-02-20', actual_date='2021-02-18',
# exact_match=False, rate=72.3, rate_type='tt_buy')
inr_value = 10_000 * result.rate
rate_type:"tt_buy"or"tt_sell"exact_matchtells you whether the requested date had a published rate, or whether it fell back to the nearest prior trading day — useful to log if you're using this for tax/compliance purposes.- Data is cached locally (
~/.cache/sbi_tt_rates/), so repeated lookups don't re-download the CSV each call.
Currencies
AED AUD BDT BHD CAD CHF CNY DKK EUR GBP HKD IDR JPY KES KRW KWD LKR MYR NOK NZD OMR PKR QAR RUB SAR SEK SGD THB TRY USD ZAR SBI_REFERENCE_RATES_ on https://github.com/sahilgupta/sbi-fx-ratekeeper
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sbi_tt_rates-0.1.0.tar.gz.
File metadata
- Download URL: sbi_tt_rates-0.1.0.tar.gz
- Upload date:
- Size: 7.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d847cd7439d2d7ebcd8d4aa6f7e9db3fadd6a82e276c461553783486918ab99f
|
|
| MD5 |
9d7e39a2d63704f5f9ea8e2079582b6f
|
|
| BLAKE2b-256 |
39f4a46a8bce0d63546e14bc8d7cd0f1deaff347b8229f64e18e87c1256259f6
|
File details
Details for the file sbi_tt_rates-0.1.0-py3-none-any.whl.
File metadata
- Download URL: sbi_tt_rates-0.1.0-py3-none-any.whl
- Upload date:
- Size: 6.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
258c306bcccb335f5379d955fd05a0b1039ce32642c385448938f4e2e69589be
|
|
| MD5 |
b59d22bace51ae936e1625bc75e8fbd8
|
|
| BLAKE2b-256 |
500c41263e8f1968122f7117fe6d01b570274c3dcbef53a61fbfbb05422ffa99
|