# Kingdee K3Cloud MCP Server

> Query and operate Kingdee K3Cloud ERP through MCP using natural language.

- **URL**: https://followmcp.com/en/servers/kingdee-k3cloud-mcp
- **Category**: Other
- **Origin**: Community
- **Stars**: 113
- **FMRS Score**: 54/100 (Grade D)
- **Source**: https://github.com/adamzhang1987/kingdee-k3cloud-mcp
- **Transports**: stdio (local process), SSE, Streamable HTTP
- **Runtimes**: Python 3.10+
- **Auth**: API key / credential required

## Overview
Kingdee K3Cloud MCP Server wraps the Kingdee K3Cloud Web API as MCP tools for ERP queries and operations from MCP-capable AI assistants. It provides generic form queries, metadata discovery, pagination and date-range querying, as well as bill creation, submission, auditing, unauditing, deletion, custom operations, and push-down. It supports stdio, SSE, and streamable HTTP transports.

## Best for
- Teams connecting Kingdee K3Cloud ERP to MCP-capable AI assistants.
- Workloads requiring large queries, pagination, date-range searches, or file exports.
- Kingdee deployments using custom fields or form metadata.
- Deployments that want to disable write operations with read-only mode.

## Not for
- Use cases that do not involve Kingdee K3Cloud ERP.
- Use cases requiring different ERP identities for different callers; the server uses one configured integration user.
- Environments without Kingdee third-party system authorization or the required form permissions.

## Required permissions
- Requires the Kingdee server URL, account ID, integration username, application ID, and application secret.
- The integration user's Kingdee feature, data, and field permissions determine accessible data and available operations.
- File exports require a writable export directory on the host running the server; an isolated system temporary directory is used if no fixed directory is configured.
- Bearer Token authentication can be enabled with MCP_API_KEY for SSE or streamable HTTP; this connection authentication does not apply to stdio.

## Risks
- Read-write mode includes bill creation, submission, auditing, unauditing, deletion, and custom operations; grant only the needed integration-user permissions or use read-only mode to disable write tools.
- Insufficient data permissions may cause errors or silently filter results, producing fewer rows or an empty result.
- Exports write files on the server host. Export files are not removed when the service exits, and temporary directories may be cleaned by the system.
- All tool calls share the configured integration-user identity; callers cannot switch users.

## Client config (JSON)
```json
{"mcpServers":{"kingdee-k3cloud":{"command":"uvx","args":["kingdee-k3cloud-mcp"],"env":{"KD_SERVER_URL":"https://your-server/k3cloud/","KD_ACCT_ID":"your_acct_id","KD_USERNAME":"your_username","KD_APP_ID":"your_app_id","KD_APP_SEC":"your_app_secret","KD_LCID":"2052"}}}}
```

## Tools (15)
- `query_bill`: Query bill data and return it as a two-dimensional array.
- `query_bill_json`: Query bill data and return JSON with field names as keys.
- `count_bill`: Estimate the number of rows matching a query.
- `query_bill_all`: Automatically paginate and combine results until complete or a safety limit is reached.
- `query_bill_to_file`: Automatically paginate and stream query results to a local NDJSON or CSV file.
- `query_bill_range`: Query a date range in month, week, or day segments, with pagination and optional file output.
- `view_bill`: View the full details of a single record.
- `query_metadata`: Retrieve form field structure and metadata.
- `save_bill`: Save or create a bill.
- `submit_bill`: Submit a bill.
- `audit_bill`: Audit a bill.
- `unaudit_bill`: Unaudit a bill.
- `delete_bill`: Delete a bill.
- `execute_operation`: Run a custom operation, such as disabling or enabling a record.
- `push_bill`: Push a bill into another bill type, such as a sales order into a delivery notice.
