Skip to main content
Glama
CanalWestStudio

AddressPenny MCP Server

validate_address

Validate a postal address to obtain its standardized form, deliverability status, and validation metadata.

Instructions

Validate a single postal address. Returns the standardized address, deliverability status, and validation metadata. Consumes 1 credit.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
addressYesFull or partial postal address as a single string, e.g. '1600 Amphitheatre Pkwy, Mountain View, CA'

Implementation Reference

  • src/index.ts:34-56 (registration)
    The tool 'validate_address' is registered with the MCP server at line 34, with its name, description, input schema (a single string 'address'), and handler callback.
    server.registerTool(
      "validate_address",
      {
        description:
          "Validate a single postal address. Returns the standardized address, deliverability status, and validation metadata. Consumes 1 credit.",
        inputSchema: {
          address: z
            .string()
            .min(1)
            .describe("Full or partial postal address as a single string, e.g. '1600 Amphitheatre Pkwy, Mountain View, CA'"),
        },
      },
      async ({ address }) => {
        try {
          const result = await client.validateAddress(address);
          return {
            content: [{ type: "text", text: JSON.stringify(shapeSingle(result), null, 2) }],
          };
        } catch (error) {
          return errorResult(error);
        }
      }
    );
  • The handler function for 'validate_address' that calls client.validateAddress(address), shapes the result via shapeSingle(), and returns the response.
    async ({ address }) => {
      try {
        const result = await client.validateAddress(address);
        return {
          content: [{ type: "text", text: JSON.stringify(shapeSingle(result), null, 2) }],
        };
      } catch (error) {
        return errorResult(error);
      }
    }
  • Input schema for validate_address: a single required string field 'address' with a description.
    inputSchema: {
      address: z
        .string()
        .min(1)
        .describe("Full or partial postal address as a single string, e.g. '1600 Amphitheatre Pkwy, Mountain View, CA'"),
    },
  • The client method validateAddress() that sends a POST request to the API endpoint with the original input address.
    async validateAddress(originalInput: string) {
      return this.post(`/accounts/${this.accountId}/addresses`, {
        address: { original_input: originalInput },
        sync: true,
      });
    }
  • The shapeSingle() helper that transforms the raw API response into the shaped output format used by validate_address.
    export function shapeSingle(envelope: unknown): ShapedAddress {
      const raw = ((envelope as { address?: RawAddress })?.address ?? {}) as RawAddress;
      return shape(raw);
    }
Behavior4/5

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

Despite no annotations, the description discloses that it returns standardized address, deliverability status, and validation metadata, and that it consumes 1 credit. These are useful behavioral details. However, it doesn't mention whether the tool is idempotent, whether it modifies data, or any error conditions beyond what's implied.

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 extremely concise, consisting of two short sentences. No unnecessary words, every sentence adds clear value.

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

Completeness4/5

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

Given the tool's simplicity (one parameter, no output schema), the description is fairly complete: it explains the input format, output types, and cost. However, it lacks any guidance on when to use siblings, which would improve completeness for agents choosing between tools.

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

Parameters4/5

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

The schema already covers the single parameter with a description. The tool's description adds no additional parameter-level semantics beyond what the schema provides, but the schema itself is very clear with an example format. Since schema coverage is 100%, baseline 3, and the description doesn't add much extra, a score of 4 is appropriate as it confirms the meaning without redundancy.

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

Purpose5/5

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

The description clearly states the verb 'Validate' and the resource 'postal address', and specifies returns (standardized address, deliverability status, validation metadata). The naming and description distinguish it from siblings 'bulk_validate' and 'parse_and_validate' by emphasizing single address validation.

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

Usage Guidelines3/5

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

The description implies this is for single address validation and mentions credit consumption, but provides no explicit guidance on when to choose this tool over siblings. For example, it doesn't state that 'bulk_validate' should be used for multiple addresses or when to use 'parse_and_validate' instead.

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/CanalWestStudio/addresspenny-mcp'

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