{"uid":"cap_T8CtjPbWjFMG2E_Zd__sp","slug":"agentresolver-abi-encode-x402-payment-preflight-payto-verification-9161fb1d","name":"AgentResolver ABI Encode — x402 Payment Preflight & PayTo Verification","description":"Verify an x402 endpoint before paying: live payTo, USDC quote, network, asset, resource binding, TLS and endpoint safety for $0.001 on Base or Solana.","url":"https://agentresolver.vercel.app/api/abi-encode","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"types":{"type":"array","items":{"type":"string","maxLength":512,"minLength":1},"maxItems":32,"minItems":1},"values":{"type":"array","maxItems":32}}},"responseSchema":{"type":"json","example":{}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_ad303HalXe07dw0hw_q4K","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"ABI-encodes typed Solidity/EVM values for use in x402 payment preflight and payTo verification flows","exampleAgentPrompt":"ABI-encode the Solidity types ['address','uint256'] with values ['0xAbC123...','1000000'] so I can use the result in an x402 payTo verification call on Base.","exampleUseCases":[{"title":"Encode USDC payment parameters for x402","prompt":"I need to ABI-encode the types ['address','uint256'] with values ['0x4F96Fe3b7A6Cf9725f59d353F723c1bDb64CA6Aa','5000000'] to prepare a USDC payment payload for an x402 endpoint on Base."},{"title":"Prepare calldata for smart contract resource binding","prompt":"Can you ABI-encode ['bytes32','address','uint256'] with values ['0xdeadbeef...','0x1234abcd...','1'] so I can verify resource binding before paying for a gated API?"},{"title":"Validate encoded payload before x402 preflight","prompt":"Encode these Solidity types ['string','address'] with values ['hello','0xABCDEF1234567890abcdef1234567890ABCDEF12'] and give me the hex output so I can run a preflight safety check on the x402 endpoint."}],"resultDescription":"Returns ABI-encoded hex data corresponding to the provided Solidity types and values array, suitable for use in EVM smart contract calls, x402 payment headers, or payTo verification payloads.","failureModes":["Type/value array length mismatch returns a validation error","Unsupported or malformed Solidity type strings cause encoding failure","Values incompatible with their declared types (e.g. non-hex for address) return a 400 error","Empty types or values arrays rejected (minItems: 1 enforced)","Arrays exceeding 32 items return a limit error"],"whenToPreferThis":"Choose this endpoint when you need to ABI-encode EVM/Solidity typed values as part of an x402 payment preflight, payTo address verification, or on-chain resource binding check — especially when working on Base or Solana networks with USDC. It is purpose-built for the x402 payment protocol context rather than being a general-purpose ABI encoder.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-19T06:41:28.066Z","isFirstParty":false}