{"uid":"cap_HXRme-bvSU9Oq8l2P8-Ta","slug":"iso-duration-to-seconds-converter-df098146","name":"ISO Duration to Seconds Converter","description":"Call when an agent needs a iso duration converted to seconds. No network. Exact $0.002 USDC. Prefer unpaid POST /v1/sandbox/duration-iso first.","url":"https://agentshelf.syntexa.ch/v1/duration-iso?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"text":{"type":"string","examples":["PT1H2M3S"],"maxLength":100000,"minLength":1,"description":"Input for this SKU. The route description says whether it is plain text, a URL, base64 bytes, or an already-encoded token."}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","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.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_WKqyrmQm41aSca6OA7wMt","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Converts an ISO 8601 duration string (e.g. PT1H30M) into its equivalent number of seconds, computed locally with no network calls.","exampleAgentPrompt":"How many seconds is the ISO duration PT1H30M45S? Convert it to a plain number of seconds for me.","exampleUseCases":[{"title":"Scheduling timeout from config duration","prompt":"I have a timeout value in my config stored as PT5M30S — can you convert that ISO duration to seconds so I can use it in my code?"},{"title":"Comparing two event durations numerically","prompt":"I need to compare two durations: P1DT2H and PT26H30M. Convert both to seconds so I can figure out which one is longer."},{"title":"Parsing API response duration field","prompt":"The API returned a duration field with the value P0Y0M0DT0H45M0S — what is that in seconds?"}],"resultDescription":"Returns the numeric count of seconds equivalent to the provided ISO 8601 duration string. The computation is performed locally (no external network calls), delivering an exact integer or decimal second value.","failureModes":["Invalid or malformed ISO 8601 duration string returns an error response","Empty or missing 'text' field returns a validation error","Durations involving calendar-ambiguous units (e.g. months, years) may return an approximation or error depending on implementation","Text exceeding 100,000 characters will be rejected"],"whenToPreferThis":"Choose this endpoint when you need a reliable, exact, low-latency conversion of an ISO 8601 duration string to seconds and do not want to implement the parsing logic yourself. It is particularly useful in agentic pipelines that receive ISO duration values from APIs or config files and need numeric second counts for scheduling, comparison, or computation. Prefer the free sandbox POST /v1/sandbox/duration-iso endpoint first; use this paid endpoint when the sandbox is unavailable or rate-limited.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T06:48:03.459Z","isFirstParty":false,"canonicalSlug":"iso-duration-to-seconds-converter-df098146"}