Skip to main content
The SMS OTP API is available for accounts where the OTP product is enabled. For new integrations, use Unified OTP: it generates codes inside KarFlows and can route them through SMS or WhatsApp.
SMS OTP and Unified OTP use different tokens and pinId formats. Keep each send/verify pair on the same API.

Send OTP

Send response

Store pinId on your server. Ask the customer for the code, then call verify.

Verify OTP

Aliases accepted for the code: pin, otp, or code.

Logs

Billing

  • Sending an OTP consumes one SMS segment after the KarFlows delivery route accepts the request.
  • Verification does not consume SMS balance.
  • A synchronous send failure is refunded.
  • Incorrect, expired, and blocked verification attempts are logged.

Best practices

  • Store pinId server-side.
  • Do not trust OTP verification done in browser-only code.
  • Rate limit signup/login forms before calling the OTP API.
  • Do not expose the OTP token in mobile apps.