NoCFO CLI, MCP server, and Cursor skill toolkit.
Project description
Open-source Python toolkit that connects NoCFO to your terminal and AI workflows — a single package powering a CLI client, an MCP server, and a Cursor AI skill.
What You Can Ask
After connecting, you can ask your AI assistant things like:
- "How many sales invoices do I have this month?"
- "Who are my top 10 customers by revenue this year?"
- "Show unpaid invoices due this week."
- "List bookkeeping documents from January."
- "What was my VAT total last quarter?"
Why This Is Useful
- One connection gives your AI assistant direct access to NoCFO business data
- No need to manually export CSV files for common questions
- Works for both non-technical users and developers
Fastest Setup (Hosted MCP)
Use the hosted endpoint mcp.nocfo.io when your AI client supports remote MCP connectors.
Connect to Claude
- Open Claude settings and go to Connectors / MCP.
- Add a new connector.
- Enter server URL:
mcp.nocfo.io - Sign in with your NoCFO account when prompted.
- Open a new chat and test:
- "List my businesses"
- "Show this month's sales invoices"
Connect to ChatGPT
If your ChatGPT plan includes MCP/custom connectors:
- Open ChatGPT settings and go to Connectors / Integrations.
- Add a custom MCP connector.
- Set server URL to
mcp.nocfo.io - Complete sign-in flow with your NoCFO account.
- Test with:
- "List my contacts"
- "Show unpaid purchase invoices"
If your workspace does not yet show MCP/custom connector options, use the local setup below with Claude Desktop or Cursor.
Local Setup (Claude Desktop)
Use this when you want to run MCP locally on your machine.
1) Install the toolkit
pip install nocfo-cli
Alternative (no permanent install):
uvx nocfo-cli --help
2) Create NoCFO API token
- Open login.nocfo.io/auth/tokens
- Click Luo uusi avain / Create new key
- Name it (for example:
Claude Desktop) - Copy the token and save it to a password manager
3) Add NoCFO MCP to Claude config
Open Claude Desktop config and add:
{
"mcpServers": {
"nocfo": {
"command": "uvx",
"args": ["--from", "nocfo-cli", "nocfo", "mcp"],
"env": {
"NOCFO_JWT_TOKEN": "your_jwt_here"
}
}
}
}
Then restart Claude Desktop.
Claude config file locations
| OS | Path |
|---|---|
| Mac | ~/Library/Application Support/Claude/claude_desktop_config.json |
| Windows | %APPDATA%\Claude\claude_desktop_config.json |
Local Setup (Cursor)
Add the following to your Cursor MCP config (~/.cursor/mcp.json):
{
"mcpServers": {
"nocfo": {
"command": "uvx",
"args": ["--from", "nocfo-cli", "nocfo", "mcp"],
"env": {
"NOCFO_JWT_TOKEN": "your_jwt_here"
}
}
}
}
Then test with a simple prompt like "List my businesses".
CLI Quick Examples
nocfo user me
nocfo businesses list
nocfo invoices list --business <business_slug>
nocfo reports balance-sheet --business <business_slug> --date-at 2026-12-31
nocfo reports balance-sheet-short --business <business_slug> --date-at 2026-12-31
nocfo reports income-statement --business <business_slug> --date-from 2026-01-01 --date-to 2026-12-31
nocfo reports income-statement-short --business <business_slug> --date-from 2026-01-01 --date-to 2026-12-31
nocfo reports ledger --business <business_slug> --date-from 2026-01-01 --date-to 2026-01-31
nocfo reports journal --business <business_slug> --date-from 2026-01-01 --date-to 2026-01-31
nocfo reports vat --business <business_slug> --date-from 2026-01-01 --date-to 2026-01-31
nocfo reports equity-changes --business <business_slug> --date-at 2026-12-31
JSON output:
nocfo --output json businesses list
Advanced / Technical
MCP server modes
nocfo mcp= local stdio modenocfo mcp --transport http --auth-mode oauth --mcp-base-url mcp.nocfo.io= remote HTTP mode- Local stdio auth order:
NOCFO_JWT_TOKENfirst, thenNOCFO_API_TOKEN NOCFO_API_TOKENis optional for stdio whenNOCFO_JWT_TOKENis set
Detailed auth contract and troubleshooting are in MCP_AUTHENTICATION.md.
Auth precedence
| Priority | Source |
|---|---|
| 1 | --api-token CLI flag |
| 2 | NOCFO_API_TOKEN env var |
| 3 | ~/.config/nocfo-cli/config.json |
Default base URL: https://api-prd.nocfo.io
Default output format: table
CLI Command Groups
| Group | Description |
|---|---|
auth |
Configure and verify authentication |
businesses |
List and manage businesses |
accounts |
Chart of accounts |
documents |
Accounting entries and journal documents |
contacts |
Customer and supplier contacts |
invoices |
Sales invoices |
purchase-invoices |
Purchase invoices |
products |
Invoicing products |
files |
File attachments |
tags |
Document tags |
user |
Current user info |
mcp |
Start MCP server |
Development
poetry install # install dependencies
poetry run pytest # run tests
poetry run nocfo --help # run CLI locally
Regenerate OpenAPI-based command stubs:
poetry run python scripts/generate_cli_commands.py
Publishing to PyPI
poetry build
poetry config pypi-token.pypi <pypi_token>
poetry publish
For TestPyPI:
poetry config repositories.testpypi https://test.pypi.org/legacy/
poetry config pypi-token.testpypi <testpypi_token>
poetry publish -r testpypi
Security
- Never commit PAT tokens
- Keep
.envlocal only - Use separate tokens for test and production
- Local config contains secrets — do not share
License
MIT — see LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file nocfo_cli-1.3.0.tar.gz.
File metadata
- Download URL: nocfo_cli-1.3.0.tar.gz
- Upload date:
- Size: 29.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.3.3 CPython/3.12.13 Linux/6.17.0-1008-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a601fb6d04b8aa892affbb1822d39d509a265ebe093c2a927c4b2420b4df924c
|
|
| MD5 |
e8fa4d730eb01125835b7ca46581648f
|
|
| BLAKE2b-256 |
497d682a2d96025cbce6e10d4be978c30074b3a3637db70812eeb855ed7f5349
|
File details
Details for the file nocfo_cli-1.3.0-py3-none-any.whl.
File metadata
- Download URL: nocfo_cli-1.3.0-py3-none-any.whl
- Upload date:
- Size: 42.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.3.3 CPython/3.12.13 Linux/6.17.0-1008-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b750f46c07caf93a409777127698a662bb8ec6ffb7675ae4a471c483ddd9d6f5
|
|
| MD5 |
7e8b8bb22945bc2ba8fb00050bbf2fe2
|
|
| BLAKE2b-256 |
690f9384957878769e23b7ebf83798d04bf87e99060a8ee21fda3547f566edb6
|