{"uid":"cap_yY_aOWUQkTXZkAA96oRl_","slug":"hmac-sha256-message-authentication-462d62eb","name":"HMAC-SHA256 Message Authentication","description":"HMAC-SHA256 of a string with a secret key","url":"https://x402render-u5vwpxpyua-uc.a.run.app/hmac-sha256","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"key":{"type":"string","description":"string"},"text":{"type":"string","description":"string"}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.01","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.01/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_GPkdrwPNV6hRxOx5jOdw-","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.01","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Computes an HMAC-SHA256 digest of a given text string using a provided secret key","exampleAgentPrompt":"Compute an HMAC-SHA256 signature for the message 'order_id=12345&amount=99.99' using my secret key 'mySuperSecretKey2024'.","exampleUseCases":[{"title":"Webhook signature verification","prompt":"Generate an HMAC-SHA256 signature for the payload '{\"event\":\"payment.completed\",\"amount\":150}' using my webhook secret 'whsec_abc123xyz' so I can validate it matches what the sender claims."},{"title":"API request signing","prompt":"Sign the string 'GET /api/orders/42 timestamp=1715000000' with the HMAC-SHA256 algorithm using my API secret key 'prod_secret_key_789' to include as an auth header."},{"title":"Data integrity token generation","prompt":"Create an HMAC-SHA256 digest for the text 'user_id=987&action=delete&resource=account' with the key 'internalSharedSecret' so I can attach it to the request as a tamper-proof token."}],"resultDescription":"Returns the HMAC-SHA256 hexadecimal digest (message authentication code) computed from the input text using the provided secret key, allowing the caller to authenticate or verify the integrity of the original message.","failureModes":["Missing 'key' or 'text' field in request body returns a 400 error","Empty string key or text may produce a valid but trivially weak HMAC","Payment not attached or insufficient USDC balance results in 402 Payment Required","Server error on the cloud run instance returns 500 with no digest"],"whenToPreferThis":"Choose this endpoint when you need a simple, stateless HMAC-SHA256 computation as a service without setting up local crypto libraries — especially useful in low-code or agent workflows where running native crypto code is inconvenient. Prefer it over generic hashing endpoints (MD5, SHA-512 siblings) when you need keyed authentication rather than a plain hash, and when the $0.01 per-call cost is acceptable for on-demand signing.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T12:52:28.214Z","isFirstParty":false}