npm package: @ktmcp-cli/bunq
Description: Production-ready CLI for Bunq API - neobank accounts, payments, and cards
Author: KTMCP
Latest version: 1.0.0

![Banner](https://raw.githubusercontent.com/ktmcp-cli/bunq/main/banner.svg)

> "Six months ago, everyone was talking about MCPs. And I was like, screw MCPs. Every MCP would be better as a CLI."
>
> — [Peter Steinberger](https://twitter.com/steipete), Founder of OpenClaw
> [Watch on YouTube (~2:39:00)](https://www.youtube.com/@lexfridman) | [Lex Fridman Podcast #491](https://lexfridman.com/peter-steinberger/)

# Bunq CLI

A production-ready command-line interface for the [Bunq](https://bunq.com) neobank API. Manage accounts, send payments, handle payment requests, and control cards — all from your terminal.

> **Disclaimer:** This is an unofficial, community-built CLI. It is not affiliated with, endorsed by, or supported by Bunq B.V. Use at your own risk. Always review the [Bunq API Terms of Service](https://www.bunq.com/en/terms-bunq-api) before use.

## Features

- **Accounts** — List and inspect monetary accounts with balances
- **Payments** — Send SEPA payments and view transaction history
- **Requests** — Create and track payment requests (by email, phone, or IBAN)
- **Cards** — View card details and transaction history
- **User** — Inspect authenticated user details
- **Auth** — Full Bunq authentication flow (installation + device + session)
- **JSON output** — All commands support `--json` for scripting and agent use
- **Sandbox support** — Test safely with Bunq sandbox environment

## Why CLI > MCP

| | MCP | CLI |
|---|---|---|
| Works in any shell script | No | Yes |
| Pipeable with `jq`, `grep`, `awk` | No | Yes |
| Usable by AI agents | Partial | Yes |
| No server process needed | No | Yes |
| Easy to audit | No | Yes |
| Works offline / cached | No | Yes |

CLIs compose. MCPs don't.

## Installation

```bash
npm install -g @ktmcp-cli/bunq
```

Requires Node.js 18+.

## Commands

```
bunq config set --api-key <key>       Set your Bunq API key
bunq config set --sandbox             Switch to sandbox mode
bunq config set --production          Switch to production mode
bunq config get                       Show current config
bunq config clear                     Clear all stored config

bunq auth setup                       Full authentication setup
bunq auth refresh                     Refresh session token
bunq auth status                      Show auth status

bunq accounts list                    List all monetary accounts
bunq accounts get <account-id>        Get account details

bunq payments list --account-id <id>  List payments for an account
bunq payments create ...              Create a new payment
bunq payments get <account-id> <id>   Get a specific payment

bunq requests list --account-id <id>  List payment requests
bunq requests create ...              Create a payment request
bunq requests get <account-id> <id>   Get a specific request

bunq cards list                       List all cards
bunq cards get <card-id>              Get card details
bunq cards transactions <card-id>     List card transactions

bunq user info                        Get authenticated user info
bunq user list                        List all accessible users
```

## Authentication

Bunq uses a multi-step authentication flow. The CLI handles all of it automatically.

### Step 1: Get your API key

Log into [Bunq web](https://www.bunq.com) or the mobile app → Profile → Security & Preferences → Developers → API Keys → Create API Key.

For sandbox access, register at [bunq.com/en/sandbox](https://www.bunq.com/en/sandbox).

### Step 2: Configure

```bash
bunq config set --api-key <YOUR_API_KEY>

# For sandbox:
bunq config set --api-key <SANDBOX_KEY> --sandbox
```

### Step 3: Authenticate

```bash
bunq auth setup
```

This registers an RSA installation, registers your device, and creates a session. Takes ~3 seconds.

Session tokens expire (typically after a week). Refresh with:

```bash
bunq auth refresh
```

## Examples

### List accounts and balances

```bash
bunq accounts list
```

```
ID        Description         Balance       Currency  Status  IBAN
--------  ------------------  ------------  --------  ------  ---------------------
12345678  My Main Account     1,234.56      EUR       ACTIVE  NL91ABNA0417164300
23456789  Savings Jar         500.00        EUR       ACTIVE  NL91ABNA0417164301
```

### Send a payment

```bash
bunq payments create \
  --account-id 12345678 \
  --amount 25.00 \
  --currency EUR \
  --iban NL91ABNA0417164300 \
  --name "John Doe" \
  --description "Dinner split"
```

### Request money via email

```bash
bunq requests create \
  --account-id 12345678 \
  --amount 15.50 \
  --counterparty-email john@example.com \
  --description "Coffee refund"
```

### Get recent transactions as JSON

```bash
bunq payments list --account-id 12345678 --limit 10 --json | jq '.[] | {amount, description}'
```

### Check your balance in a script

```bash
BALANCE=$(bunq accounts list --json | jq -r '.[0].balance.value')
echo "Balance: €$BALANCE"
```

### List cards

```bash
bunq cards list
```

## AI Agent Usage

This CLI is designed to be agent-friendly. See [AGENT.md](./AGENT.md) for full documentation on using `bunq` from AI agents (Claude, GPT-4, etc.).

```bash
# Typical agent workflow
bunq auth status
ACCOUNT_ID=$(bunq accounts list --json | jq -r '.[0].id')
bunq payments list --account-id $ACCOUNT_ID --limit 5 --json
```

## Configuration Storage

Config and tokens are stored securely in your system config directory:

- **Linux**: `~/.config/bunq-cli/`
- **macOS**: `~/Library/Preferences/bunq-cli/`
- **Windows**: `%APPDATA%/bunq-cli/`

## Contributing

Pull requests welcome. Please test changes against the Bunq sandbox environment.

## License

MIT © KTMCP

---

Part of the [KTMCP](https://killthemcp.com) project — CLIs as alternatives to MCPs.