Verify a Generic OTP
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/verify_otp \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"timestampMs": "<string> (e.g. 1746736509954)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g. 1746736509954)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"verifyOtpIntent": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
},
"result": {
"verifyOtpResult": {
"verificationToken": "<string>"
}
}
}
}
}
}
Enum options: ACTIVITY_TYPE_VERIFY_OTP
Timestamp (in milliseconds) of the request, used to verify liveness of user requests.
Unique identifier for a given Organization.
parameters field
Show details
A successful response returns the following fields:
The activity object containing type, intent, and result
Show activity details
The intent of the activity
Show intent details
The verifyOtpIntent object
Show verifyOtpIntent details
ID representing the result of an init OTP activity.
OTP sent out to a user’s contact (email or SMS)
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/verify_otp \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"timestampMs": "<string> (e.g. 1746736509954)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g. 1746736509954)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"verifyOtpIntent": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
},
"result": {
"verifyOtpResult": {
"verificationToken": "<string>"
}
}
}
}
}
}
Was this page helpful?
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/verify_otp \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"timestampMs": "<string> (e.g. 1746736509954)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g. 1746736509954)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"verifyOtpIntent": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
},
"result": {
"verifyOtpResult": {
"verificationToken": "<string>"
}
}
}
}
}
}
Verify a Generic OTP
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/verify_otp \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"timestampMs": "<string> (e.g. 1746736509954)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g. 1746736509954)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"verifyOtpIntent": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
},
"result": {
"verifyOtpResult": {
"verificationToken": "<string>"
}
}
}
}
}
}
Enum options: ACTIVITY_TYPE_VERIFY_OTP
Timestamp (in milliseconds) of the request, used to verify liveness of user requests.
Unique identifier for a given Organization.
parameters field
Show details
A successful response returns the following fields:
The activity object containing type, intent, and result
Show activity details
The intent of the activity
Show intent details
The verifyOtpIntent object
Show verifyOtpIntent details
ID representing the result of an init OTP activity.
OTP sent out to a user’s contact (email or SMS)
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/verify_otp \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"timestampMs": "<string> (e.g. 1746736509954)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g. 1746736509954)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"verifyOtpIntent": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
},
"result": {
"verifyOtpResult": {
"verificationToken": "<string>"
}
}
}
}
}
}
Was this page helpful?
curl --request POST \
--url https://api.turnkey.com/public/v1/submit/verify_otp \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--header "X-Stamp: <YOUR_API_KEY.YOUR_API_SECRET>" \
--data '{
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"timestampMs": "<string> (e.g. 1746736509954)",
"organizationId": "<string> (Your Organization ID)",
"parameters": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
}'
{
"activity": {
"id": "<activity-id>",
"status": "ACTIVITY_STATUS_COMPLETED",
"type": "ACTIVITY_TYPE_VERIFY_OTP",
"organizationId": "<organization-id>",
"timestampMs": "<timestamp> (e.g. 1746736509954)",
"result": {
"activity": {
"type": "<string>",
"intent": {
"verifyOtpIntent": {
"otpId": "<string>",
"otpCode": "<string>",
"expirationSeconds": "<string>"
}
},
"result": {
"verifyOtpResult": {
"verificationToken": "<string>"
}
}
}
}
}
}