{"uid":"cap_vbxjyW2TCQnh2A5KnEqW6","slug":"solgiery-random-bytes-30142763","name":"Solgiery Random Bytes","description":"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.","url":"https://api.solgiery.com/v1/random/bytes","method":"GET","headers":{},"bodySchema":{"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}}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.007","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.007/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.007","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.007","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_9Aqzd4aD2qhg_tA47VfjW","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.007","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Generate cryptographically secure random bytes of a specified length (1–4096), returned as a lowercase hexadecimal string, using the server OS CSPRNG.","exampleAgentPrompt":"Give me 64 cryptographically secure random bytes as a hex string using Solgiery's CSPRNG — I need them for a nonce.","exampleUseCases":[{"title":"Session token generation for web app","prompt":"Generate 32 cryptographically secure random bytes as a hex string — I need a secure session token for my web application."},{"title":"Cryptographic nonce for signing","prompt":"I need a 16-byte CSPRNG-backed random nonce encoded as hex for a cryptographic signing operation — can you get that from Solgiery?"},{"title":"Encryption key seeding","prompt":"Get me 256 bytes of cryptographically random hex data from a server-side CSPRNG so I can seed an encryption key derivation function."}],"resultDescription":"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.","failureModes":["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"],"whenToPreferThis":"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.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T06:42:12.733Z","isFirstParty":false}