rom thefirstock import thefirstock
from dotenv import load_dotenv
import os
import pyotp
dotenv_filepath = os.path.join(os.path.dirname(__file__), ".env")
load_dotenv(dotenv_filepath)
totp = pyotp.TOTP(os.environ.get('FIRSTOCK_TOTP_KEY'))
def init_firstock_sdk():
login = thefirstock.firstock_login(
userId=os.environ.get('FIRSTOCK_USERID'),
password=os.environ.get('FIRSTOCK_PASSWORD'),
TOTP=totp.now(),
vendorCode='TJ2901_API',
apiKey=os.environ.get('FIRSTOCK_API_KEY'),
)
print(thefirstock.firstock_userDetails())
print('login: ',login)
>>> import firstock_util
>>> firstock_util.init_firstock_sdk()
[Errno 2] No such file or directory: 'config.json'
None
login: None
>>>
Hello @tejas_ttid ,
Currently you can’t use multiple users in a single folder, But for using multiple user you need to access in different folders i.e. call the different user login on different folder.