What goes in twoFA ? Theres no pin as such to login in First stock app

In access.json folder we have a list of credentials like vendor code , api key.

What goes in twoFA ? Theres no pin as such to login in First stock app it uses Face ID.

Hi PB2099,

In the access.json file, the twoFA parameter should store the TOTP (Time-based One-Time Password) value.

You can enable and use TOTP login as follows:

From Web App:

  1. Log in to Firstock - Smart trading and investment platform
  2. Go to Profile → Settings → Password → Enable TOTP
  3. Enter the OTP received on your email
  4. After verification, you’ll get a secret key
  5. Use this secret key to generate TOTP in your code

From Mobile App:

  1. Log in with your credentials
  2. Click on Profile → Profile Details
  3. Scroll down and click on Reset Password
  4. Click on Enable TOTP
  5. Enter the OTP received on your email, after that you’ll get a secret key

Example in Python:

import pyotp

# Replace with your secret key from Firstock app
secret_key = "YOUR_SECRET_KEY"

# Initialize TOTP generator
totp = pyotp.TOTP(secret_key)

# Generate the current OTP
current_otp = totp.now()

print("Your TOTP is:", current_otp)

The value generated here should be used in the twoFA field of access.json.