Overview
AwalletId is a string you provide to Bluvo to identify a specific user-exchange connection. You control the format, it just needs to be unique per user per exchange pair. Every API call that touches a wallet (balances, quotes, withdrawals) is scoped to this identifier.
The Common Mistake
| Approach | User | Exchange | walletId | Result |
|---|---|---|---|---|
| Wrong | user-123 | Binance | user-123 | Coinbase connection overwrites Binance |
| Wrong | user-123 | Coinbase | user-123 | |
| Correct | user-123 | Binance | user-123-binance | Both connections work independently |
| Correct | user-123 | Coinbase | user-123-coinbase |
The Simple Pattern
The easiest approach is a deterministic format that combines your user ID with the exchange name:Alternative: Random UUID
If you prefer not to encode user IDs into the walletId, generate acrypto.randomUUID() per connection and store the mapping in your database:
Trade-offs
Deterministic (userId-exchange) | Random UUID | |
|---|---|---|
| DB lookup needed | No | Yes |
| Reconstructable | Yes, rebuild from userId + exchange | No, must persist |
| Exposes user ID | In the walletId string | No |
| Setup complexity | None | Requires a mapping table |
Code Examples
Next Steps
OAuth2 Integration
Implement the full OAuth2 popup flow with React hooks
Encryption & Security
How Bluvo encrypts and isolates exchange credentials