EIP-712 hash
Validate EIP-712 typed structured data and derive its domain separator, message hash, and signing digest.
Endpoint
https://apiacre.com/v1/crypto/typed-data-hashSend the JSON body below. An unpaid request returns HTTP 402 with a PAYMENT-REQUIRED header; an x402-compatible buyer signs the requirement and retries with PAYMENT-SIGNATURE.
Pay $0.01 USDC and run in your browserOfficial Coinbase agent path
Coinbase Agentic Wallet can satisfy this x402 request in one command. Running it may pay automatically, so --max-amount is fixed to $0.01 USDC in atomic units. Copying the command does not install, authenticate, sign, or pay; review the request and use a separate low-value wallet before running it.
npx --yes awal@latest x402 pay https://apiacre.com/v1/crypto/typed-data-hash \
-X POST \
-d '{"typed_data":{"types":{"EIP712Domain":[{"name":"name","type":"string"}],"Message":[{"name":"contents","type":"string"}]},"primaryType":"Message","domain":{"name":"API Acre Example"},"message":{"contents":"Hello"}}}' \
--max-amount 10000 \
--jsonCoinbase pay-for-service documentation · Buyer setup and wallet safety
Alternative third-party AgentCash commands
Run check first without payment. Its fetch command may automatically pay up to the exact listed price.
npx --yes agentcash@latest check https://apiacre.com/v1/crypto/typed-data-hash
npx --yes agentcash@latest fetch https://apiacre.com/v1/crypto/typed-data-hash \
--method POST \
--header 'content-type: application/json' \
--body '{"typed_data":{"types":{"EIP712Domain":[{"name":"name","type":"string"}],"Message":[{"name":"contents","type":"string"}]},"primaryType":"Message","domain":{"name":"API Acre Example"},"message":{"contents":"Hello"}}}' \
--payment-protocol x402 \
--payment-network base \
--max-amount 0.010Input example
{
"typed_data": {
"types": {
"EIP712Domain": [
{
"name": "name",
"type": "string"
}
],
"Message": [
{
"name": "contents",
"type": "string"
}
]
},
"primaryType": "Message",
"domain": {
"name": "API Acre Example"
},
"message": {
"contents": "Hello"
}
}
}Response shape
{
"request_id": "018f1f54-7f38-7ba2-8dc3-5f90272d9f1a",
"service": "crypto.typed-data-hash",
"version": "1",
"data": {
"valid": true,
"domainSeparator": "0xc167959bdf834486717879a8cd6eb3e12a864d1b1d7dbcecec40455e1b4bc8c8",
"messageHash": "0xd6a9eadbfb49313d8b83d02d2bb22b916a5b16e6006946c9ca6fa7959d934b3a",
"signingHash": "0x7433e410d5f2857cb42d0bfd31bc71e8aa553f02ce0eed397927f01dfb46424c",
"primaryType": "Message"
},
"meta": {
"duration_ms": 42,
"cached": false,
"sources": [],
"warnings": [],
"next_actions": []
}
}Try the payment challenge
curl -i -X POST 'https://apiacre.com/v1/crypto/typed-data-hash' \
-H 'content-type: application/json' \
--data '{"typed_data":{"types":{"EIP712Domain":[{"name":"name","type":"string"}],"Message":[{"name":"contents","type":"string"}]},"primaryType":"Message","domain":{"name":"API Acre Example"},"message":{"contents":"Hello"}}}'