Age Verification
Age Verification Status
The verifyAgeVerification function is an asynchronous method that checks the status of an age verification request by using the unique audit ID generated during the verification process. It communicates with RocketFuel’s backend to determine whether the user has successfully completed age verification.
Use this function to confirm whether a user has passed or failed age verification. This is essential when handling age-restricted products or services, ensuring compliance with legal and regulatory requirements.
Input Parameters
auditId:
stringThe unique identifier of the audit log that was created when the age verification attempt was initiated.
Usage Example
Assuming you have an instance of your SDK client (e.g., named client) that includes the verifyAgeVerification method:
async function checkAgeVerification(auditId: string) {
try {
const result = await client.verifyAgeVerification(auditId);
console.log("✅ User age verified successfully:", result);
} catch (error) {
console.error("Error verifying age:", error);
}
}
Response
{
"id": "d27d3b78-cd99-42f9-87f6-2a17b01f7820",
"status": "status_verified",
"verifiedOn": "2025-09-10T17:59:37.002Z",
"createdAt": "2025-09-10T17:59:21.122Z",
"timezone": "UTC"
}id
string
Unique identifier of the verification record (audit ID).
status
string
Current verification status (see Status Values below).
verifiedOn
string (ISO datetime)
Timestamp when the user was successfully verified (only available if verified).
createdAt
string (ISO datetime)
Timestamp when the verification request was created.
timezone
string
Timezone used in the verification process.
expired
The verification session expired before completion.
status_initiated
Age verification process has started but not yet completed.
status_verified
User successfully completed age verification.
status_failed
Age verification attempt failed.
widget_started
The verification widget was launched, but final status not yet determined.
📌 Notes
This function returns
trueif the signature is valid, otherwisefalse.Your webhook endpoint must always return a successful response (e.g., HTTP 200), as Rocketfuel verifies the endpoint only once during registration through the merchant dashboard.
Last updated
Was this helpful?