> For the complete documentation index, see [llms.txt](https://docs.xyb.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.xyb.co/accounts/account-management/account-wallet-management-overview.md).

# Account Wallet Management Overview

An **account** **wallet** represents a currency-specific balance container under an account. Wallets hold funds, track balances in real time, and support transactions in specific currencies.

Every account must have at least one wallet (usually created automatically), and can support multiple additional wallets as needed (e.g., for multi-currency).

***

Wallet creation in XYB is fully automated and tied to your **Product Configuration**. Once you define the wallet strategy for your account product including default currency, additional currencies, and wallet codes XYB will auto-provision these wallets during account creation. This means no separate API call is required to create wallets. When you create an account using the standard API, the system references your product setup, creates the associated wallets, and links them to the correct ledger.

[Learn how to configure wallets in Product Configuration](/accounts/configure-accounts/setting-up-product-configuration-for-accounts.md)\
[Read more on creating accounts](/accounts/configure-accounts/create-new-accounts.md)

***

#### View Wallet Balances

You can view all wallet balances using the following endpoints:

* **Get all balances:**\
  `GET /api/v2.0/account/{idRef}/wallets`
* **Get a specific wallet:**\
  `GET /api/v2.0/account/{idRef}/wallets/{walletType}/{currency}`

Each wallet returns:

* **Available balance**: Funds ready to be used
* **Hold balance**: Funds temporarily on hold
* **Account balance**: Total including holds and available
* **Last updated timestamp**

This data can be used in your portals, statements, or notifications.

***

#### Global Customer Balance (GCB)

If your account has multiple wallets, XYB can calculate a **Global Customer Balance** (GCB) - a consolidated balance across all wallets, normalized into a single currency.

* Use:\
  `GET /api/v2.0/account/{idRef}/wallets/gcb`\
  Or specify wallet type and currency for filtered views.

GCB is particularly useful for:

* Presenting a single unified balance to users
* Simplifying reconciliation across multiple currencies

***

#### Wallet Sweeping: Automate Balance Movement

Wallet **sweeping** lets you configure rules to move funds between wallets automatically,  for example, clearing a reserve wallet into the default wallet when thresholds are met.

How it works:

* The ledger emits balance updates.
* Account service detects available funds in secondary wallets.
* If rules match (e.g., “sweep if > 100 USD”), funds are moved.
* The resulting balance is updated and broadcast.

Sweeping is managed automatically by XYB’s backend. You can define rules via internal logic or work with the XYB team during onboarding to customize it.

***

#### Summary: Wallet Lifecycle at a Glance

| Action                 | Trigger                          | Tool/Endpoint                      |
| ---------------------- | -------------------------------- | ---------------------------------- |
| Define wallet strategy | Product Configuration            | Console or API (`/product-config`) |
| Create wallets         | Account creation                 | `POST /api/v2.0/account`           |
| View balances          | Any time                         | `GET /account/{id}/wallets`        |
| Consolidated GCB       | Real-time                        | `GET /account/{id}/wallets/gcb`    |
| Automate sweeping      | Based on rules & balance updates | Managed internally                 |

***


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.xyb.co/accounts/account-management/account-wallet-management-overview.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
