Integrations Overview
TrustGate provides multiple integration options to fit your technical requirements, from no-code solutions to fully customized API integrations.
Integration Options
1. Hosted Flow (Quickest)
Redirect users to TrustGate-hosted verification:
┌─────────────────────────────────────────────────────────┐
│ YOUR APPLICATION │
│ │
│ User clicks "Verify Identity" │
└─────────────────────────┬───────────────────────────────┘
│
│ Redirect to TrustGate
v
┌─────────────────────────────────────────────────────────┐
│ TRUSTGATE │
│ │
│ Document upload → Biometric → Screening │
└─────────────────────────┬───────────────────────────────┘
│
│ Redirect back with result
v
┌─────────────────────────────────────────────────────────┐
│ YOUR APPLICATION │
│ │
│ User is verified, continue onboarding │
└─────────────────────────────────────────────────────────┘
Best for:
- Quick implementation
- Mobile and web
- No frontend development needed
2. Embedded SDK
Embed verification UI directly in your app using the React SDK or the Hosted SDK in an iframe:
For detailed integration instructions, see the SDK Integration guide. A React SDK is available at
@trustgate/react-sdk.
Best for:
- Seamless user experience
- Brand consistency
- More control over flow
3. API Integration
Full control with direct API calls:
# 1. Create applicant
curl -X POST https://api.bytrustgate.com/api/v1/applicants \
-H "Authorization: Bearer sk_live_xxx" \
-d '{"first_name": "John", "last_name": "Doe"}'
# 2. Upload document
curl -X POST https://api.bytrustgate.com/api/v1/documents \
-H "Authorization: Bearer sk_live_xxx" \
-F "applicant_id=app_123" \
-F "type=passport" \
-F "file=@passport.jpg"
# 3. Run verification
curl -X POST https://api.bytrustgate.com/api/v1/verifications \
-H "Authorization: Bearer sk_live_xxx" \
-d '{"applicant_id": "app_123", "checks": ["document", "biometric"]}'
Best for:
- Custom workflows
- Backend-to-backend
- Maximum flexibility
Quick Start
Step 1: Get API Keys
- Log in to the TrustGate Dashboard
- Navigate to Integrations → API Keys (or Dev Workbench → API Keys)
- Create keys for sandbox (testing) and production
Step 2: Choose Integration Method
| Method | Effort | Control | Best For |
|---|---|---|---|
| Hosted Flow | Low | Low | MVP, quick launch |
| Embedded SDK | Medium | Medium | Branded experience |
| API | High | High | Custom workflows |
Step 3: Implement
Hosted Flow
// Generate verification session with shareable link
const response = await fetch('https://api.bytrustgate.com/api/v1/sdk/access-token', {
method: 'POST',
headers: {
'X-API-Key': 'sk_live_xxx',
'Content-Type': 'application/json'
},
body: JSON.stringify({
external_user_id: 'user_12345',
email: 'user@example.com',
flow_name: 'default',
redirect_url: 'https://your-app.com/verification-complete',
expires_in: 3600 // seconds
})
});
const { sdk_url } = await response.json();
// Redirect user to hosted verification
window.location.href = sdk_url;
Embedded SDK
Use the Hosted SDK in an iframe or integrate the React SDK directly:
// Generate a hosted SDK session, then embed via iframe or redirect
const response = await fetch('https://api.bytrustgate.com/api/v1/sdk/access-token', {
method: 'POST',
headers: {
'X-API-Key': 'sk_live_xxx',
'Content-Type': 'application/json'
},
body: JSON.stringify({
external_user_id: 'user_12345',
flow_name: 'default'
})
});
const { sdk_url } = await response.json();
// Embed sdk_url in an iframe or redirect the user
For React applications, see the @trustgate/react-sdk package.
API Integration
See API Reference for complete documentation.
Environments
Sandbox
- Base URL:
https://api.sandbox.bytrustgate.com - API Keys: Start with
sk_test_/pk_test_ - No real verifications performed
- Test data and scenarios available
Production
- Base URL:
https://api.bytrustgate.com - API Keys: Start with
sk_live_/pk_live_ - Real verifications
- Billing active
Integration Methods
REST API (Recommended)
The TrustGate REST API is the primary way to integrate. No SDK installation required — use any HTTP client (curl, fetch, requests, axios, etc.):
Quick Start:
- Sign up at app.bytrustgate.com
- Go to Dev Workbench → API Keys and create a key
- Make API calls directly with your key
All features are available via REST API:
# Example: Run a screening check
curl -X POST https://api.bytrustgate.com/api/v1/screen \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"name": "John Doe", "date_of_birth": "1990-01-15"}'
Official SDKs (Optional)
SDKs provide convenience wrappers around the REST API. They are not required — all functionality is available via direct HTTP calls.
| Platform | Package | Status |
|---|---|---|
| JavaScript/Node.js | @trustgate/sdk | Coming soon |
| Python | trustgate | Coming soon |
| React Native | @trustgate/react-native | Coming soon |
| iOS | TrustGateSDK | Coming soon |
| Android | com.trustgate:sdk | Coming soon |
Webhook Integration
Receive real-time updates about verification status:
curl -X POST https://api.bytrustgate.com/api/v1/integrations/webhooks \
-H "X-API-Key: sk_live_xxx" \
-H "Content-Type: application/json" \
-d '{
"url": "https://your-app.com/webhooks/trustgate",
"events": [
"applicant.verified",
"applicant.rejected",
"screening.hit"
]
}'
Security Best Practices
- Never expose secret keys in frontend code
- Use public keys for client-side SDK
- Verify webhook signatures to authenticate requests
- Use HTTPS for all API communication
- Rotate keys periodically
Next Steps
- API Keys - Key management
- Webhooks - Real-time notifications
- SDK Integration - Detailed SDK guide
- Webhook Events - Event reference