COS
- typescript
28
GitHub Stars
typescript
Language
4 months ago
First Indexed
3 weeks ago
Catalog Refreshed
Documentation & install
Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.
You can connect Tencent COS with the MCP framework to automatically upload, process, and search cloud-stored data. This MCP Server lets you access COS storage and data processing features from large models without writing integration code, enabling tasks like uploading files, image analysis, OCR, video frame extraction, and AI-assisted retrieval directly through MCP.
How to use
Use an MCP client to interact with the COS MCP Server. You can run the server locally or remotely and connect to it via either HTTP (remote URL) or STDIO (local) modes. The server exposes capabilities such as uploading to COS, downloading, listing files, image processing, OCR, watermarking, and advanced retrieval. Configure your MCP client to point at the server’s URL or to launch the local process and forward IO accordingly.
How to install
Prerequisites: you need Node.js and npm installed on your system. Verify versions with node -v and npm -v.
Install the MCP package globally and run in SSE mode or configure via JSON for your MCP client.
# Install the COS MCP Server globally
npm install -g cos-mcp@latest
# Run in SSE mode with your configuration
cos-mcp --Region=yourRegion --Bucket=yourBucket --SecretId=yourSecretId --SecretKey=yourSecretKey --DatasetName=yourDatasetname --port=3001 --connectType=sse
# Or configure via JSON to specify the MCP server mapping
cos-mcp --cos-config='{"Region":"yourRegion","Bucket":"BucketName-APPID","SecretId":"yourSecretId","SecretKey":"yourSecretKey","DatasetName":"datasetName"}' --port=3001 --connectType=sse
If you prefer to start using a local stdio configuration from a JSON snippet, you can define the following MCP mapping to launch the server via npx.
{
"mcpServers": {
"cos-mcp": {
"command": "npx",
"args": [
"cos-mcp",
"--Region=yourRegion",
"--Bucket=yourBucket",
"--SecretId=yourSecretId",
"--SecretKey=yourSecretKey",
"--DatasetName=yourDatasetname"
]
}
}
}
Additional setup for local/remote modes
To run in remote HTTP mode, you can expose the server via an HTTP URL and connect your MCP client to that URL.
{
"mcpServers": {
"cos-mcp": {
"type": "http",
"name": "cos_mcp",
"url": "http://localhost:3001/sse",
"args": []
}
}
}
Available tools
Upload to COS
Upload files from your environment or MCP workflow directly into Tencent COS storage.
Download from COS
Retrieve files from COS storage to your local environment or MCP workflow.
List COS files
Get a list of files stored in a COS bucket for browsing and selection.
Image info
Obtain metadata and basic properties about images stored in COS.
Image super-resolution
Enhance image resolution using AI-based upscaling.
Image crop
Crop images to specified regions or aspect ratios.
QR code recognition
Detect and decode QR codes from images.
Image quality evaluation
Assess the visual quality of images using predefined metrics.
Text watermark
Apply or detect watermark text on images.
Metadata/NLP search
Index and search image/video metadata and natural language content (MateInsight).
PDF conversion
Convert documents to PDF format for standardized viewing.
Video cover
Generate or extract thumbnails for videos.