Skip to main content
Glama

Hash Encoding Direct Credits

Base64 encode

base64_encode
Destructive

Encode UTF-8 text as standard Base64. Use this for transport/storage encoding of text bytes; Base64 is reversible encoding, not encryption and not a cryptographic hash. Returns the encoded Base64 string. Costs 1 credit.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inputYesPlain text interpreted as UTF-8, maximum 65,536 characters.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / input / description
      Added value: +"Plain text interpreted as UTF-8, maximum 65,536 characters."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "https://json-schema.org/draft/2020-12/schema",
      +  "anyOf": [
      +    {
      +      "additionalProperties": false,
      +      "properties": {
      +        "base64": {
      +          "description": "Standard Base64 representation of the UTF-8 input bytes.",
      +          "type": "string"
      +        },
      +        "creditsRemaining": {
      +          "description": "Credits remaining after this successful 1-credit call.",
      +          "maximum": 9007199254740991,
      +          "minimum": 0,
      +          "type": "integer"
      +        }
      +      },
      +      "required": [
      +        "base64",
      +        "creditsRemaining"
      +      ],
      +      "type": "object"
      +    },
      +    {
      +      "additionalProperties": false,
      +      "properties": {
      +        "creditsRemaining": {
      +          "anyOf": [
      +            {
      +              "maximum": 9007199254740991,
      +              "minimum": 0,
      +              "type": "integer"
      +            },
      +            {
      +              "type": "null"
      +            }
      +          ],
      +          "description": "Known remaining credits, or null when no balance can be reported."
      +        },
      +        "error": {
      +          "description": "Human-readable reason the protected tool call failed.",
      +          "type": "string"
      +        },
      +        "status": {
      +          "description": "HTTP-style status code for the failure.",
      +          "maximum": 9007199254740991,
      +          "minimum": -9007199254740991,
      +          "type": "integer"
      +        }
      +      },
      +      "required": [
      +        "error",
      +        "status",
      +        "creditsRemaining"
      +      ],
      +      "type": "object"
      +    }
      +  ],
      +  "type": "object"
      +}
  2. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Beyond the annotations, the description adds two useful behavioral facts: the output is the encoded Base64 string and the call costs 1 credit, plus it clarifies the reversible, non-cryptographic nature of the operation. It does not reconcile the surprising destructiveHint=true annotation with what is described as a pure, reversible transformation, which leaves a mild ambiguity.

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?

Three short sentences, all front-loaded around the core action, with zero filler; the 'not encryption, not a hash' clause is the one bit of extra length and it earns its place by preventing tool misuse.

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

Completeness5/5

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

With an output schema present, return values need not be described, and the input is fully specified in the schema. The description covers purpose, intended use, the non-cryptographic caveat, and the credit cost, which is everything an agent needs to call it correctly.

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 coverage is 100% and the single parameter is fully documented (UTF-8, max 65,536 characters) in the schema itself. The description reinforces the UTF-8 interpretation and notes the standard Base64 alphabet but adds no syntax or format detail beyond the schema, so the baseline 3 applies.

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 gives a specific verb and resource ('Encode UTF-8 text as standard Base64') and immediately contrasts itself against the hash/encryption siblings, so an agent can distinguish it from hash_sha256 or base64_decode without opening any schema.

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

Usage Guidelines4/5

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

'Use this for transport/storage encoding of text bytes' states the intended context, and the clarification that Base64 is not encryption or a cryptographic hash implicitly routes the agent away from the hash_* siblings. It stops short of naming an explicit alternative tool or an exclusion case, so it is clear context rather than full when/when-not guidance.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources