{"uid":"cap_XeJUgh6Y2nt1ISraj6yhT","slug":"writerslogic-dedup-window-d01d8379","name":"WritersLogic Dedup Window","description":"Pay-per-call agents settled in USDC on Base via x402. Every response carries a signed provenance envelope.","url":"https://agents.writerslogic.com/api/v1/dedup-window?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"history":{"type":"array","items":{"type":"object","required":["identity","receivedAt"],"properties":{"id":{"type":"string","maxLength":200,"minLength":1},"outcome":{"enum":["processed","failed","in-flight","unknown"],"type":"string","description":"What happened when this delivery was handled (history only)."},"payload":{"description":"Event body; hashed with RFC 8785 canonical JSON to detect conflicting duplicates."},"identity":{"type":"string","maxLength":200,"minLength":1,"description":"Delivery identity: the provider's event id, or a key built from the fields that define the event."},"receivedAt":{"type":"string","maxLength":40,"description":"RFC 3339 instant."},"payloadDigest":{"type":"string","maxLength":128,"minLength":8,"description":"Alternative to payload: a digest the caller computed."}},"additionalProperties":false},"maxItems":500},"incoming":{"type":"object","required":["identity","receivedAt"],"properties":{"id":{"type":"string","maxLength":200,"minLength":1},"outcome":{"enum":["processed","failed","in-flight","unknown"],"type":"string","description":"What happened when this delivery was handled (history only)."},"payload":{"description":"Event body; hashed with RFC 8785 canonical JSON to detect conflicting duplicates."},"identity":{"type":"string","maxLength":200,"minLength":1,"description":"Delivery identity: the provider's event id, or a key built from the fields that define the event."},"receivedAt":{"type":"string","maxLength":40,"description":"RFC 3339 instant."},"payloadDigest":{"type":"string","maxLength":128,"minLength":8,"description":"Alternative to payload: a digest the caller computed."}},"additionalProperties":false},"windowMode":{"enum":["from-first","sliding"],"type":"string","description":"from-first (default): a group's window starts at its first delivery. sliding: each delivery extends the window."},"windowSeconds":{"type":"integer","maximum":2592000,"minimum":1}}},"responseSchema":{"type":"json"},"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__v63qlm634ZtErrkbIEfB","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":"Stateless webhook/event deduplication engine that classifies an incoming delivery as process, dedupe, retry, reconcile, or abstain based on a caller-supplied history window","exampleAgentPrompt":"I just received a webhook event with identity 'evt_abc123' at 2025-01-15T10:30:00Z — check it against my delivery history of the last 300 seconds using from-first mode and tell me whether I should process it, skip it as a duplicate, treat it as a retry, reconcile it, or abstain.","exampleUseCases":[{"title":"Webhook idempotency for payment events","prompt":"I keep getting duplicate Stripe payment webhooks — I have a history of the last 10 deliveries for event 'ch_3ABC123' and a new one just arrived at 2025-01-15T12:00:00Z. Check the past 600 seconds using from-first mode and tell me if I should process it or skip it."},{"title":"Retry detection for failed event deliveries","prompt":"An event with identity 'order.shipped.order_9981' arrived again just now at 2025-01-15T14:00:00Z. All my previous deliveries of it in the last 3600 seconds failed. Use sliding window mode to tell me if this qualifies as a retry I should process."},{"title":"Conflict detection for diverging payloads","prompt":"I'm seeing two deliveries with identity 'inventory.update.SKU-77' but I think they have different payloads — can you check my history over the past 900 seconds with from-first mode and flag whether there's a reconcile conflict I need to resolve?"}],"resultDescription":"Returns a decision field with one of: process (no duplicates found), dedupe (same payload already successfully processed), retry (all prior deliveries failed), reconcile (an earlier delivery is in-flight/unknown or a conflicting payload was seen), or abstain (insufficient evidence). Also returns a status of pass, fail, or unknown corresponding to the decision. Additionally lists duplicate groups found in history and any payload conflicts detected.","failureModes":["Missing required fields (identity or receivedAt) on incoming or history items returns a validation error","windowSeconds out of range (< 1 or > 2592000) returns a schema error","payloadDigest too short (< 8 chars) triggers validation failure","More than 500 history items exceeds maxItems limit","Ambiguous or missing timestamps cause abstain decision rather than a hard error","No matching identity in history returns process decision by design"],"whenToPreferThis":"Use this endpoint when you need stateless, caller-managed event deduplication without maintaining server-side state — ideal for serverless functions, agent pipelines, and webhook processors that already track delivery history. Prefer this over database-based idempotency checks when you want an explicit classification (not just a boolean) distinguishing retries, reconciliation needs, and payload conflicts. Best when you can supply up to 500 history records per call and need deterministic, auditable dedup logic.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-19T06:38:33.773Z","isFirstParty":false,"canonicalSlug":"writerslogic-dedup-window-d01d8379"}