# QingFlow MCP

> QingFlow connects your AI client to a no-code BPM platform, letting you run complex business processes through natural conversation. Your agent can list applications, retrieve form schemas, and manage records (create, update, delete) without needing to open any dashboard. It handles everything from HR approvals to asset tracking.

## Overview
- **Category:** productivity
- **Price:** Free
- **Tags:** no-code, bpm, workflow-automation, business-process, data-records, digital-transformation

## Description

You're running a business process through your AI client that normally requires logging into ten different dashboards just to check one status update. That’s pain. QingFlow changes that. You connect your agent, and it treats complex operational logic like a simple conversation. Instead of dealing with clunky forms or deep menus, you talk to the system, and your agent executes real business actions using specialized tools.

You start by figuring out what's available. Your agent uses `list_apps` to pull up every single business application running in your QingFlow workspace; it lets you see all accessible systems at a glance. Once you know which app you need, the system lets you check the data structure itself. You run `get_app_schema`, and that instantly shows you a list of every field name and its required data type for that application form.

For managing user access, your agent pulls up all accounts in the workspace using `list_users`. If you need an overview of automated processes, you can call `list_workflows` to get a summary of all defined workflow rules. To see what records exist within a specific app type, the tool runs `list_data`, giving you a roster of every record currently stored there.

The core function is handling data—the whole CRUD cycle. When you need to start something new, your agent uses `create_record` to generate an entirely fresh application record, filling in all the required data fields right from the chat conversation. If that record needs changes later on, it modifies specific details using `update_record`, saving those adjustments immediately. Conversely, if a record is obsolete or wrong, you can have your agent delete it with `delete_record`, assuming you've got the necessary permissions to do so.

When you just need to know what's in an existing file, your agent pulls the specific, current data for any record ID you provide via `get_record_details`. This gives you a clean readout of exactly what numbers and text are attached to that particular instance. Beyond basic reading, understanding progress is critical. You run `get_workflow_status` on any record to check its real-time approval stage—it tells you if it's 'Pending HR Review,' for example.

This whole setup means your agent doesn't guess or wander through menus; it runs specific code against the platform. It manages everything from tracking assets and handling payroll requests to processing vendor approvals, ensuring that every business rule gets followed correctly without you ever having to open a dashboard.

## Tools

### create_record
This tool creates a brand-new application record with specified data fields.

### delete_record
The agent deletes an existing application record, provided you have the necessary permissions.

### get_app_schema
It retrieves a list of all fields and their types for a given application form.

### get_record_details
This tool pulls the specific, current data from any existing record ID you provide.

### get_workflow_status
It checks and reports the precise stage an application record is in (e.g., 'Pending HR Review').

### list_apps
You can get a list of every single business application available within your QingFlow workspace.

### list_data
This tool lists all the records currently stored in a specific application type.

### list_users
It pulls a list of all user accounts that belong to your workspace.

### list_workflows
You can get an overview of all the automated workflow definitions available in the system.

### update_record
This tool modifies specific fields on a record that already exists, saving the changes immediately.

## Prompt Examples

**Prompt:** 
```
List all applications in my QingFlow workspace.
```

**Response:** 
```
I've retrieved your QingFlow applications. You have 5 active apps, including 'Expense Reimbursement', 'Leave Request', and 'Asset Management'. Which one would you like to explore?
```

**Prompt:** 
```
Show me the records for the 'Asset Management' application.
```

**Response:** 
```
I've listed the records for 'Asset Management'. I found 12 items, including 'MacBook Pro #001' and 'Dell Monitor #042'. Would you like the details of a specific record?
```

**Prompt:** 
```
What is the approval status for record 'req-9920' in 'Leave Request'?
```

**Response:** 
```
The leave request 'req-9920' is currently at the 'Department Head Approval' stage. It has been pending for 2 hours. Would you like me to send a reminder?
```

## Capabilities

### View Available Applications
You can list all accessible business applications within the QingFlow workspace using `list_apps`.

### Read and Write Data Records
The agent handles CRUD (Create, Read, Update, Delete) operations on application records through tools like `create_record`, `read_record_details`, and `update_record`.

### Check Workflow Progress
You get real-time status updates for any record's approval process using `get_workflow_status`.

