← All tool references

Communication · execute

UTF-8 Converter

Encode Unicode text as UTF-8 hexadecimal bytes or validate and decode a hexadecimal byte sequence back into text.

Open public tool

Overview

Category
Communication
API mode
execute
Processing
client-side
Privacy
no-data-stored

Public descriptor

The descriptor is available without an API key and supplies this tool’s metadata, schemas, modes, and examples.

GET /api/v1/tools/utf-8-converter

View this descriptor as JSON

Execute availability

This tool has an execute route defined by its descriptor. Server-side execution is currently unavailable, so requests return api_not_launched.

POST /api/v1/tools/utf-8-converter/execute

Authentication is not issued during the preview. A bearer API key is planned for execution after launch.

Input schema

object object; additional properties are not accepted.

mode · string · required
Conversion direction. Accepted values: text_to_bytes, bytes_to_text.
value · string · required
Unicode text or hexadecimal byte tokens.
{
    "type": "object",
    "properties": {
        "mode": {
            "type": "string",
            "enum": [
                "text_to_bytes",
                "bytes_to_text"
            ],
            "description": "Conversion direction."
        },
        "value": {
            "type": "string",
            "description": "Unicode text or hexadecimal byte tokens."
        }
    },
    "required": [
        "mode",
        "value"
    ],
    "additionalProperties": false
}

Output schema

On a successful execution, schema values appear in data.result.values.

result · string
Converted content.
format · string
Output format.
byte_length · number
UTF-8 octets.
character_count · number
Unicode code points.
valid · boolean
Validation status.
mode · string
Conversion direction.
{
    "type": "object",
    "properties": {
        "result": {
            "type": "string",
            "description": "Converted content."
        },
        "format": {
            "type": "string",
            "description": "Output format."
        },
        "byte_length": {
            "type": "number",
            "description": "UTF-8 octets."
        },
        "character_count": {
            "type": "number",
            "description": "Unicode code points."
        },
        "valid": {
            "type": "boolean",
            "description": "Validation status."
        },
        "mode": {
            "type": "string",
            "description": "Conversion direction."
        }
    },
    "additionalProperties": false
}

Encode café

The request body follows the published input schema. The response below shows the success-envelope shape returned after execution is available.

curl -X POST "https://utilitypages.org/api/v1/tools/utf-8-converter/execute" \
  -H "Content-Type: application/json" \
  -d '{
    "mode": "text_to_bytes",
    "value": "café"
}'
{
    "ok": true,
    "data": {
        "slug": "utf-8-converter",
        "result": {
            "values": {
                "result": "63 61 66 C3 A9",
                "format": "UTF-8 hexadecimal bytes",
                "byte_length": 5,
                "character_count": 4,
                "valid": true,
                "mode": "text_to_bytes"
            },
            "display": {
                "display": "63 61 66 C3 A9"
            },
            "warnings": [],
            "assumptions": [],
            "steps": []
        }
    },
    "meta": [],
    "request_id": "req_example_123"
}

Errors

api_not_launched · 503
Returned by the current launch gate for every execute request.
invalid_json · 400
Returned when an enabled execute request does not contain valid JSON.
validation_failed · 422
Returned when a request does not satisfy the input schema.
browser_interaction_required · 422
Returned for browser capability tools instead of inventing a server-side result.
tool_not_found · 404
Returned when a requested descriptor slug does not exist.
execution_failed · 503
Returned when an enabled server-side execution cannot complete.