B2B Saas Authentication

/

Frontend SDKs

/

Headless

/

Email One-time Passcodes (OTPs)

/

Send Discovery Email OTP

Send discovery email


Method parameters


email_address*string

login_template_idstring

localestring
import { useStytchB2BClient } from '@stytch/react/b2b';

export const Login = () => {
  const stytch = useStytchB2BClient();

  const sendDiscoveryEmail = () => {
    stytch.otps.email.discovery.send({
      email_address: 'sandbox@stytch.com',
    });
  };

  return <button onClick={sendDiscoveryEmail}>Send email</button>;
};

RESPONSE

200
{
    "status_code": 200,
    "request_id": "request-id-test-b05c992f-ebdc-489d-a754-c7e70ba13141"
  }