This family groups a set of actions related to one-time passwords (OTP) and temporary codes.
Generate one-time password
Generates a numeric code with a validity of 10 minutes, that can be sent via email, SMS or any messaging apps.
Input settings
Parameter |
Description |
ID (required) |
Action ID. It is used to reference the output values of the action. |
Alias |
Short description to be displayed in the action. |
Reference value (required) |
You can bind your generated code to a phone number, email address or any value.
|
Code length (required) |
The number of digits that the generated code will have. |
Output object
Property |
Type |
Description |
code |
String |
The generated code. |
validUntil |
String |
Expiration date and time (ISO 8601 UTC format) until the generated code is valid. |
Output object example
{
"code": "5377",
"validUntil": "2020-12-09T19:34:35.654Z"
}
Verify one-time password
Verifies if the provided code is valid or not.
Input settings
Parameter |
Description |
ID (required) |
Action ID. It is used to reference the output values of the action. |
Alias |
Short description to be displayed in the action. |
Reference value (required) |
You need to use the same reference you used to generate the code.
|
Code value (required) |
The number of digits that the generated code will have. |
Output object
Property |
Type |
Description |
valid |
Boolean |
Indicates if the provided code is valid or not returning a true or false value. |
result |
String |
Indicates different result codes based on the provided code:
MISSING : If the provided code doesn't exist with that reference value.
EXPIRED : If the provided code has expired.
VALID : If the provided code is valid.
UNEQUAL : If you provided code is not valid.
|
Output object examples
{
"valid": false,
"result": "UNEQUAL"
}