> For the complete documentation index, see [llms.txt](https://docs.xandtech.fr/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.xandtech.fr/home/xplayercurrencies/features/bank.md).

# Bank

Lets a player stash part of their balance in a separate, per-currency bank account, deposited money earning interest over time up to a cap that grows with paid tier upgrades.

Enable it per currency in `currencies/<id>.yml`:

```yaml
bank:
  enabled: true
  commands: ["bank"]              # e.g. "/bank" on top of "/coins bank"
  interest-interval-minutes: 60
  base-interest-rate-percent: 0.5
  base-max-balance: 10000
  tiers:
    - name: "Bronze Vault"
      upgrade-cost: 5000
      required-permission: ""
      interest-rate-percent: 1.5
      max-balance: 50000
    - name: "Silver Vault"
      upgrade-cost: 25000
      required-permission: "xplayercurrencies.bank.silver"
      interest-rate-percent: 3.0
      max-balance: 250000
```

| Key                                               | Description                                                                                                                                                                                                                                                    |
| ------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `commands`                                        | Extra top-level command(s) that open this currency's bank directly (e.g. `bank` for `/bank`), on top of `/currencies bank <id>` / `/coins bank`.                                                                                                               |
| `interest-interval-minutes`                       | How often money sitting in the bank earns interest. Applied in whole-interval jumps, so a player offline through several intervals still gets it all at once next time they're touched (join, deposit/withdraw/upgrade) - nothing is lost just for being away. |
| `base-interest-rate-percent` / `base-max-balance` | Rate and cap for the free base tier (tier 0) - everyone has this from the start, no upgrade needed.                                                                                                                                                            |
| `tiers`                                           | An **ordered** list of paid upgrades - tier 1 is the first entry, tier 2 the second, etc. Reaching tier N always means having paid for every tier below it first; there's no skipping ahead.                                                                   |

Each tier: `name`, `upgrade-cost` (paid from the wallet), `required-permission` (blank = cost only, no permission needed), `interest-rate-percent`, `max-balance`.

`bank.sounds` follows the same shape as [`shop.sounds`](/home/xplayercurrencies/features/shop.md#sounds) with its own events: `open`, `click`, `deposit-success`, `withdraw-success`, `upgrade-success`, `error`.

## Commands

| Command                       | Description                                                                                                  |
| ----------------------------- | ------------------------------------------------------------------------------------------------------------ |
| `/currencies bank [currency]` | Opens the bank menu. With no currency, auto-picks the only bank-enabled one (or shows a picker if several).  |
| `/coins bank`                 | Same, scoped to that currency (if `command`/`bank.commands` is set).                                         |
| `/currencies killcoins`       | (Unrelated name, historical) toggles the "interest received"/kill-coins actionbar notification for yourself. |

Requires `xplayercurrencies.bank` (default: `true`).

## Admin commands

All under `/currencies admin bank <action> ...` (`xplayercurrencies.admin`):

| Command                                        | Description                                                                                                                                                                 |
| ---------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `give\|take\|set <currency> <player> <amount>` | Directly modifies a player's bank balance. Bypasses the tier's max-balance cap (same "explicit override" philosophy as ordinary give/take/set), works on an offline target. |
| `reset <currency> <player>`                    | Resets the bank balance to 0.                                                                                                                                               |
| `tier <currency> <player> <tier>`              | Force-sets a player's tier level (0 = base).                                                                                                                                |
| `interest [currency]`                          | Force-pays interest immediately, skipping the wait for the next interval.                                                                                                   |

## Portable bank

A currency-agnostic physical item (config.yml `portable-bank`, see [Global Configuration](/home/xplayercurrencies/configuration/global-config.md#portable-bank)) that opens the bank menu when right-clicked, exactly like `/currencies bank` with no argument.

```
/currencies admin portablebank give <player> [amount]
```

Requires `xplayercurrencies.portablebank.use` (default: `true`) **on top of** `xplayercurrencies.bank`, which is still required too - so you can hand out the item without automatically granting bank access to everyone who has it.

## Leaderboard & PAPI

See [Leaderboard](/home/xplayercurrencies/features/leaderboard.md) for the bank-balance ranking, and [PlaceholderAPI](/home/xplayercurrencies/integrations/placeholderapi.md) for `bank_*` placeholders (balance, tier, rank, next interest, projected growth, etc).

Next: [Shop](/home/xplayercurrencies/features/shop.md).


---

# 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.xandtech.fr/home/xplayercurrencies/features/bank.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.
