## Get Code `v2.totp.get_code(strsecret_id) -> TotpGetCodeResponse` **get** `/api/v2/totp/code/{secret_id}` Generate the current 6- or 8-digit TOTP code for a stored secret, along with how many seconds remain until it rotates. ### Parameters - `secret_id: str` ### Returns - `class TotpGetCodeResponse: …` - `code: Optional[str]` The current TOTP code - `expires_in: Optional[int]` Seconds until this code rotates - `status: Optional[str]` ### Example ```python import os from sendblue_api import SendblueAPI client = SendblueAPI( api_key=os.environ.get("SENDBLUE_API_API_KEY"), # This is the default and can be omitted api_secret=os.environ.get("SENDBLUE_API_API_SECRET"), # This is the default and can be omitted ) response = client.v2.totp.get_code( "550e8400-e29b-41d4-a716-446655440000", ) print(response.code) ```