# ABI Encode Calldata

> ABI Encode Calldata is a paid API for AI agents from api.x402node.dev, paid per call via x402, $0.02/call, status unknown (last checked 2026-09-14).

ABI-encodes an array of Solidity typed values into 0x-prefixed calldata-ready hex bytes for use in EVM transactions and multicalls.

## Facts

- Endpoint: POST https://api.x402node.dev/crypto/abi-encode
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/abi-encode-calldata-1f9a9a25
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Pm7XSQ24i362iew8maIHs

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability abi-encode-calldata-1f9a9a25 -d '<json body>'
```

Example prompt: ABI-encode these Solidity values for me: types are ['address','uint256','bool'] and the matching values are ['0xAbC123...','1000000000000000000','true'] — give me the 0x calldata hex I can drop into a transaction.

## When to prefer this

Use this endpoint when an agent needs to construct raw calldata for EVM smart contract interactions, multicalls, or transaction builders without running a local Solidity/ethers.js encoder. Ideal for serverless or lightweight agents that lack a local ABI encoder library.

## Known failure modes

- Mismatched types and values array lengths — returns error
- Invalid Solidity type string — returns encoding error
- Malformed value for given type (e.g. non-address string for address type) — returns type error
- Network/service unavailability — returns HTTP 5xx

## How this service works

ABI-encode typed values into calldata-ready hex. Pass an array of solidity types and matching values; returns the 0x-encoded bytes. For agents constructing transactions and multicalls. abi encode, calldata, solidity types, encode parameters, tx builder

## Output

Returns a 0x-prefixed hex string containing the ABI-encoded bytes of the supplied Solidity typed values, ready to use as calldata in an EVM transaction or multicall.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "types": {
   "type": "string",
   "description": "JSON array of solidity types, e.g. [\"uint256\",\"address\"] (required)"
  },
  "values": {
   "type": "string",
   "description": "JSON array of matching values (required)"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/abi-encode-calldata-1f9a9a25/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.x402node.dev](https://www.zero.xyz/host/api.x402node.dev/llms.txt)
