ToolAssay

Encodes a PaymentRequired, PaymentPayload or settlement response object as the b

Encodes a PaymentRequired, PaymentPayload or settlement response object as the base64 value of its x402 header, for hand-written servers, clients and tests, and reports the same problems /v1/decode finds.

Answeringour last check, 2026-10-25
1 of 1checks answered this week
488 msmedian answer time
$0.002listed price per call
$0.002price it asked us

Paid test badge: not yet. The checks above are free: we call the tool without paying and read the payment request it sends back. The Verified badge needs paid calls whose answers match the promised output, and nobody can buy a badge.

Endpoint

POST https://dev.kagurazaka.dev/v1/encode

CategoryEverything else
Provider hostdev.kagurazaka.dev
Networkseip155:8453
Payment schemesexact
Self-reported calls, 30 days1 from 1 payers (the provider's figure, not ours)

Our checks, last 30 days

DayResultHTTPAskedTime
2026-10-25 valid payment request 402$0.002 488 ms

Example input (from the provider)

{
  "body": {
    "value": {
      "network": "eip155:8453",
      "payer": "0x5672C104c5A7F931843DD0b4Cc12BA0B525C7BCB",
      "success": true,
      "transaction": "0x5e1d3a1f7c8b9a0e2d4c6b8a0f1e3d5c7b9a1f3e5d7c9b1a3f5e7d9c1b3a5f7e",
      "x402Version": 2
    }
  },
  "bodyType": "json",
  "method": "POST",
  "type": "http"
}

Promised output schema (from the provider)

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "input": {
      "additionalProperties": false,
      "properties": {
        "body": {
          "properties": {
            "kind": {
              "description": "default auto",
              "enum": [
                "payment-required",
                "payment-signature",
                "payment-response",
                "auto"
              ],
              "type": "string"
            },
            "value": {
              "description": "the header's JSON object",
              "type": "object"
            }
          },
          "required": [
            "value"
          ]
        },
        "bodyType": {
          "enum": [
            "json",
            "form-data",
            "text"
          ],
          "type": "string"
        },
        "method": {
          "enum": [
            "POST"
          ],
          "type": "string"
        },
        "type": {
          "const": "http",
          "type": "string"
        }
      },
      "required": [
        "type",
        "method",
        "bodyType",
        "body"
      ],
      "type": "object"
    },
    "output": {
      "properties": {
        "example": {
          "properties": {
            "findings": {},
            "header": {},
            "header_name": {},
            "kind": {}
          },
          "type": "object"
        },
        "type": {
          "type": "string"
        }
      },
      "required": [
        "type"
      ],
      "type": "object"
    }
  },
  "required": [
    "input"
  ],
  "type": "object"
}

This page as JSON