Getting your API keys
You need two keys before you start: a Partner API key from Cr3dentials and a Google API key for the Gemini AI features.1
Get your Partner API key
- Sign up or log in to Cr3dentials at app.cr3dentials.xyz.
- Go to the Partner API section of the dashboard.
- Click “Generate New API Key” or copy your existing key.
- Store the key in your
.envfile.
2
Get your Google API key
- Visit aistudio.google.com/app/apikey.
- Click “Create API Key”.
- Copy the key and add it to your
.envfile.
3
Set up your environment
.env
Quick start
Install the SDK:Platform identifiers
Each platform you integrate needs a unique identifier, such as"providus_bank", "your_bank", or "your_platform".
Available platform strategies:
providus_bank: Providus Bank (Nigeria) with transaction capture
- Choosing a unique platform identifier.
- Using that identifier in
universalLogin(). - The SDK discovers and caches the login flow automatically.
Login and capture data
The SDK logs into a platform and captures relevant data during the login flow.Providus Bank (transaction data)
Providus Bank captures transaction data automatically during login:Transaction data structure
Using with other platforms
The same pattern works for any platform:Verify specific transactions (Providus Bank)
Transaction verification via
platformConfig is a Providus Bank-specific feature. Other platforms may have different platformConfig options based on their capabilities.Verification options
All criteria use AND logic, so every field you provide must match.
Manual verification (ZK proof model)
If you do not want the SDK to log in on behalf of users, use the manual verification workflow (similar to zkp2p). In this model:- Users log into their bank or platform themselves.
- The SDK provides a verification session and monitors for proof.
- No credentials are shared with your application.
- Users keep full control and privacy.
- Privacy-focused applications
- Compliance requirements where credential sharing is restricted
- User-controlled verification flows
- Zero-knowledge proof architectures
Using the API-only client
For manual verification workflows, useCr3dentialsApiClient instead of the full SDK:
The API-only client is lightweight and does not require browser automation dependencies.
1
Get available verification types
Discover what types of verification are available:
2
Get sources for a verification type
Get the available platforms or sources for a specific verification type:
3
Create a verification session
Create a session where the user will manually verify:
4
Direct the user to the verification URL
Present the verification URL to your user:
5
Poll for verification status
Monitor the verification session for completion:
6
Handle verification results
Once the verification is complete, process the results:
Complete manual verification example
Using webhooks (recommended for production)
Instead of polling, configure webhooks to receive real-time updates:Session status reference
Extract custom data
After login, you can perform additional actions and extract custom data from any platform using natural language.Providus Bank
Using with any platform
The same approach works for any platform. Change the platform identifier and the extraction logic:Configuration
SDK configuration
Your Partner API key from the Cr3dentials dashboard.
Your Google API key. Required for the AI features.
Hide the browser UI.
Enable detailed logging.
Platform identifier used for flow caching. Match it to the identifier you pass to
universalLogin() to enable faster subsequent logins.API timeout in milliseconds.
Number of retry attempts.
Delay between retries in milliseconds.
Environment variables
.env
Error handling
AuthenticationError
AuthenticationError
The provided credentials were rejected by the platform. Check the username and password, and confirm the account is not locked or requiring additional verification.
AutomationError
AutomationError
The browser automation could not complete the login or extraction flow. This can happen when the platform UI changed or a step timed out.
ApiError
ApiError
The Cr3dentials API returned an error. Read
error.statusCode and error.message for details.Best practices
Always use try/finally
Use environment variables
Development vs production
Monitor live sessions
Reuse the SDK instance
Complete examples
All examples below use Providus Bank as the platform. To use another platform, change theplatform identifier and adjust the data extraction logic for that platform’s data structure.
