Skip to main content
Create and manage custodial cryptocurrency wallets for your users with blockchain integration.

Create Wallet

POST /v1/wallet Create a new custodial cryptocurrency wallet for a user.
curl -X POST "https://api.useonion.xyz/v1/wallet" \
  -H "Content-Type: application/json" \
  -H "x-api-key: sk_live_…" \
  -d '{
    "userId": "user_abc123"
  }'
  • x-api-key (header): Active API key for authentication

Body Parameters

fieldtyperequireddescription
userIdstringyesUser identifier

Response: 200 OK

{
  "id": "wallet_def456",
  "userId": "user_abc123",
  "clientId": "client_789",
  "walletId": "br_wallet_123",
  "addressId": "br_addr_456",
  "address": "0x1234567890abcdef1234567890abcdef12345678",
  "blockchain": "ethereum",
  "createdAt": "2025-07-20T14:10:00Z",
  "updatedAt": "2025-07-20T14:10:00Z"
}

Response: 400 Bad Request

{
  "error": "Invalid user ID format"
}

Response: 500 Internal Server Error

{
  "error": "Failed to create wallet"
}

Get User Wallet

GET /v1/wallet/:userId Retrieve the custodial wallet for a specific user.
curl -X GET "https://api.useonion.xyz/v1/wallet/user_abc123" \
  -H "x-api-key: sk_live_…"
  • x-api-key (header): Active API key for authentication

Path Parameters

  • userId (path): User identifier

Response: 200 OK

{
  "id": "wallet_def456",
  "userId": "user_abc123",
  "clientId": "client_789",
  "walletId": "br_wallet_123",
  "addressId": "br_addr_456", 
  "address": "0x1234567890abcdef1234567890abcdef12345678",
  "blockchain": "ethereum",
  "createdAt": "2025-07-20T14:10:00Z",
  "updatedAt": "2025-07-20T14:10:00Z"
}

Response: 404 Not Found

{
  "error": "User not found"
}

Wallet Features

Custodial Management

Secure custodial wallet creation and management through BlockRadar integration

Multi-Blockchain Support

Support for Ethereum and other EVM-compatible blockchains

Automatic Creation

Wallets are created automatically when users need cryptocurrency functionality

Address Management

Each wallet comes with a unique blockchain address for receiving transactions
Wallets are automatically created and managed through our secure infrastructure. Users don’t need to handle private keys or seed phrases.