{"id":"69935613-6fe6-460b-921f-b42464b308e4","slug":"mcp-pennylane-company","kind":"mcp","name":"mcp-pennylane-company","summary":"","owner":"studio-catapulte","repoUrl":"https://github.com/studio-catapulte/mcp-pennylane-company","license":"MIT","licenseTier":"permissive","trust":"community","stars":1,"match":null,"fewStars":true,"format":"mcp","createdAt":"2025-05-20T20:15:10.000Z","addedAt":"2026-10-21T15:14:02.207Z","logoUrl":"https://avatars.githubusercontent.com/u/256236086?v=4","linkOnly":false,"collection":null,"skillPath":null,"categories":["utilities"],"tags":[],"runtime":"binary","local":true,"cloudCapable":false,"cloudCapability":"unknown","cloudReadyOnPlatform":false,"needsApiKey":false,"reviewed":false,"syncedAt":"2026-10-23T06:33:02.435Z","sample":false,"url":"https://conduits.dev/tools/mcp-pennylane-company","language":"Python","transports":["stdio"],"install":{},"requirements":{"env":[],"upstreamMayCharge":false},"tools":null,"readme":"# MCP Pennylane - Model Context Protocol Server for Pennylane Accounting\n\nA comprehensive MCP (Model Context Protocol) server that enables LLMs to interact with Pennylane accounting software through tools, resources, and prompts.\n\n## Features\n\n### 🛠️ **85 Tools** - Perform actions in Pennylane\n- **Accounting**: Journals, ledger entries, trial balance, fiscal years\n- **Invoicing**: Create, send, and manage customer/supplier invoices\n- **Banking**: Transaction reconciliation and categorization\n- **Analytics**: Categories and analytical reporting\n- **File Management**: Document attachments and uploads\n\n### 📊 **7 Resources** - Access structured data\n- Company information and settings\n- Chart of accounts with smart grouping\n- Customer and product catalogs\n- Recent invoices and transactions\n- Analytics categories hierarchy\n\n### 💬 **14 Prompts** - Guided workflows\n- Invoice creation and processing\n- Transaction recording and reconciliation\n- Financial analysis and reporting\n- Period closing procedures\n- Cash flow forecasting\n\n## Installation\n\n1. Clone the repository:\n```bash\ngit clone https://github.com/StudioCatapulte/mcp-pennylane-company.git\ncd mcp-pennylane-company\n```\n\n2. Create a virtual environment:\n```bash\npython -m venv venv\nsource venv/bin/activate  # On Windows: venv\\Scripts\\activate\n```\n\n3. Install dependencies:\n```bash\n# For production use:\npip install -r requirements.txt\n\n# For development (includes testing and linting tools):\npip install -r requirements-dev.txt\n\n# For exact reproducible environment:\npip install -r requirements-lock.txt\n```\n\n4. Configure environment:\n```bash\ncp .env.example .env\n# Edit .env with your Pennylane API credentials\n```\n\n## Configuration\n\n### API Key Authentication\n```env\nPENNYLANE_API_KEY=your_api_key_here\nPENNYLANE_BASE_URL=https://app.pennylane.com/api/external/v2\n```\n\n### OAuth Authentication (Advanced)\n```env\nUSE_OAUTH=true\nOAUTH_CLIENT_ID=your_client_id\nOAUTH_CLIENT_SECRET=your_client_secret\nOAUTH_REDIRECT_URI=http://localhost:8000/callback\n```\n\n## Usage with Claude Desktop\n\nAdd to your Claude Desktop configuration (`~/Library/Application Support/Claude/claude_desktop_config.json`):\n\n```json\n{\n  \"mcpServers\": {\n    \"pennylane\": {\n      \"command\": \"python\",\n      \"args\": [\"/path/to/mcp-pennylane-company/src/server.py\"],\n      \"env\": {\n        \"PENNYLANE_API_KEY\": \"your_api_key_here\"\n      }\n    }\n  }\n}\n```\n\n## Transport Options\n\nThe Pennylane MCP server supports multiple transport protocols:\n\n### STDIO Transport (Default)\nBest for local tools and Claude Desktop integration:\n\n```bash\n# Run with default STDIO transport\npython src/server.py\n\n# Or explicitly specify STDIO\npython src/server.py --transport stdio\n```\n\n### Streamable HTTP Transport\nRecommended for web deployments and remote access:\n\n```bash\n# Run with Streamable HTTP on default port 8000\npython src/server.py --transport streamable-http\n\n# Custom configuration\npython src/server.py --transport streamable-http --host 0.0.0.0 --port 9000\n\n# With debug logging\npython src/server.py --transport streamable-http --log-level debug\n```\n\n**Features:**\n- Single endpoint for all communication (`/mcp`)\n- Health check endpoint at `/health`\n- Bi-directional communication\n- Automatic connection upgrades for long-running tasks\n\n### Using the HTTP Client\n\n```python\nfrom fastmcp import Client\n\n# Connect to HTTP server\nasync with Client(\"http://localhost:8000/mcp\") as client:\n    # Call tools\n    result = await client.call_tool(\"pennylane_customers_list\", {\"limit\": 10})\n    \n    # Read resources\n    data = await client.read_resource(\"pennylane://company/info\")\n```\n\nSee `examples/http_client_example.py` for a complete example.\n\n### Using with FastMCP CLI\n\n```bash\n# Run with CLI (overrides any transport in code)\nfastmcp run src/server.py --transport streamable-http --port 9000\n\n# Development mode with inspector\nfastmcp dev src/server.py\n```\n\n## Example Workflows\n\n### Creating an Invoice\n```\n1. Check customer exists: Use resource pennylane://customers/recent/10\n2. Get products: Use resource pennylane://products/catalog/20\n3. Get guidance: Use prompt create_invoice_prompt\n4. Create invoice: Use tool pennylane_invoices_create\n5. Send invoice: Use tool pennylane_invoices_send_email\n```\n\n### Recording a Transaction\n```\n1. Get guidance: Use prompt record_transaction_prompt\n2. View accounts: Use resource pennylane://chart_of_accounts/all\n3. Select journal: Use resource pennylane://journals\n4. Create entry: Use tool pennylane_ledger_entries_create\n5. Categorize: Use tool pennylane_ledger_entry_lines_categorize\n```\n\n### Financial Analysis\n```\n1. Set parameters: Use prompt analyze_finances_prompt\n2. Get company info: Use resource pennylane://company/info\n3. View invoices: Use resource pennylane://invoices/recent/customer/50\n4. Generate report: Use prompt generate_report_prompt\n5. Export data: Use tool pennylane_export_analytical_ledger_create\n```\n\n## Resource Examples\n\n### Company Information\n```\npennylane://company/info\nReturns: Company settings, fiscal years, currency, country\n```\n\n### Chart of Accounts\n```\npennylane://chart_of_accounts/411  # Customer accounts only\npennylane://chart_of_accounts/all  # All accounts grouped by type\n```\n\n### Recent Data\n```\npennylane://customers/recent/20    # Last 20 customers\npennylane://invoices/recent/customer/10  # Last 10 customer invoices\npennylane://products/catalog/50    # 50 products from catalog\n```\n\n## Prompt Examples\n\n### Invoice Creation\n```python\ncreate_invoice_prompt(\n    customer_info=\"ABC Corp, VAT: FR12345678901\",\n    products_services=\"5 hours consulting at 150€/hour\",\n    invoice_type=\"standard\",\n    special_requirements=\"Net 30 payment terms\"\n)\n```\n\n### Transaction Recording\n```python\nrecord_transaction_prompt(\n    transaction_type=\"sale\",\n    amount=1500.00,\n    description=\"Consulting services - Project X\",\n    date=\"2024-01-15\"\n)\n```\n\n### Financial Analysis\n```python\nanalyze_finances_prompt(\n    analysis_period=\"2024-Q1\",\n    focus_areas=[\"revenue\", \"cash_flow\"],\n    comparison_period=\"2023-Q4\"\n)\n```\n\n## Architecture\n\n```\nsrc/\n├── server.py          # Main MCP server\n├── mcp_instance.py    # FastMCP configuration\n├── config.py          # Settings management\n├── tools/             # 85 API tools\n├── resources/         # 7 data resources\n├── prompts/           # 14 workflow prompts\n└── utils/             # API client and helpers\n```\n\n## Development\n\n### Running Tests\n```bash\npython -m pytest tests/\n```\n\n### Adding New Features\n1. **Tools**: Add to `src/tools/` following existing patterns\n2. **Resources**: Add to `src/resources/` with proper URI scheme\n3. **Prompts**: Add to `src/prompts/` with clear parameter descriptions\n\n## API Coverage\n\n| Category | Coverage | Features |\n|----------|----------|----------|\n| Accounting | ✅ 100% | Journals, entries, accounts, balance |\n| Invoicing | ✅ 100% | Customer/supplier invoices, credit notes |\n| Banking | ✅ 100% | Transactions, reconciliation, accounts |\n| Analytics | ✅ 100% | Categories, groups, categorization |\n| Files | ✅ 100% | Attachments, uploads, appendices |\n| Exports | ✅ 100% | FEC, analytical ledger |\n\n## Documentation\n\n- [Complete Feature Guide](documentation/MCP_FEATURES.md)\n- [API Reference](documentation/api_pennylane_doc/)\n- [MCP Protocol Details](documentation/mcp/)\n\n## License\n\nMIT License - see [LICENSE](LICENSE) file for details.\n\n## Support\n\nFor issues or questions:\n1. Check the [Feature Guide](documentation/MCP_FEATURES.md)\n2. Review server logs for detailed errors\n3. Ensure API credentials are valid\n4. Open an issue on GitHub\n\n---\n\n## Author\n\n**Guillaume Sayer** - [Studio Catapulte](https://catapulte.studio)\n\n---\n\nBuilt with [FastMCP](https://github.com/jlowin/fastmcp) and the [Model Context Protocol](https://modelcontextprotocol.io) by Anthropic."}