Skip to main content
Glama

get-soon-mainnet-last-transaction

Retrieve the most recent transaction for a SOON mainnet address to monitor account activity and verify blockchain interactions.

Instructions

Get the last transaction of an address on the Soon mainnet

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
addressYesThe SOON address to get the last transaction for

Implementation Reference

  • The handler function that implements the tool logic: fetches the most recent transaction signature for the given address on Soon mainnet (using Solana Web3.js Connection), retrieves the confirmed transaction details, and returns it as a JSON string in the MCP response format. Handles no-transaction and error cases.
    async ({ address }) => {
      try {
        const signatures = await connectionMainnet.getSignaturesForAddress(
          new PublicKey(address),
          { limit: 1 }
        );
    
        if (signatures.length === 0) {
          return {
            content: [
              {
                type: "text",
                text: "No transactions found for this address",
              },
            ],
          };
        }
    
        const latestSignature = signatures[0].signature;
        const transaction = await connectionMainnet.getConfirmedTransaction(
          latestSignature
        );
    
        return {
          content: [
            {
              type: "text",
              text: JSON.stringify(transaction),
            },
          ],
        };
      } catch (error) {
        return {
          content: [
            {
              type: "text",
              text: `Error getting transaction: ${
                error instanceof Error ? error.message : String(error)
              }`,
            },
          ],
        };
      }
    }
  • Zod schema defining the input parameter: 'address' as a string describing the SOON (Solana) public key.
    {
      address: z
        .string()
        .describe("The SOON address to get the last transaction for"),
    },
  • src/index.ts:153-205 (registration)
    The server.tool() call that registers the tool with MCP server, specifying name, description, input schema, and handler function.
    server.tool(
      "get-soon-mainnet-last-transaction",
      "Get the last transaction of an address on the Soon mainnet",
      {
        address: z
          .string()
          .describe("The SOON address to get the last transaction for"),
      },
      async ({ address }) => {
        try {
          const signatures = await connectionMainnet.getSignaturesForAddress(
            new PublicKey(address),
            { limit: 1 }
          );
    
          if (signatures.length === 0) {
            return {
              content: [
                {
                  type: "text",
                  text: "No transactions found for this address",
                },
              ],
            };
          }
    
          const latestSignature = signatures[0].signature;
          const transaction = await connectionMainnet.getConfirmedTransaction(
            latestSignature
          );
    
          return {
            content: [
              {
                type: "text",
                text: JSON.stringify(transaction),
              },
            ],
          };
        } catch (error) {
          return {
            content: [
              {
                type: "text",
                text: `Error getting transaction: ${
                  error instanceof Error ? error.message : String(error)
                }`,
              },
            ],
          };
        }
      }
    );
  • src/index.ts:9-20 (registration)
    MCP server initialization listing 'get-soon-mainnet-last-transaction' in capabilities.
    const server = new McpServer({
      name: "svm-mcp",
      version: "0.0.1",
      capabilities: [
        "get-soon-testnet-balance",
        "get-soon-testnet-last-transaction",
        "get-soon-testnet-account-tokens",
        "get-soon-mainnet-balance",
        "get-soon-mainnet-last-transaction",
        "get-soon-mainnet-account-tokens",
      ],
    });
  • Solana Web3.js Connection instance for Soon mainnet RPC endpoint, used by the handler.
    const connectionMainnet = new Connection("https://rpc.mainnet.soo.network/rpc");
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. It states the tool retrieves the last transaction, but doesn't disclose behavioral traits like error handling (e.g., invalid addresses), rate limits, authentication needs, or what 'last transaction' means (e.g., most recent by time). This leaves significant gaps for an agent to use 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, clear sentence that front-loads the key information without unnecessary words. It efficiently conveys the core purpose, making it easy to parse and understand quickly.

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 lack of annotations and output schema, the description is incomplete. It doesn't explain what the tool returns (e.g., transaction details, error formats) or address potential complexities like network-specific behaviors. For a tool with no structured support, more context is needed to ensure reliable use.

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 schema description coverage is 100%, with the parameter 'address' fully documented in the schema. The description adds no additional meaning beyond what the schema provides, such as format details or examples. With high schema coverage, the baseline score of 3 is appropriate as the description doesn't enhance parameter understanding.

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 ('Get') and resource ('last transaction of an address on the Soon mainnet'), making the purpose understandable. However, it doesn't explicitly differentiate from sibling tools like 'get-soon-testnet-last-transaction' beyond the 'mainnet' reference, which is implied but not contrasted.

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?

No guidance is provided on when to use this tool versus alternatives. It doesn't mention prerequisites, such as needing a valid address, or compare it to siblings like 'get-soon-mainnet-balance' or 'get-soon-testnet-last-transaction' for context-specific use cases.

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/rkmonarch/svm-mcp'

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