Skip to main content
Glama

get_blob

Retrieve stored data from Walrus decentralized storage by providing the blob ID, enabling access to blockchain-verified content on the Sui network.

Instructions

Retrieve a blob from Walrus storage

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
blobIdYesThe blob ID to retrieve

Implementation Reference

  • MCP tool handler for 'get_blob': parses arguments with GetBlobSchema and calls walrusClient.getBlob, returning the result as text content
    case 'get_blob': {
      const { blobId } = GetBlobSchema.parse(args);
      const result = await walrusClient.getBlob(blobId);
      return {
        content: [
          {
            type: 'text',
            text: result,
          },
        ],
      };
    }
  • Zod input schema validation for the get_blob tool (requires blobId string)
    const GetBlobSchema = z.object({
      blobId: z.string().describe('The blob ID to retrieve'),
    });
  • src/index.ts:74-87 (registration)
    Tool registration descriptor for 'get_blob' in the ListTools response, defining name, description, and input schema
    {
      name: 'get_blob',
      description: 'Retrieve a blob from Walrus storage',
      inputSchema: {
        type: 'object',
        properties: {
          blobId: {
            type: 'string',
            description: 'The blob ID to retrieve',
          },
        },
        required: ['blobId'],
      },
    },
  • Core implementation of blob retrieval in WalrusClient: HTTP GET to aggregator, returns base64-encoded blob data with error handling
    async getBlob(blobId: string): Promise<string> {
      try {
        const response = await this.httpClient.get(
          `${this.config.aggregatorUrl}/v1/${blobId}`,
          {
            responseType: 'arraybuffer',
          }
        );
    
        // Return as base64 encoded string
        return Buffer.from(response.data).toString('base64');
      } catch (error) {
        if (axios.isAxiosError(error)) {
          if (error.response?.status === 404) {
            throw new Error(`Blob not found: ${blobId}`);
          }
          throw new Error(`Failed to retrieve blob: ${error.response?.data?.error || error.message}`);
        }
        throw new Error(`Failed to retrieve blob: ${error instanceof Error ? error.message : String(error)}`);
      }
    }
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states this is a retrieval operation but doesn't mention whether it requires authentication, has rate limits, returns binary data, or handles errors. For a storage tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

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, efficient sentence that directly states the tool's purpose without unnecessary words. It's appropriately sized for a simple retrieval tool and front-loads the essential information.

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 no annotations and no output schema, the description is incomplete for a storage retrieval tool. It doesn't explain what 'blob' means in this context, what format the retrieved data is in, error handling, or authentication requirements. The agent lacks sufficient context to use this tool effectively.

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?

Schema description coverage is 100%, so the schema already documents the single parameter 'blobId' adequately. The description doesn't add any additional meaning about parameter usage, format, or constraints beyond what the schema provides, meeting the baseline for high schema coverage.

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 clearly states the action ('Retrieve') and resource ('a blob from Walrus storage'), making the purpose immediately understandable. However, it doesn't differentiate from sibling tools like 'get_blob_info' which also retrieves blob information, so it doesn't reach the highest 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 like 'get_blob_info' (for metadata) or 'list_blobs' (for listing). There's no mention of prerequisites, error conditions, or typical use cases, leaving the agent with insufficient context for optimal selection.

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/Motion-Labs-Sui/walrus-mcp'

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