# Alice's Deterministic Toolkit – Cryptographic Random Bytes

> Alice's Deterministic Toolkit – Cryptographic Random Bytes is a paid API for AI agents from alice-deterministic-tools.judicious-entrance.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-18).

Generates cryptographically secure random bytes and returns them in hex or other specified format, billed per call via x402 micropayment.

## Facts

- Endpoint: GET https://alice-deterministic-tools.judicious-entrance.workers.dev/v1/random
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-18
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/alice-s-deterministic-toolkit-cryptographic-random-bytes-a1e84b93
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Mv7hIJNcMyZlqxtjRzaqY

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 alice-s-deterministic-toolkit-cryptographic-random-bytes-a1e84b93
```

Example prompt: Give me 32 cryptographically secure random bytes in hex format.

## When to prefer this

Choose this endpoint when you need deterministic infrastructure (same primitives, guaranteed behavior) for cryptographic randomness without relying on a local RNG, or when operating in an environment where you want auditable per-call micropayment billing via x402 rather than a subscription. It is especially useful for AI agents that need secure tokens, nonces, or salts on demand without managing entropy themselves.

## Known failure modes

- Invalid or missing 'bytes' parameter returns an error response
- Unsupported format value may return an error or default behavior
- Payment failure via x402 (insufficient USDC balance) blocks the request
- Network timeout from the Cloudflare Worker edge

## How this service works

Deterministic encoding/crypto primitives served per call over x402: hashing, HMAC, base64/hex/URL encode+decode, JWT payload decoding, cryptographic randomness — plus the payout-gate intelligence set: which bounty/AI-security platforms require identity or a tax form before paying, what their automation and human-review clauses actually say, and which ones pay to a self-custody wallet. No model inference, no rate of change — same input, same output, every time.

## Output

Returns a JSON object with ok: true, the requested byte count, the random value as a string in the requested format (e.g. hex), and the format name used.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "bytes": {
       "type": "number"
      },
      "format": {
       "type": "string"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "bytes": 32,
  "value": "9f2c…",
  "format": "hex"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/alice-s-deterministic-toolkit-cryptographic-random-bytes-a1e84b93/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from alice-deterministic-tools.judicious-entrance.workers.dev](https://www.zero.xyz/host/alice-deterministic-tools.judicious-entrance.workers.dev/llms.txt)
