Create & Manage Wallets

Create and manage custodial wallets to custody stablecoin balances for your customers.

Manager wallets are custodial accounts that Inflow Connect creates and manages on behalf of your customers using Privy infrastructure. Each customer can have one Manager wallet that provides:

  • Custody and security - Inflow Connect holds the private keys
  • Simple payout source - Use Manager wallets as funding source for payouts
  • Regulatory compliance - KYC/AML oversight handled by Inflow Connect

Important: Each customer can only have one Manager wallet per account.

Core Operations

Manager Wallet Lifecycle

Create Manager Wallet

Create a new custodial wallet for a customer. Only one Manager wallet per customer is allowed.

Request

curl --location --request POST 'https://api.inflowconnect.com/accounts/{customerId}' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <API_KEY>' \
--data-raw '{
  "accountType": "MANAGED_WALLET_ACCOUNT",
  "name": "Customer Treasury Wallet",
  "referenceId": "cust_wallet_001"
}'

Response

{
  "id": "acc_a1b2c3d4e5f6g7h8",
  "customerId": "cus_x1y2z3a4b5c6d7e8",
  "accountType": "MANAGED_WALLET_ACCOUNT",
  "name": "Customer Treasury Wallet",
  "referenceId": "cust_wallet_001",
  "walletAddress": "0x742d35Cc6634C0532925a3b8D4C9db96C4b4d8b6",
  "walletChain": "polygon",
  "isWalletManaged": true,
  "status": "ACTIVE",
  "createdAt": "2024-01-15T10:30:00Z",
  "updatedAt": "2024-01-15T10:30:00Z"
}

Get Manager Wallet Details

Retrieve details for a specific Manager wallet.

Request

curl --location --request GET 'https://api.inflowconnect.com/accounts/{accountId}' \
--header 'Authorization: Bearer <API_KEY>'

Response

{
  "id": "acc_a1b2c3d4e5f6g7h8",
  "customerId": "cus_x1y2z3a4b5c6d7e8",
  "accountType": "MANAGED_WALLET_ACCOUNT",
  "name": "Customer Treasury Wallet",
  "walletAddress": "0x742d35Cc6634C0532925a3b8D4C9db96C4b4d8b6",
  "walletChain": "polygon",
  "isWalletManaged": true,
  "status": "ACTIVE",
  "createdAt": "2024-01-15T10:30:00Z",
  "updatedAt": "2024-01-15T10:30:00Z"
}

List Customer Accounts

Get all accounts for a specific customer (including Manager wallet if it exists).

Request

curl --location --request GET 'https://api.inflowconnect.com/accounts/customer/{customerId}' \
--header 'Authorization: Bearer <API_KEY>'

Response

{
  "accounts": [
    {
      "id": "acc_a1b2c3d4e5f6g7h8",
      "accountType": "MANAGED_WALLET_ACCOUNT",
      "name": "Customer Treasury Wallet",
      "walletAddress": "0x742d35Cc6634C0532925a3b8D4C9db96C4b4d8b6",
      "walletChain": "polygon",
      "isWalletManaged": true,
      "createdAt": "2024-01-15T10:30:00Z"
    },
    {
      "id": "acc_b2c3d4e5f6g7h8i9",
      "accountType": "EXTERNAL_BANK_ACCOUNT", 
      "name": "Main Bank Account",
      "bankName": "BNP Paribas",
      "createdAt": "2024-01-10T14:15:00Z"
    }
  ]
}

Transfer Operations

Send to External Bank Account

Transfer stablecoins from a Manager wallet to an external bank account (stablecoin-to-fiat).

Request

curl --location --request POST 'https://api.inflowconnect.com/payout/{customerId}' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <API_KEY>' \
--data-raw '{
  "source": {
    "fromManagedWalletDetails": {
      "accountId": "acc_a1b2c3d4e5f6g7h8"
    },
    "amountInCents": 5000
  },
  "destination": {
    "destinationAccountId": "acc_bank_xyz123"
  },
  "referenceId": "payout_ref_001"
}'

Response

{
  "id": "payout_x1y2z3a4b5c6d7e8",
  "customerId": "cus_a1b2c3d4e5f6g7h8",
  "status": "INITIATED",
  "source": {
    "accountId": "acc_a1b2c3d4e5f6g7h8",
    "amountInCents": 5000,
    "currency": "USDC",
    "currencyChain": "ethereum"
  },
  "destination": {
    "accountId": "acc_bank_xyz123",
    "currency": "USD"
  },
  "feeAmountInCents": 150,
  "createdAt": "2024-01-15T10:30:00Z",
  "updatedAt": "2024-01-15T10:30:00Z"
}

Send to External Wallet

Transfer stablecoins from a Manager wallet to an external crypto wallet.

Request

curl --location --request POST 'https://api.inflowconnect.com/payout/{customerId}' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <API_KEY>' \
--data-raw '{
  "source": {
    "fromManagedWalletDetails": {
      "accountId": "acc_a1b2c3d4e5f6g7h8"
    },
    "amountInCents": 10000
  },
  "destination": {
    "destinationAccountId": "acc_wallet_abc456"
  },
  "referenceId": "transfer_ref_002"
}'

Response

{
  "id": "payout_y2z3a4b5c6d7e8f9",
  "customerId": "cus_a1b2c3d4e5f6g7h8",
  "status": "INITIATED",
  "source": {
    "accountId": "acc_a1b2c3d4e5f6g7h8",
    "amountInCents": 10000,
    "currency": "USDC",
    "currencyChain": "ethereum"
  },
  "destination": {
    "accountId": "acc_wallet_abc456",
    "currency": "USDC",
    "currencyChain": "polygon"
  },
  "feeAmountInCents": 50,
  "createdAt": "2024-01-15T10:30:00Z",
  "updatedAt": "2024-01-15T10:30:00Z"
}

Funding Manager Wallets

Manager wallets can be funded through:

  1. Direct transfers - Customers send stablecoins directly to the Manager wallet address
  2. Hosted Checkout - Fiat-to-stablecoin deposits with Manager wallet as destination

Hosted Checkout to Manager Wallet

curl --location --request POST 'https://api.inflowconnect.com/onramp/{customerId}' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <API_KEY>' \
--data-raw '{
  "currency": "USD",
  "amountInCents": 25000,
  "destinationAccountId": "acc_a1b2c3d4e5f6g7h8",
  "successUrl": "https://yourapp.com/success",
  "cancelUrl": "https://yourapp.com/cancel"
}'

Error Handling

Common error scenarios and responses:

Duplicate Wallet Attempt

When trying to create a second Manager wallet for a customer:

{
  "error": "BAD_REQUEST",
  "message": "a managed wallet acc_existing123 already exists for customer 'cus_customer123'",
  "statusCode": 400
}

Invalid Account

{
  "error": "ACCOUNT_NOT_FOUND",
  "message": "Specified account ID does not exist or is not accessible",
  "details": {
    "accountId": "acc_invalid123"
  }
}

Wallet Creation Failed

{
  "error": "BAD_REQUEST",
  "message": "failed to create the managed wallet",
  "statusCode": 400
}