Retrieve an Email Validation
GET
https://api.verifik.co/v2/email-validations/{id}
This service retrieves a specific email validation record using its unique identifier. The response includes all the details about the email validation process, including status, OTP information, and associated project data.
Headers
Content-Type
application/json
Authorization
Bearer {YOUR_ACCESS_TOKEN}
Path Parameters
id
string
The unique identifier of the email validation record you want to retrieve.
Query Parameters
populates[]
string
Optional array of related data to include. Available options: client
, project
, projectFlow
.
Request
const axios = require("axios");
const config = {
method: "get",
url: "https://api.verifik.co/v2/email-validations/{id}",
headers: {
Authorization: "Bearer YOUR_ACCESS_TOKEN"
}
};
axios.request(config)
.then(response => console.log(response.data))
.catch(error => console.error(error));
Response
{
"data": {
"_id": "63505a2cf61d5a8d0f812317d",
"client": "623b6317fe5fd118be9f566",
"project": "635047538c4cca6fdbd09237",
"projectFlow": "635059838c4cca6fdbd01828",
"status": "validated",
"validationMethod": "verificationCode",
"email": "[email protected]",
"type": "onboarding",
"otp": "$2a$45$zSS9ubgb2jGtHlPPjrkareD8k2clcplqB7a4T3.98D4idumUOiJ4.",
"expiresAt": "2024-12-19T20:27:28.000Z",
"redirectUrl": "https://example.com/success",
"webhookUrl": "https://api.client.com/webhooks/verifik",
"requires2FA": false,
"ipAddress": "192.168.1.1",
"extraParams": [],
"emailData": {
"projectName": "Example Project",
"contactEmail": "[email protected]",
"template": "onboarding",
"firstName": "John",
"logo": "https://cdn.verifik.co/access/projectlogo.png",
"authLink": "https://access.verifik.co/sign-up/635047538c4cca6fdbd09237?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...&otp="
},
"deleted": false,
"createdAt": "2024-12-19T20:12:28.613Z",
"updatedAt": "2024-12-19T20:13:14.199Z",
"__v": 0
}
}
Response Body
_id
String
Unique identifier of the email validation record
client
Object
Client information (populated if requested)
project
Object
Project information (populated if requested)
projectFlow
String
Unique identifier of the project flow
status
String
Current status: new
, sent
, validated
, or failed
validationMethod
String
Method used: verificationCode
or manual
email
String
Email address being validated
type
String
Type of validation: validation
, login
, onboarding
, or oneTimeLink
otp
String
Hashed one-time password (for security)
expiresAt
String
Timestamp when the OTP expires
redirectUrl
String
URL for redirect after validation
webhookUrl
String
Webhook URL for notifications
requires2FA
Boolean
Whether two-factor authentication is required
ipAddress
String
IP address of the validation request
extraParams
Array
Additional parameters passed during creation
emailData
Object
Email template and project-specific data
deleted
Boolean
Whether the record has been deleted
createdAt
String
Timestamp when the record was created
updatedAt
String
Timestamp when the record was last updated
Important Notes
Authentication Required: You must provide a valid Bearer token to access this endpoint
Client Isolation: The system automatically filters results based on your client ID for security
Data Population: Use query parameters to include related client and project information
Security: OTP values are returned as hashed strings for security purposes
Status Tracking: The status field provides real-time information about the validation process
Expiration: Check the
expiresAt
field to determine if the OTP is still valid
Error Responses
404
Email validation record not found
403
Access forbidden (insufficient permissions)
500
Internal server error
This endpoint is useful for checking the current status of email validations, retrieving OTP expiration times, and monitoring the progress of user verification processes.
Last updated
Was this helpful?