Skip to main content
Glama

s3_object_list

List all objects stored in an Amazon S3 bucket to manage and review file contents.

Instructions

List objects in an S3 bucket

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bucket_nameYesName of the S3 bucket

Implementation Reference

  • Core execution logic for the s3_object_list tool: calls boto3 S3 client's list_objects_v2 method with the bucket_name argument.
    elif name == "s3_object_list":
        response = s3_client.list_objects_v2(
            Bucket=arguments["bucket_name"])
  • Tool definition including input schema that requires a 'bucket_name' string parameter.
    Tool(
        name="s3_object_list",
        description="List objects in an S3 bucket",
        inputSchema={
            "type": "object",
            "properties": {
                "bucket_name": {
                    "type": "string",
                    "description": "Name of the S3 bucket"
                }
            },
            "required": ["bucket_name"]
        }
    ),
  • Registers the s3_object_list tool (among others) by returning the list of AWS tools via MCP's list_tools handler.
    @server.list_tools()
    async def list_tools() -> list[Tool]:
        """List available AWS tools"""
        logger.debug("Handling list_tools request")
        return get_aws_tools()
  • Shared post-execution logic: logs the operation to audit and returns the S3 API response as formatted JSON text content.
    aws.log_operation("s3", name.replace("s3_", ""), arguments)
    return [TextContent(type="text", text=f"Operation Result:\n{json.dumps(response, indent=2, default=custom_json_serializer)}")]
  • Combines S3 and DynamoDB tools (including s3_object_list from get_s3_tools) into the full tools list returned by list_tools.
    def get_aws_tools() -> list[Tool]:
        return [
            *get_s3_tools(),
            *get_dynamodb_tools()
        ]
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the action ('List objects') but lacks critical details: it does not mention pagination, rate limits, permissions required (e.g., S3:ListBucket), return format (e.g., object keys, sizes), or error conditions (e.g., bucket not found). This leaves significant gaps for an agent to invoke it correctly.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, direct sentence ('List objects in an S3 bucket') with zero wasted words. It is front-loaded and efficiently conveys the core purpose without unnecessary elaboration, making it highly concise and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (listing objects in cloud storage), lack of annotations, and no output schema, the description is incomplete. It omits behavioral traits (e.g., pagination, permissions), usage context, and return value details, which are essential for an agent to operate effectively in a real-world S3 environment.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, with 'bucket_name' clearly documented. The description adds no additional parameter semantics beyond what the schema provides (e.g., bucket naming rules, region implications). Since schema coverage is high, the baseline score of 3 is appropriate, as the description does not compensate but also does not detract.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'List objects in an S3 bucket' clearly states the verb ('List') and resource ('objects in an S3 bucket'), making the purpose immediately understandable. However, it does not differentiate from sibling tools like 's3_bucket_list' (which lists buckets, not objects) or specify scope (e.g., all objects vs. filtered), preventing a perfect score.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It does not mention sibling tools like 's3_object_read' (for reading specific objects) or 's3_object_delete' (for deletion), nor does it specify prerequisites (e.g., bucket existence) or use cases (e.g., inventory checks).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/rishikavikondala/mcp-server-aws'

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