Skip to Content
Multi-Factor Authentication (MFA)

Create MFA Workflow

View Markdown (.md)
POST
/api/v1/public/mfa/workflows

Creates a new multi-factor authentication workflow policy configuring code length, expiration TTL, resend cooldown, channels, and optional signed webhooks.

Authorization

headerX-Api-Key<token>

SMS Pro API Key (sk_live_... or sk_test_...)

Request Body

application/json
  1. body
name*string
senderId?string
codeLength?integer
Range4 <= value <= 8
Default6
expiryMinutes?integer
Range1 <= value <= 60
Default5
maxAttempts?integer
Range1 <= value <= 10
Default3
resendCooldownSeconds?integer
Range10 <= value <= 300
Default30
channel?string
Default"AUTO_FAILOVER"
Value in"SMS""WHATSAPP""AUTO_FAILOVER"
messageTemplate?string
webhookUrl?string
Formaturi
webhookSecret?string
isDefault?boolean
Defaultfalse
isActive?boolean
Defaulttrue
defaultProofMode?string
Default"CHALLENGE_RESPONSE"
Value in"CHALLENGE_RESPONSE""PLAIN"

Response Body

MFA workflow successfully created

application/json
  1. response
status?string
message?string
data?
Example Request
curl -X POST 'https://api.smspro.com/api/v1/public/mfa/workflows' \  -H 'Content-Type: application/json' \  -d '{  "name": "string"}'
Example Response
{  "status": "string",  "message": "string",  "data": {    "id": "string",    "name": "string",    "senderId": "string",    "codeLength": 0,    "expiryMinutes": 0,    "maxAttempts": 0,    "resendCooldownSeconds": 0,    "channel": "string",    "isDefault": true,    "isActive": true,    "webhookUrl": "string",    "defaultProofMode": "CHALLENGE_RESPONSE"  }}