{
  "openapi": "3.1.0",
  "info": {
    "title": "ARDE Atomic Utility Batch",
    "version": "1.1.0",
    "description": "Deterministic pay-per-call developer utilities for AI agents over x402 on Base Mainnet. One $0.005 USDC payment executes 1-10 operations covering unit conversion, EVM hex normalization, HTTP normalization and policy checks, CORS preflight evaluation, retry classification, cookie security inspection, and CSV null normalization."
  },
  "servers": [
    {
      "url": "https://untitled-ef4f71e4.base44.app",
      "description": "ARDE seller origin used by agent indexes and routers"
    },
    {
      "url": "https://base44.app",
      "description": "Canonical Base44 function host returned by the live x402 challenge"
    }
  ],
  "paths": {
    "/api/apps/6a8fe38d53b9b6beef4f71e4/functions/ardeUtilityBatchMainnetWorker": {
      "post": {
        "operationId": "ardeAtomicUtilityBatch",
        "summary": "ARDE deterministic utility batch",
        "description": "Run 1-10 deterministic developer operations in one paid batch. Supported tasks: unit conversion; EVM JSON-RPC hex quantity normalization; EVM hex data normalization; HTTP version normalization; Allow header normalization; Vary header normalization; Origin normalization; CORS preflight policy checking; HTTP status retry classification; Set-Cookie security checks; and CSV null-token normalization. Pure deterministic transformations/checks with no LLM in the serving path.",
        "tags": ["utility", "developer-tools", "http", "evm", "data-normalization", "x402"],
        "security": [
          {
            "x402": []
          }
        ],
        "x-payment-info": {
          "protocols": ["x402"],
          "scheme": "exact",
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.005",
            "amountAtomic": "5000"
          },
          "network": "eip155:8453",
          "asset": "USDC",
          "assetAddress": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
          "payTo": "0xf5871C8b5f1B332d319A5EfB56b055A7410036E5"
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": ["items"],
                "additionalProperties": false,
                "properties": {
                  "items": {
                    "type": "array",
                    "minItems": 1,
                    "maxItems": 10,
                    "description": "Operations executed in order under one fixed $0.005 payment.",
                    "items": {
                      "type": "object",
                      "required": ["operation", "input"],
                      "additionalProperties": false,
                      "properties": {
                        "operation": {
                          "type": "string",
                          "enum": [
                            "unit_convert",
                            "evm_hex_quantity_normalize",
                            "evm_hex_data_normalize",
                            "http_version_normalize",
                            "allow_header_normalize",
                            "vary_header_normalize",
                            "origin_header_normalize",
                            "cors_preflight_check",
                            "status_retry_classify",
                            "cookie_security_check",
                            "csv_null_normalize"
                          ]
                        },
                        "input": {
                          "type": "object",
                          "description": "Operation-specific input object.",
                          "additionalProperties": true
                        }
                      }
                    }
                  }
                }
              },
              "examples": {
                "mixedDeveloperBatch": {
                  "summary": "Convert a unit and normalize an HTTP version",
                  "value": {
                    "items": [
                      {
                        "operation": "unit_convert",
                        "input": {"value": 10, "from": "mi", "to": "km"}
                      },
                      {
                        "operation": "http_version_normalize",
                        "input": {"value": "h2"}
                      }
                    ]
                  }
                },
                "corsCheck": {
                  "summary": "Evaluate a CORS preflight policy",
                  "value": {
                    "items": [
                      {
                        "operation": "cors_preflight_check",
                        "input": {
                          "origin": "https://agent.example",
                          "requested_method": "POST",
                          "requested_headers": ["content-type"],
                          "allow_origin": "https://agent.example",
                          "allow_methods": ["POST"],
                          "allow_headers": ["content-type"]
                        }
                      }
                    ]
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Paid deterministic utility results for the requested items.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true
                }
              }
            }
          },
          "400": {
            "description": "Invalid operation or bounded input. No automatic retry is implied."
          },
          "402": {
            "description": "x402 Payment Required. Read PAYMENT-REQUIRED for the authoritative Base Mainnet USDC terms."
          },
          "503": {
            "description": "Paid production acceptance is currently closed or fail-closed."
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "x402": {
        "type": "apiKey",
        "in": "header",
        "name": "PAYMENT-SIGNATURE",
        "description": "x402 v2 payment signature. First send the request unsigned and read the live HTTP 402 challenge."
      }
    }
  }
}