### Understand Data Structure (Schema)
The agent retrieves the field structure of an application using `get_app_schema`, letting you know exactly what data fields exist.

### Manage Users and Teams
You can list workspace users with `list_users` to manage who has access or needs participation on a record.

## Use Cases

### The stalled expense report
A manager needs to know why 'exp-345' hasn't been approved. Instead of checking the HR system, they ask their agent. The agent runs `get_workflow_status`, discovers it's stuck at 'Finance Review,' and tells the manager who needs to follow up.

### Onboarding a new employee
The IT department uses the AI client to onboard an asset. They run `list_users` to find the correct team lead, then use `create_record` with specific asset data and assign it to that user.

### Fixing bad application data
A record was created incorrectly. The agent first runs `get_app_schema` to confirm the required fields, then uses `update_record` to correct the owner and status without deleting the entire entry.

### Inventory check for assets
You need a quick list of all asset records. You run `list_data`, get 40 items, spot the missing serial number 'SN-901', and immediately use `get_record_details` to pull up its history.

## Benefits

- Check status instantly: Instead of digging through a dashboard, use `get_workflow_status` to know exactly which approval step a record is stuck on. This saves time tracking down bottlenecks.
- See your whole system at once: Use `list_apps` to get an inventory of every application in the workspace. You'll instantly remember that 'Asset Management' exists, even if you haven't used it recently.
- Audit data structure fast: Need to know what fields are on a form? Call `get_app_schema`. It spits out the field types and widget IDs so developers don't have to guess.
- Modify records without clicks: Use `update_record` when you need to change a specific date or owner. You just tell your agent, 'Update record X with Y data,' and it handles the payload.
- Maintain clean history: Need to start a new process? Run `create_record`. It ensures the initial application is set up correctly before any work begins.

## How It Works

The bottom line is: you talk to your agent like a human, but it executes complex, multi-step backend operations on QingFlow for you.

1. Subscribe to the QingFlow MCP Server and input your unique Access Token.
2. Instruct your AI client (e.g., 'List all applications for HR').
3. The agent calls the necessary tool (`list_apps`), receives structured data, processes it, and presents a conversational answer.

## Frequently Asked Questions

**How does QingFlow MCP Server handle permissions?**
The server manages access control through your provided Access Token and relies on the underlying platform's user lists (`list_users`). Your agent only executes tools for which the connected workspace grants permission.

**Can I use QingFlow MCP Server to create records?**
Yes. You use `create_record` when you need to start a new application instance. You must provide all required field data in the payload, otherwise the creation will fail.

**Do I need to know the schema to use QingFlow MCP Server?**
No. Your agent handles that for you; it calls `get_app_schema` behind the scenes when needed so that write operations like `create_record` or `update_record` are structured correctly.

**What is the difference between list_data and get_record_details?**
`list_data` shows you a paginated list (the index) of many records in an app. `get_record_details` pulls up all the specific fields for one single record ID.

**Does `list_data` support pagination when I have a large number of records?**
Yes, it handles large datasets using offset and limit parameters. You specify the required page size and starting point to retrieve record sets exceeding the default API limits.

**What happens if I try to `update_record` with an invalid or deleted ID?**
The server returns a clear 404 error code, telling you the record ID doesn't exist. You must use `get_record_details` first to confirm the correct identifier before making any changes.

**How does using `list_apps` help me understand my available applications?**
Calling `list_apps` gives you a complete list of every application QingFlow manages for your workspace. This quickly shows you which domains and structures are accessible via the MCP server.

**Can I use `get_workflow_status` to see the full history of changes?**
The tool provides the record's current status and its last known stage. For a complete audit trail, you must cross-reference this API data with the application's internal change logs.

**How do I find my QingFlow Access Token?**
Log in to QingFlow, go to the Qing Store (轻商城), install the 'OPEN API' plugin under Third-party Connections, and find your Access Token in the plugin configuration.

**Can I check why a request is pending approval?**
Yes. Using the `get_workflow_status` tool with the application and record IDs, you can retrieve the current approval node, the person responsible, and the status of the process.

**How do I format the data for creating a record?**
QingFlow uses a specific format for its fields. Use the `get_app_schema` tool first to see the `queId` for each field, then provide the data as a JSON string following the required structure.