Overview
BOOP Network uses WebSocket connections for real-time, bidirectional communication between your vendor system and our authentication service. This enables instant palm vein authentication without polling.Connection Setup
Development Environment
Connect to the BOOP test network WebSocket endpoint:Authentication
After connecting, authenticate with your vendor credentials:Complete Integration Example
Message Types
Vendor → BOOP
| Message Type | Description | Required Fields |
|---|---|---|
vendor_hello | Initial authentication | api_key, vendor_id |
create_context | Create authentication context | context_id, context_type, attributes |
cancel_context | Cancel active context | context_id |
ping | Keep connection alive | - |
BOOP → Vendor
| Message Type | Description | Fields |
|---|---|---|
vendor_hello_response | Authentication result | success, error |
context_created | Context creation confirmed | context_id, qr_code |
authentication_success | User authenticated | context_id, user_id, attributes |
authentication_failed | Authentication failed | context_id, reason |
context_expired | Context timed out | context_id |
pong | Keep-alive response | - |
Context Types
Payment Context
For processing payments:Access Context
For physical or digital access control:Age Verification Context
For age-restricted purchases:Error Handling
Connection Errors
Implement automatic reconnection with exponential backoff:Message Validation
Always validate incoming messages:Best Practices
🔒 Security
🔒 Security
- Never expose your API key in client-side code
- Use environment variables for credentials
- Implement request signing for additional security
- Validate all incoming messages
- Use TLS/SSL for all connections
⚡ Performance
⚡ Performance
- Implement connection pooling for high-volume scenarios
- Use message queuing for reliability
- Batch context creation when possible
- Monitor WebSocket health with regular pings
- Implement circuit breakers for failing connections
🔄 Reliability
🔄 Reliability
- Always implement reconnection logic
- Store context state locally for recovery
- Use unique, idempotent context IDs
- Implement timeout handling for contexts
- Log all messages for debugging
🧪 Testing
🧪 Testing
- Use the dev environment for all testing
- Test edge cases like network disconnections
- Verify attribute handling
- Test with various context types
- Monitor message latency
Testing Your Integration
1. Basic Connection Test
2. Context Creation Test
3. End-to-End Test
Use our mock PVS interface to simulate complete authentication flows:- Create a context via WebSocket
- Display the QR code or context ID
- Use the mock PVS at
https://mock-pvs.dev.event-vendor.boop.itto simulate a scan - Receive authentication result via WebSocket
Migration to Production
When ready to go live:-
Change WebSocket URL:
- Update API credentials to production keys
- Remove test flags from metadata
- Implement production monitoring and alerting