# Solgiery Random Bytes

> Solgiery Random Bytes is a paid API for AI agents from api.solgiery.com, paid per call via x402, $0.007/call, status unknown (last checked 2026-09-14).

Generate cryptographically secure random bytes of a specified length (1–4096), returned as a lowercase hexadecimal string, using the server OS CSPRNG.

## Facts

- Endpoint: GET https://api.solgiery.com/v1/random/bytes
- Price: $0.007/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/solgiery-random-bytes-30142763
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_vbxjyW2TCQnh2A5KnEqW6

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 solgiery-random-bytes-30142763
```

Example prompt: Give me 64 cryptographically secure random bytes as a hex string using Solgiery's CSPRNG — I need them for a nonce.

## When to prefer this

Choose this endpoint when you need raw cryptographically secure random bytes of a precise length (up to 4096 bytes) in hex format, especially when you want to inspect the consumed entropy for auditing or reproducibility. Prefer over UUID or integer endpoints when the output format must be raw hex bytes rather than a structured type. Use when building tokens, nonces, keys, or seeds that require CSPRNG-grade randomness.

## Known failure modes

- length parameter below 1 or above 4096 returns a validation error
- non-integer or malformed length value is rejected
- payment of 0.007 USDC not settled results in 402 Payment Required
- unknown or extra query parameters are rejected
- null parameter values are rejected

## How this service works

Generate length cryptographically random bytes, encoded as lowercase hexadecimal. length defaults to 32 and may be 1 to 4096. Uses the server OS CSPRNG. Returns consumed bytes for reproducible calculation, not proof of their origin. Price: 0.007 USDC per request, including the bounded batch.

## Output

Returns a JSON object containing: a hex-encoded string of the requested random bytes (field: result), an entropy object with the raw consumed bytes as hex (field: entropy.hex) and the source identifier 'os-csprng' (field: entropy.source), and the algorithm identifier 'solgiery-random-v1' (field: algorithm). The hex result string has length equal to 2× the requested byte count.

## 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",
     "required": [],
     "properties": {
      "length": {
       "type": "integer",
       "default": 32,
       "maximum": 4096,
       "minimum": 1
      }
     },
     "description": "Unknown or duplicate parameters and null parameter values are rejected. JSON body: at most 65536 bytes, depth 16, and 4096 bytes per item. Repeated sample items together must fit 65536 bytes.",
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "algorithm",
      "result",
      "entropy"
     ],
     "properties": {
      "result": {
       "type": "string",
       "pattern": "^[0-9a-f]+$",
       "maxLength": 8192,
       "minLength": 2
      },
      "entropy": {
       "type": "object",
       "required": [
        "source",
        "hex"
       ],
       "properties": {
        "hex": {
         "type": "string",
         "pattern": "^([0-9a-f]{2})*$",
         "maxLength": 262144
        },
        "source": {
         "type": "string",
         "const": "os-csprng"
        }
       },
       "additionalProperties": false
      },
      "algorithm": {
       "type": "string",
       "const": "solgiery-random-v1"
      }
     },
     "additionalProperties": false
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/solgiery-random-bytes-30142763/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.solgiery.com](https://www.zero.xyz/host/api.solgiery.com/llms.txt)
