{"uid":"cap_RBa0dmplcmIpnEhDpf-Ug","slug":"2s-hash-compute-23d280d5","name":"2s Hash Compute","description":"The (most) everything API: 575+ pay-per-call endpoints for AI agents — ground-truth data, a full AI gateway, and agent infrastructure (storage, queues, watchers). USDC via x402, no signup, no API keys, and upto billing: pay actual usage, not the quote.","url":"https://2s.io/api/hash/compute","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"input":{"type":"string","maxLength":524288},"algorithm":{"enum":["md5","sha1","sha224","sha256","sha384","sha512","sha3-224","sha3-256","sha3-384","sha3-512","blake2b512","blake2s256"],"type":"string"},"algorithms":{"type":"array","items":{"enum":["md5","sha1","sha224","sha256","sha384","sha512","sha3-224","sha3-256","sha3-384","sha3-512","blake2b512","blake2s256"],"type":"string"}},"inputEncoding":{"enum":["utf8","hex","base64"],"type":"string","default":"utf8"},"outputEncoding":{"enum":["hex","base64"],"type":"string","default":"hex"}}},"responseSchema":null,"example":{"request":{"input":"Hello world","algorithm":"sha256","inputEncoding":"utf8","outputEncoding":"hex"},"response":{"data":{"ok":true,"items":[{"input":{"bytes":11,"encoding":"utf8"},"digests":{"sha256":"64ec88ca00b268e5ba1a35678a1b5316d212f4f366b2477232534a8aeca37f3c"},"outputEncoding":"hex"}],"total":1,"source":{"url":"https://2s.io","license":"No upstream license — computed by 2s.io","provider":"2s.io digest engine (node:crypto)"}},"meta":{"cost":{"usd":0.001,"tier":0},"caller":"x402","version":null,"endpoint":"hash.compute","settlement":{"txHash":"0x62ac16f7aada6c00f887240173be6c1fe76bb59a73fcf9201812cfba0d865edc","network":"eip155:8453","success":true}}}},"exampleRequest":{"input":"Hello world","algorithm":"sha256","inputEncoding":"utf8","outputEncoding":"hex"},"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","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.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0025","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0025","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_vWJVyd85rDphqupTuBT36","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0025","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Computes cryptographic hash digests of an input string using one or more configurable hashing algorithms","exampleAgentPrompt":"Can you compute the SHA-256 and SHA-512 hashes of the string 'hello world' and give me the results in hex encoding?","exampleUseCases":null,"resultDescription":"A JSON object containing an array of items, each with the input metadata (encoding and byte count), a map of algorithm names to their computed digest strings, and output encoding used. Also includes a total count and source attribution with provider, URL, and license.","failureModes":["Invalid algorithm name not in the supported enum returns an error","Input exceeding 524288 characters may be rejected","Unsupported inputEncoding or outputEncoding values return validation errors","Malformed base64 or hex input strings may cause decoding errors","Payment failure via x402 prevents the call from being processed"],"whenToPreferThis":"Use this endpoint when an AI agent needs to compute cryptographic hashes on-demand without managing server infrastructure, libraries, or API keys — especially useful for data integrity checks, fingerprinting, or multi-algorithm comparison in a single call. Prefer over self-hosted solutions when operating in a stateless, pay-per-use agent environment on Base or Solana.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T00:51:50.393Z","isFirstParty":false}