Home API Reference Wallet & balance

Wallet & balance

Last updated on Jun 07, 2026

Return your dealer profile, including your wallet balance(s). Use it to confirm your key works and to check funds before placing orders.

Request

curl -H "x-api-key: sk_prod_your_key_here" \
  "https://api.palcards.ps/user/profile"

GET /user/profile

Response

{
  "id": 42,
  "name": "My Store",
  "username": "mystore",
  "email": "store@example.com",
  "role": "dealer",
  "status": "active",
  "wallets": [
    {
      "balance": { "currency": "USD", "value": 250.75 },
      "default": true,
      "active": true,
      "updatedAt": "2026-06-01T10:00:00.000Z"
    }
  ],
  "outstandingBalance": { "currency": "USD", "value": 0 },
  "defaultDiscountPercent": 5
}

Fields

  • wallets[] — one entry per currency; wallets[].balance is your available balance in that currency.
  • wallets[].default — your default wallet; an order with no orderCurrency uses this wallet's currency.
  • outstandingBalance — amount you owe (credit used), if any.
  • defaultDiscountPercent — your default discount.

How wallets & currency work for orders

  • An order is charged from the wallet whose currency matches the order's orderCurrency.
  • Omitting orderCurrency uses your default wallet's currency.
  • Ordering in a currency you have no wallet for returns 400"Required wallet for currency 'X' is missing."
  • If the matching wallet's balance is below the price, POST /order returns 400 "Insufficient balance" and no order is created (you are not charged).

Amounts are objects: { "currency": "USD", "value": 250.75 }.