okta_login
Authenticate to a website via Okta SSO, including TOTP MFA, and save the browser session for reuse.
Instructions
Authenticate to a website via Okta SSO and persist the session.
Launches a headless browser, navigates to the target URL, performs Okta login (including TOTP MFA if configured), and saves the browser session for later use. Sessions are stored per-domain in ~/.okta-auth/sessions/.
Credentials are resolved in order: explicit parameter → environment variable
→ OS keyring when the local provider is set to keyring. When the provider
is set to op, launch the server through op run so the environment is
populated at process start.
Args: url: Target URL to authenticate against (e.g., 'https://portal.company.com'). username: Okta username or email. Falls back to OKTA_USERNAME or stored keyring data. password: Okta password. Falls back to OKTA_PASSWORD or stored keyring data. totp_secret: Base32 TOTP secret for automated MFA. Falls back to OKTA_TOTP_SECRET or stored keyring data. headed: Show the browser window during login. Set to true for debugging. timeout_ms: Maximum time in ms to wait for page loads (5000-300000, default 60000).
Returns: JSON: {"success": bool, "domain_key": str|null, "message": str, "url": str}
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | ||
| headed | No | ||
| password | No | ||
| username | No | ||
| timeout_ms | No | ||
| totp_secret | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |