This guide walks you through the entire process, from sign-up to production deployment. No PhD in computer vision required.
What You'll Need
π Prerequisites
1. An App Bouncer account (free to create)
2. Your app's codebase with API integration capability
3. About 30 minutes of your time
Step 1: Get Your API Credentials (5 minutes)
First, sign up for a free App Bouncer account:
- Visit appbouncer.com and click "Get Started Free"
- Complete the registration form
- Verify your email address
- Navigate to your dashboard and find your API key
π Security First
Your API key is like a passwordβkeep it secret! Always store it in environment variables and never commit it to version control or share it publicly.
Step 2: Install the SDK (2 minutes)
We provide SDKs for major platforms. Choose yours:
JavaScript/TypeScript
npm install @appbouncer/sdk Python
pip install appbouncer Ruby
gem install appbouncer Or use our REST API directly if you prefer another language.
Step 3: Initialize the Client (3 minutes)
Import the SDK and initialize it with your API key:
import { AppBouncer } from '@appbouncer/sdk'
const bouncer = new AppBouncer({
apiKey: process.env.APP_BOUNCER_API_KEY
}) Step 4: Trigger Verification (10 minutes)
When a user attempts to access age-restricted content, trigger the verification:
async function verifyUserAge(userId) {
try {
const result = await bouncer.verifyAge({
userId: userId,
redirectUrl: 'https://yourapp.com/verification-complete'
})
// Send user to verification flow
window.location.href = result.verificationUrl
} catch (error) {
console.error('Verification failed:', error)
// Handle error appropriately
}
} The user will be redirected to a secure verification page where they'll use their camera for age verification. The entire process takes about 10 seconds for the user.
Step 5: Handle the Response (5 minutes)
After verification, the user returns to your redirect URL. You'll receive a verification token:
async function handleVerificationComplete(token) {
try {
const result = await bouncer.getVerificationResult(token)
if (result.isVerified && result.ageEstimate >= 18) {
// Grant access
grantAccess(result.userId)
} else {
// Deny access
showAgeRestrictedMessage()
}
} catch (error) {
console.error('Failed to get verification result:', error)
}
} Step 6: Store the Result (5 minutes)
Store the verification status in your database so users don't need to verify every time:
await database.users.update({
userId: result.userId,
ageVerified: true,
verifiedAt: new Date(),
verificationId: result.verificationId
}) Best Practices
π‘ Implementation Tips
1. Handle Errors Gracefully: Network issues happen. Always provide fallback messaging and retry options.
2. Don't Store Biometric Data: App Bouncer doesn't send you biometric data, and you shouldn't store any either. Just store the verification result.
3. Test in Sandbox Mode: Use sandbox mode during development. It returns mock results without requiring actual face verification.
4. Provide Clear User Communication: Explain why age verification is necessary and how the process works. Transparency builds trust.
Common Issues and Solutions
π§ Troubleshooting Guide
Issue: Users complain about camera access
Solution: Clearly explain that the verification happens on App Bouncer's
secure servers, not your app, and no images are stored.
Issue: Verification fails in poor lighting
Solution: Provide guidance before verification starts about optimal
lighting conditions.
Issue: Token expires before user returns
Solution: Tokens are valid for 1 hour. If expired, simply trigger
a new verification.
Next Steps
Congratulations! You've implemented biometric age verification. Here's what to do next:
- Test thoroughly in sandbox mode
- Review our compliance documentation
- Deploy to production
- Monitor your verification rates in the dashboard
Questions? Our support team is available 24/7 through the dashboard chat.