# x402 Vending Machine – Buy $4 USDC Tokens

> x402 Vending Machine – Buy $4 USDC Tokens is a paid API for AI agents from vending-machine.heurist.xyz, paid per call via x402, $4/call, status unknown (last checked 2026-10-11).

Purchase $4.00 USDC worth of tokens from a Heurist vending machine token launch using x402 payment protocol.

## Facts

- Endpoint: POST https://vending-machine.heurist.xyz/x402/buy4x?utm_source=zero.xyz
- Price: $4/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-11
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/x402-vending-machine-buy-4-usdc-tokens-85dfecf1
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_siVgcKnE63YIMbND2g0OV

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 x402-vending-machine-buy-4-usdc-tokens-85dfecf1 -d '<json body>'
```

Example prompt: Buy $4 worth of tokens from the Heurist vending machine for token address 0xAbC123... and send them to my wallet 0xDef456...

## When to prefer this

Choose this endpoint when you want to purchase exactly $4.00 USDC worth of tokens in a single transaction. Use the $3 endpoint for a smaller purchase or the $5 endpoint for a slightly larger one. This is ideal for agents automating fixed-denomination token buys in open Heurist vending machine launches.

## Known failure modes

- Token launch is not open for buying — returns an error indicating the sale is closed
- Allocation cap has already been reached — returns an error that no more tokens are available
- Invalid or non-existent token address — returns a validation error
- Insufficient x402 payment — payment of $4 USDC not confirmed, transaction rejected
- Invalid recipient address format — returns a schema validation error

## How this service works

Buy $4.00 USDC worth of tokens from the vending machine. The token launch must be open to buy, and the allocation cap must not have been reached.

## Output

Returns a transaction confirmation including the purchase status, the amount of tokens received for the $4.00 USDC spent, and the recipient address that received the tokens.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "token"
 ],
 "properties": {
  "token": {
   "type": "string",
   "description": "Token address"
  },
  "recipient": {
   "type": "string",
   "description": "Optional recipient address; default is the API caller"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/x402-vending-machine-buy-4-usdc-tokens-85dfecf1/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from vending-machine.heurist.xyz](https://www.zero.xyz/host/vending-machine.heurist.xyz/llms.txt)
