{"uid":"cap_m0_5oGSjf6TA9MEPTdLka","slug":"signalharness-market-twap-calculator-69569266","name":"SignalHarness Market TWAP Calculator","description":"Explore 330 pay-per-call x402 API services and 27 agent-native digital products, with Base USDC pricing, secure Polar checkout, and free discovery.","url":"https://signalharness.ai/api/agent/services/market_twap/invoke","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"twap_request":{"type":"string","maxLength":65536,"minLength":2}}},"responseSchema":{"type":"json","example":{"replay":false,"result":{"warnings":["TWAP coverage and observation quality are caller controlled."],"service_id":"market_twap","evidence_scope":"caller_supplied_data","twap_calculation":"{\"duration_ms\":\"1000\",\"observation_count\":2,\"twap\":\"10\",\"weighting\":\"left_continuous\"}"},"status":"succeeded","receipt":{"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","usage":[],"status":"succeeded","network":"eip155:8453","artifacts":[],"endedAtMs":0,"latencyMs":0,"paymentId":"example-payment","receiptId":"example-receipt","requestId":"example-request","serviceId":"market_twap","executionId":"example-execution","startedAtMs":0,"amountAtomic":"5000","resultSha256":"90a9235ba27d3ed5806c8c393d3fcc459b25283b3de1823809767df300ba5a7a","serviceVersion":"1.0.0","settlementReference":"0x0000000000000000000000000000000000000000000000000000000000000000"},"artifacts":[],"requestId":"example-request","executionId":"example-execution"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","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.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_v-krw_I1AIhi8hsoWnhz7","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Computes a Time-Weighted Average Price (TWAP) for a given market or asset based on caller-supplied data","exampleAgentPrompt":"Calculate the time-weighted average price (TWAP) for ETH/USDC over the last 4 hours using the price data I'm providing — I need this for a DeFi trading strategy to minimize slippage.","exampleUseCases":[{"title":"DeFi trade slippage reduction","prompt":"I'm executing a large USDC buy of ETH and want to minimize slippage — calculate the TWAP for ETH over the past 2 hours using this price series so I can benchmark my execution."},{"title":"On-chain price oracle verification","prompt":"I need to verify whether the on-chain TWAP oracle price for WBTC over the last 30 minutes matches my off-chain calculation — can you compute the TWAP from this dataset I'm supplying?"},{"title":"Automated market-making strategy calibration","prompt":"My market-making bot needs a TWAP reading for the SOL/USDC pair over the last 6 hours to recalibrate its bid-ask spread — compute it from the OHLCV data I'm sending."}],"resultDescription":"Returns a JSON object containing the TWAP calculation string, any warnings about the input data, an evidence scope indicator (e.g. 'caller_supplied_data'), the service ID, plus a signed receipt with payment details including the USDC amount paid, network (Base/EIP-155:8453), request/execution IDs, result SHA-256 hash, and latency metrics.","failureModes":["Malformed or unparseable twap_request string returns an error status","twap_request below 2 characters or above 65536 characters is rejected by schema validation","Insufficient or inconsistent price data in the request may produce warnings or failed computation","Payment failure on the x402 micropayment layer prevents execution","Missing required fields in the TWAP request body cause validation errors"],"whenToPreferThis":"Choose this endpoint when you need a verifiable, agent-native TWAP calculation with a cryptographic receipt (SHA-256 result hash, payment proof) rather than pulling raw price feeds from a CEX or DEX API. Best suited for DeFi agents that need auditable price computation at low cost ($0.005 USDC per call) and can supply their own price series for processing. Prefer this over raw oracle reads when you need a signed artifact proving the computation was performed.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T13:07:21.623Z","isFirstParty":false}