bizSupply MCP Server
Connect your AI assistant (Claude Desktop, Cursor, Claude Code) to bizSupply using the Model Context Protocol (MCP).
Connect your AI assistant (Claude Desktop, Cursor, Claude Code) to bizSupply using the Model Context Protocol (MCP).
What is MCP?
The Model Context Protocol (MCP) is an open standard that lets AI assistants interact directly with external tools and data sources. bizSupply runs a hosted HTTP MCP server that exposes your workspace as a set of tools your assistant can call in conversation. There is nothing to install and run locally — you point your client at the hosted endpoint and authenticate with an API key.
Once connected, your AI can:
- Manage documents — list, search, view content and extracted data.
- Develop plugins — validate, create, update, and test plugins.
- Execute pipelines — run document processing workflows.
- Monitor jobs — track execution status and results.
- Manage ontologies — define extraction schemas.
- Work with prompts — create and manage LLM prompt templates.
The assistant calls the bizSupply API on your behalf through the MCP tool interface, and everything stays scoped to your active organization.
In-product use case. bizSupply's own support assistant ("bizAssistant") uses MCP internally — when you ask it "show me my recent documents" or "why did my last job fail?", it calls the same list_documents, get_job_status, and list_sources tools documented below through an HTTP MCP client that forwards your session token. Same protocol, same auth boundary, same tenant scoping — just plumbed from inside the product rather than from an external client like Claude Desktop.
Quick Start
1. Get an API Key
Create an API key via the API (or ask your bizSupply administrator to provision one):
curl -X POST "https://api.bizsupply.ai/api/v1/api-keys" \
-H "Authorization: Bearer <your-jwt-token>" \
-H "Content-Type: application/json" \
-d '{"name": "my-ai-assistant"}'The response contains your API key (shown only once):
{
"api_key": "bsp_K7xH2mN9pQ4wR6tY8uI1oL3jK5nB7vC9...",
"name": "my-ai-assistant",
"created_at": "2024-01-15T10: 30: 00Z"
}Store the key somewhere safe — it is shown only once. If you lose it, revoke it and create a new one.
2. Connect Your AI Client
Claude Code
claude mcp add --scope user --transport http bizsupply \
https://api.bizsupply.ai/mcp \
--header "X-API-Key: bsp_<your-api-key>"Claude Desktop
Add to your Claude Desktop configuration file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"bizsupply": {
"transport": "http",
"url": "https://api.bizsupply.ai/mcp",
"headers": {
"X-API-Key": "bsp_<your-api-key>"
}
}
}
}Cursor
Add to your Cursor MCP settings:
{
"mcp": {
"servers": {
"bizsupply": {
"transport": "http",
"url": "https://api.bizsupply.ai/mcp",
"headers": {
"X-API-Key": "bsp_<your-api-key>"
}
}
}
}
}3. Verify the Connection
Ask your AI assistant:
"Use the bizsupply ping tool to check the connection."
You should see a successful response confirming the connection.
Available Tools
Each tool maps to one or more bizSupply API endpoints. All tools are scoped to your active organization.
Public
| Tool | Description |
|---|---|
ping | Check server connectivity. |
server_info | Get server version and list available tools. |
Document Operations
| Tool | Description |
|---|---|
list_documents | List your documents with pagination. |
list_documents_filtered | Advanced filtering by labels, source, and dates. |
get_document | Get document details by ID. |
get_document_content | Get parsed text content. |
get_document_extracted_data | Get extracted structured data. |
get_document_relationships | Get linked / related documents. |
download_document | Download the original file (see size-limit note below). |
search_documents | Search by filename or content. |
get_document_stats | Statistics by source / labels. |
download_document size limit (format=base64). The inline-bytes path is bounded by the platform's configured maximum file size (the same ceiling enforced by the parsing / LLM pipeline). Files above the cap return a BLOB_TOO_LARGE (HTTP 400) error instead of overwhelming the processing engine. Use format=url to obtain a signed URL for arbitrarily large files — the URL path is not affected by this cap.
Plugin Development
| Tool | Description |
|---|---|
validate_plugin | Validate code before registration. |
list_plugins | List available plugins. |
get_plugin | Get plugin details. |
get_plugin_code | Get plugin source code. |
create_plugin | Register a new plugin. |
update_plugin | Update plugin code. |
delete_plugin | Remove a plugin. |
Pipeline Management
| Tool | Description |
|---|---|
list_pipelines | List configured pipelines. |
get_pipeline | Get pipeline configuration. |
create_pipeline | Create a pipeline from plugins. |
execute_pipeline | Start a pipeline execution. |
delete_pipeline | Remove a pipeline. |
Job Monitoring
| Tool | Description |
|---|---|
list_jobs | List jobs with status filters. |
get_job_status | Get detailed job status. |
cancel_job | Cancel a running job. |
get_last_sync | Get the last sync timestamp. |
Ontology Management
| Tool | Description |
|---|---|
list_ontologies | List ontologies. |
get_ontology | Get an ontology with its hierarchy. |
get_ontology_fields | Get fields for specific labels. |
create_ontology | Create an ontology from YAML. |
update_ontology | Update an ontology taxonomy. |
delete_ontology | Remove an ontology. |
list_pending_reviews | List ontology reviews awaiting approval (platform administrators). |
approve_review | Approve and persist an ontology (platform administrators). |
reject_review | Reject an ontology review with a reason (platform administrators). |
Prompt Templates
| Tool | Description |
|---|---|
list_prompts | List prompt templates. |
get_prompt | Get a prompt with its content. |
create_prompt | Create a new prompt template. |
update_prompt | Update prompt content. |
delete_prompt | Remove a prompt. |
Source Management
| Tool | Description |
|---|---|
list_sources | List connected sources. |
get_source_details | Get full source information. |
get_source_state | Get plugin execution state. |
update_auto_sync | Configure auto-sync settings. |
Benchmark & Analytics
| Tool | Description |
|---|---|
list_benchmarks | List available benchmarks. |
get_document_score | Get a document quality score. |
get_actions_required | List documents needing attention. |
get_contract_renewals | List upcoming contract renewals. |
Role Guards and Permissions
Write Operations Require ADMIN or OWNER Role
All destructive MCP tools (create, update, delete) require the authenticated user to have the ADMIN or OWNER role in their active organization. Read-only tools (list, get, search) are available to all roles.
| Domain | Read tools (all roles) | Write tools (ADMIN / OWNER) |
|---|---|---|
| Plugins | list_plugins, get_plugin, get_plugin_code, validate_plugin | create_plugin, update_plugin, delete_plugin |
| Pipelines | list_pipelines, get_pipeline | create_pipeline, execute_pipeline, delete_pipeline |
| Ontologies | list_ontologies, get_ontology, get_ontology_fields | create_ontology, update_ontology, delete_ontology |
| Prompts | list_prompts, get_prompt | create_prompt, update_prompt, delete_prompt |
| Sources | list_sources, get_source_details, get_source_state | update_auto_sync |
If a user without the required role attempts a write operation, the tool returns: "Insufficient permissions. OWNER or ADMIN role required."
Platform Administrator Tools
The ontology review tools are restricted to platform administrators:
| Tool | Description | Access |
|---|---|---|
list_pending_reviews | List ontology reviews awaiting approval. | Platform administrators only |
approve_review | Approve and persist an ontology. | Platform administrators only |
reject_review | Reject with a reason. | Platform administrators only |
stdio Transport (for clients without native HTTP support)
For clients that do not support HTTP transport natively, use mcp-remote to bridge stdio to HTTP:
{
"mcpServers": {
"bizsupply": {
"command": "npx",
"args": [
"mcp-remote",
"https://api.bizsupply.ai/mcp",
"--header",
"X-API-Key: bsp_<your-api-key>"
]
}
}
}The mcp-remote package translates stdio to HTTP, allowing any MCP client to connect to the bizSupply server.
Plugin Development Workflow
The MCP integration is especially powerful for plugin development. The recommended workflow is validate → fix → register → test.
Step 1: Check the plugin interface
Ask your AI:
"What are the requirements for a bizSupply classification plugin?"
The AI can reference the Plugin Interface documentation.
Step 2: Write the plugin code
Work with your AI to write the plugin. The assistant has access to plugin templates, the available service methods, and best practices.
Step 3: Validate before registration
Always validate first to catch errors early:
"Use validate_plugin to check this classification plugin code: [your code]"
Validation returns detailed feedback, including the offending line and a fix suggestion:
{
"valid": false,
"errors": [{
"error_type": "method_not_async",
"message": "Method 'classify' must be async",
"severity": "error",
"hint": "Change 'def classify' to 'async def classify'",
"line": 5
}]
}Step 4: Fix and re-validate
The AI can interpret the error and help you fix it:
"Fix the async issue and validate again."
Step 5: Register the plugin
Once validation passes:
"Create the plugin with this code."
The plugin then enters the platform's human-review gate before it can run.
Step 6: Test in a pipeline
"Create a pipeline with my new plugin and execute it on my documents."
Example Conversations
Once configured, you interact with bizSupply through natural language. A few examples:
List my documents
"Show me my recent documents from Gmail."
The assistant uses list_documents_filtered with the appropriate filters and presents the results in a formatted table.
Search for contracts
"Find all documents labeled 'contract' that mention 'renewal'."
The assistant uses search_documents with label and content filters.
Create a classification plugin
"Help me create a plugin that classifies documents as invoices, contracts, or receipts based on their content."
The assistant references the plugin interface, helps write the code, validates it with validate_plugin, and registers it with create_plugin.
Monitor processing
"What's the status of my last pipeline execution?"
The assistant uses list_jobs and get_job_status to report the status, progress counts, and any errors.
Authentication
API Key Authentication
API keys authenticate requests through the platform's API gateway. Two header formats are accepted:
Dedicated header (preferred):
X-API-Key: bsp_<your-api-key>Bearer token (for clients that only support Authorization headers):
Authorization: Bearer bsp_<your-api-key>The bsp_ prefix lets the gateway distinguish API keys from JWT tokens. When Authorization: Bearer bsp_... is detected, the request is routed through the API-key path instead of JWT validation.
API Key Format
bizSupply API keys have the format:
bsp_<opaque-key>Example: bsp_K7xH2mN9pQ4wR6tY8uI1oL3jK5nB7vC9dE0fG1hI2jK3lM4n
Managing API Keys
Create and manage keys via the platform API (requires JWT authentication):
="color:#5c6370;font-style:italic"># Create a key (plaintext returned only once)
curl -X POST "https://api.bizsupply.ai/api/v1/api-keys" \
-H "Authorization: Bearer <your-jwt-token>" \
-H "Content-Type: application/json" \
-d '{"name": "my-ai-assistant"}'
="color:#5c6370;font-style:italic"># List keys (metadata only, no plaintext)
curl "https://api.bizsupply.ai/api/v1/api-keys" \
-H "Authorization: Bearer <your-jwt-token>"
="color:#5c6370;font-style:italic"># Revoke a key (cannot be undone)
curl -X DELETE "https://api.bizsupply.ai/api/v1/api-keys/<key-id>" \
-H "Authorization: Bearer <your-jwt-token>"Security Best Practices
- Never share your API key in public repositories or chat logs.
- Rotate keys periodically — create new keys and revoke old ones.
- Use descriptive names — name keys by purpose (e.g., "claude-desktop-home").
- Revoke unused keys — remove keys you no longer need.
Key Permissions
API keys inherit the permissions of the user who created them:
- Access to the user's documents.
- Access to the user's plugins (user scope) and the organization's plugins (tenant scope).
- Read-only access to global plugins.
- Write operations still require the ADMIN or OWNER role (same as JWT auth).
Troubleshooting
Connection failed
Symptom: the AI reports it cannot connect to bizSupply.
- Verify the API key is correct (no extra spaces).
- Check the URL is
https://api.bizsupply.ai/mcp. - Ensure the API key hasn't been revoked.
Authentication error
Symptom: tools return "unauthorized" or "invalid API key".
- Create a new API key.
- Update your AI client configuration.
- Restart your AI client.
Tool not found
Symptom: the AI says a tool doesn't exist.
- Verify the MCP connection with
ping. - Use
server_infoto list available tools. - Check the tool-name spelling (tools use
snake_case).
Validation errors
Symptom: plugin validation fails.
- Read the error message carefully — it includes fix suggestions.
- Check the Plugin Interface specification.
- Ensure all required methods are
async. - Verify the base-class inheritance.
Security Considerations
The MCP server is hosted by bizSupply and reached over HTTPS using your API key. Keep the following in mind:
- Your API key is stored in your MCP client's configuration file. Ensure that file has appropriate file-system permissions.
- All communication uses HTTPS; there is no insecure HTTP option.
- The MCP server inherits the permissions of the API key you connect with. Use a key with the minimum access required for your workflow.
- Credential secrets are never returned through MCP tools — only credential names and types are visible.
Next Steps
- Plugin Interface — the required plugin contract.
- Create a Plugin — step-by-step plugin development.
- Plugin Service API — available helper methods.
Support
For MCP integration issues:
- Check this documentation first.
- Contact your bizSupply administrator.
- Email
support@bizsupply.ai.