Skip to main content
Glama

tos_list_buckets

List all available storage buckets in Volcengine TOS object storage service for bucket management and organization.

Instructions

列举 TOS 存储桶

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that implements the tos_list_buckets tool. It calls tos_client.list_buckets() to retrieve all buckets and formats them as a JSON list with name, creation_date, and location.
    async def list_buckets(_args: Dict[str, Any]) -> List[TextContent]: """列举存储桶""" try: resp = tos_client.list_buckets() buckets = [] for bucket in resp.buckets: buckets.append({ "name": bucket.name, "creation_date": str(bucket.creation_date) if bucket.creation_date else None, "location": bucket.location }) return [TextContent(type="text", text=json.dumps(buckets, indent=2, ensure_ascii=False))] except Exception as e: return [TextContent(type="text", text=f"列举存储桶失败: {str(e)}")]
  • Tool registration in list_tools() function, defining the name, description, and input schema (empty properties) for tos_list_buckets.
    Tool( name="tos_list_buckets", description="列举 TOS 存储桶", inputSchema={ "type": "object", "properties": {} } ),
  • Dispatch logic in call_tool() that routes the tos_list_buckets tool call to the list_buckets handler function.
    elif name == "tos_list_buckets": return await list_buckets(arguments)
  • Input schema for the tos_list_buckets tool, which requires no parameters (empty properties).
    inputSchema={ "type": "object", "properties": {} }

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/jneless/tos-mcp'

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