Base64 encode or decode
base64Encode text (as UTF-8) to Base64, or decode Base64 back to text, and return the result. Decoding accepts standard and URL-safe alphabets and ignores whitespace; invalid Base64 returns an error. Bytes that are not valid UTF-8 are shown as replacement characters. Input up to 100 KB.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"text": "<text>",
"mode": "<mode>"
},
"name": "base64"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | Yes | encode: text to Base64; decode: Base64 to text | |
| text | Yes | Text to encode, or Base64 to decode | |
| urlSafe | No | When encoding, use - and _ and drop = padding (for URLs and JWTs) |