{"uid":"cap_7iXoVUC_Txhc4rbRTsyaN","slug":"webref-time-until-5ff71dff","name":"WebRef Time Until","description":"Web standards and time reference for AI agents: HTTP status codes with what the client should do, retry semantics, MIME types and content-type matching, request-method safety and idempotency, plus deadline arithmetic - time until a moment, weekday and business-day checks, duration conversion and Unix timestamps. Pay per call in USDC on Base via x402 or USDC on Tempo via MPP. No signup, no API key, no KYC.","url":"https://webref.johnaio281.workers.dev/api/time/time_until?utm_source=zero.xyz","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","HEAD","DELETE"],"type":"string"},"queryParams":{"to":{"def":{"type":"string"},"type":"string"},"from":{"def":{"type":"string"},"type":"string"},"type":"object"}},"additionalProperties":false}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.003","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.003/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.003","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.003","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_MWiAbaUhapvR1M7ObWzR3","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.003","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Calculates the duration or time remaining from one moment to another, returning deadline arithmetic results like how long until a target datetime.","exampleAgentPrompt":"How long is it from now until Friday December 31st at midnight? I need the duration broken down so I can plan my deadline.","exampleUseCases":[{"title":"Countdown to project deadline","prompt":"How much time is left between now and 2025-09-01T09:00:00Z? I need to know the exact duration so I can set up my project timeline."},{"title":"Event countdown for notifications","prompt":"Calculate how long it is from 2025-06-15T00:00:00Z until 2025-07-04T20:00:00Z so I know when to start sending event reminders."},{"title":"SLA expiry time check","prompt":"How long do I have left from right now until 2025-08-01T17:00:00Z? I'm tracking an SLA deadline and need the remaining hours and minutes."}],"resultDescription":"Returns a structured result containing the computed duration between the 'from' and 'to' datetimes, expressed as human-readable intervals (e.g. days, hours, minutes, seconds) and possibly raw seconds or a formatted string indicating time remaining or elapsed.","failureModes":["Missing or malformed 'to' query parameter returns an error","Invalid datetime format in 'from' or 'to' causes a 400-level response","'from' datetime after 'to' datetime may return negative duration or an error","Payment failure via x402/MPP blocks the request with a 402 response","Rate limiting or server errors return 5xx responses"],"whenToPreferThis":"Choose this endpoint when you need precise deadline arithmetic — computing the exact duration between two points in time — without building custom date math. It is ideal for SLA tracking, countdown timers, scheduling logic, and any agent workflow that must reason about how much time remains until or has passed since a specific moment. Prefer it over general-purpose date libraries when you want a pay-per-call, no-signup, serverless utility with no authentication overhead.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-22T12:40:42.991Z","isFirstParty":false,"canonicalSlug":"webref-time-until-5ff71dff"}