Skip to main content
Glama
osshub.toml.example6.5 kB
# OssHub Multi-Source Object Storage Configuration Example # Save this file as 'osshub.toml' in your project directory # Or use '--config=path/to/your/config.toml' to specify a custom location # Define multiple storage sources using [[sources]] array syntax # Each source requires a unique 'id' field for identification ## Example 1: Huawei Cloud OBS [[sources]] id = "huawei_obs" # Required: Unique identifier type = "obs" # Required: Provider type (obs, oss, s3, cos, minio) endpoint = "https://obs.cn-east-2.myhuaweicloud.com" # Required: Service endpoint access_key = "your-access-key-id" # Required: Access Key ID secret_key = "your-secret-access-key" # Required: Secret Access Key region = "cn-east-2" # Optional: Region default_bucket = "my-bucket" # Optional: Default bucket to use connection_timeout = 60 # Optional: Connection timeout in seconds (default: 60) ssl = true # Optional: Enable SSL/TLS (default: true) ## Example 2: Alibaba Cloud OSS [[sources]] id = "aliyun_oss" # Required: Unique identifier type = "oss" # Required: Provider type endpoint = "https://oss-cn-hangzhou.aliyuncs.com" # Required: Service endpoint access_key = "your-access-key-id" # Required: Access Key ID secret_key = "your-secret-access-key" # Required: Secret Access Key region = "cn-hangzhou" # Optional: Region # security_token = "sts-token" # Optional: STS token for temporary credentials ## Example 3: AWS S3 [[sources]] id = "aws_s3" # Required: Unique identifier type = "s3" # Required: Provider type endpoint = "https://s3.amazonaws.com" # Required: Service endpoint access_key = "AKIAIOSFODNN7EXAMPLE" # Required: Access Key ID secret_key = "wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY" # Required: Secret Access Key region = "us-east-1" # Optional: Region (default: us-east-1) path_style = false # Optional: Use path-style URLs (default: true for S3-compatible) ## Example 4: MinIO (S3-Compatible) [[sources]] id = "local_minio" # Required: Unique identifier type = "s3" # Required: Use 's3' type for S3-compatible services endpoint = "http://localhost:9000" # Required: MinIO endpoint access_key = "minioadmin" # Required: Access Key ID secret_key = "minioadmin" # Required: Secret Access Key path_style = true # Required for MinIO: Use path-style URLs ## Example 5: Tencent Cloud COS (coming soon) # [[sources]] # id = "tencent_cos" # type = "cos" # endpoint = "https://cos.ap-guangzhou.myqcloud.com" # access_key = "your-secret-id" # secret_key = "your-secret-key" # region = "ap-guangzhou" # Connection Parameters Reference: # -------------------------------- # # REQUIRED FIELDS: # ---------------- # - id: Unique identifier for this storage source (string) # - type: Provider type (obs, oss, s3, cos, minio) # - endpoint: Service endpoint URL # - access_key: Access Key ID # - secret_key: Secret Access Key # # OPTIONAL FIELDS: # ---------------- # - region: Region identifier # - default_bucket: Default bucket name # - connection_timeout: Connection timeout in seconds (default: 60) # - security_token: STS token for temporary credentials # - ssl: Enable SSL/TLS (default: true) # - path_style: Use path-style URLs (default: true for S3-compatible) # # SUPPORTED PROVIDERS: # -------------------- # - obs: Huawei Cloud OBS (Object Storage Service) # - oss: Alibaba Cloud OSS (Object Storage Service) # - s3: AWS S3 / S3-Compatible (MinIO, Backblaze B2, DigitalOcean Spaces, etc.) # - cos: Tencent Cloud COS (coming soon) # - minio: MinIO (use type = "s3" with path_style = true) # Built-in Tools Configuration # ---------------------------- # Built-in tools (list_buckets, list_objects, get_object, get_object_metadata, search_objects) # are automatically enabled for all sources unless explicitly configured here. ## Example: Limit list_objects results on production source [[tools]] name = "list_objects" source = "huawei_obs" max_keys = 500 # Limit to 500 objects per request ## Example: Limit get_object size for text content [[tools]] name = "get_object" source = "huawei_obs" max_size = 5242880 # Limit to 5MB (5 * 1024 * 1024 bytes) ## Example: Limit search results [[tools]] name = "search_objects" source = "aliyun_oss" max_results = 50 # Limit to 50 results # Custom Tools (coming soon) # -------------------------- # Define custom tools for specific operations like filtering by file type, # batch operations, etc. ## Example: Custom tool for listing images # [[tools]] # name = "list_images" # description = "List all image files in a bucket" # source = "huawei_obs" # operation = "search" # [tools.filter] # extensions = [".jpg", ".jpeg", ".png", ".gif", ".webp"] # max_results = 100 ## Example: Custom tool for listing recent documents # [[tools]] # name = "list_recent_docs" # description = "List documents modified in the last 7 days" # source = "aliyun_oss" # operation = "search" # [tools.filter] # extensions = [".pdf", ".doc", ".docx", ".xls", ".xlsx"] # modified_after = "7d" # Relative time (not implemented yet) # Tool Configuration Reference: # ----------------------------- # # BUILT-IN TOOLS: # --------------- # list_buckets: List all storage buckets # list_objects: List objects in a bucket (supports: max_keys) # get_object: Get object content (supports: max_size) # get_object_metadata: Get object metadata without downloading # search_objects: Search objects with filters (supports: max_results) # # CUSTOM TOOL FIELDS (coming soon): # --------------------------------- # - name: Unique tool identifier # - description: Tool description for AI agents # - source: Source ID to operate on # - operation: Operation type (list, get, search, stat) # - filter: Filter configuration # - extensions: File extension filter [".jpg", ".png"] # - prefix: Key prefix filter # - min_size: Minimum file size in bytes # - max_size: Maximum file size in bytes # - parameters: Custom parameters for the tool # Usage Notes: # ------------ # 1. The first [[sources]] entry is the default storage source # 2. Access specific sources in MCP tools using the source_id in tool names # 3. For security, consider using environment variables for access keys # 4. Tools are named with source suffix when multiple sources exist # e.g., list_buckets_huawei_obs, list_objects_aliyun_oss

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/zq940222/OssHub'

If you have feedback or need assistance with the MCP directory API, please join our Discord server