About mcp-open-finance
mcp-open-finance is an MCP server for Open Finance Brasil, aimed at applications and developers who need to read Brazilian bank data or initiate PIX payments. It covers accounts, transactions, consents, credit cards, loans and investments, and each institution supplies its own base URL and credentials.
Key features
- 01Account balance, transaction and overdraft queries
- 02Credit card bill and transaction lookup
- 03Loan, financing and investment product listings
- 04Data and payment consent creation and revocation
- 05Payment initiation and customer qualification lookup
Use cases
- 01Viewing a customer's bank accounts and transactions from an AI assistant
- 02Managing data sharing consents
- 03Initiating PIX payments under an authorized consent
MCP support
This is an MCP server that exposes 18 tools to MCP clients for reading data and managing consents and payments through an institution's Open Finance API.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
npx -y @codespar/mcp-open-financeOPEN_FINANCE_CLIENT_SECRETSecretAPI key for open-financeLocal servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.
Tools
18Saved tool list · updated 2w ago
| Parameter | Type | Required | Description |
|---|---|---|---|
| page | number | No | Page number |
| pageSize | number | No | Items per page |
| consentId | string | Yes | Consent ID (required for data access) |
Details
From the project README@codespar/mcp-open-finance
MCP server for Open Finance Brasil — open banking standard for accounts, transactions, and consents
Quick Start
Claude Desktop
Add to ~/.config/claude/claude_desktop_config.json:
{
"mcpServers": {
"open-finance": {
"command": "npx",
"args": ["-y", "@codespar/mcp-open-finance"],
"env": {
"OPEN_FINANCE_BASE_URL": "https://api.institution.com.br",
"OPEN_FINANCE_CLIENT_ID": "your-client-id",
"OPEN_FINANCE_CLIENT_SECRET": "your-client-secret"
}
}
}
}
Claude Code
claude mcp add open-finance -- npx @codespar/mcp-open-finance
Cursor / VS Code
Add to .cursor/mcp.json or .vscode/mcp.json:
{
"servers": {
"open-finance": {
"command": "npx",
"args": ["-y", "@codespar/mcp-open-finance"],
"env": {
"OPEN_FINANCE_BASE_URL": "https://api.institution.com.br",
"OPEN_FINANCE_CLIENT_ID": "your-client-id",
"OPEN_FINANCE_CLIENT_SECRET": "your-client-secret"
}
}
}
}
Tools (18)
| Tool | Purpose |
|---|---|
list_accounts | List customer bank accounts via Open Finance |
get_account_balance | Get account balance via Open Finance |
list_transactions | List account transactions via Open Finance |
get_account_overdraft_limits | Get account overdraft (limites) via Open Finance |
get_consent | Get consent details by ID |
create_consent | Create a new consent request for data access |
revoke_consent | Revoke an existing consent (data or payment) |
list_credit_cards | List credit card accounts via Open Finance |
get_credit_card_bills | Get credit card bills (faturas) via Open Finance |
get_credit_card_transactions | Get credit card transactions via Open Finance |
list_loans | List loan contracts (empréstimos) via Open Finance |
get_loan_payments | Get loan payment schedule via Open Finance |
list_financings | List financing contracts (financiamentos) via Open Finance |
list_investments | List investment products via Open Finance |
create_payment_consent | Create payment-initiation consent (e.g., PIX) via Open Finance |
create_payment | Initiate a payment using an authorized payment consent |
get_personal_qualifications | Get personal customer qualifications (income, occupation) via Open Finance |
get_business_qualifications | Get business customer qualifications via Open Finance |
Authentication
Open Finance Brasil uses OAuth2 client credentials. Each financial institution provides its own base URL and credentials.
Sandbox / Testing
Sandbox availability varies by institution. Contact your financial institution for Open Finance sandbox access.
Get your credentials
- Go to Open Finance Brasil
- Register with a participating financial institution
- Obtain your OAuth2 client credentials
- Set the environment variables
Environment Variables
| Variable | Required | Description |
|---|---|---|
OPEN_FINANCE_BASE_URL | Yes | Institution API base URL |
OPEN_FINANCE_CLIENT_ID | Yes | OAuth2 client ID |
OPEN_FINANCE_CLIENT_SECRET | Yes | OAuth2 client secret |
Roadmap
v0.2 (planned)
revoke_consent— Revoke a data sharing consentlist_payments— List initiated paymentscreate_payment_consent— Create a payment initiation consentinitiate_payment— Initiate a payment via Open Financeget_payment_status— Get payment initiation status
v0.3 (planned)
insurance_products— List insurance products from institutionspension_products— List pension products from institutions
Want to contribute? Open a PR or request a tool.
Links
Enterprise
Need governance, budget limits, and audit trails for agent payments? CodeSpar Enterprise adds policy engine, payment routing, and compliance templates on top of these MCP servers.
License
MIT
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.