{"id":66,"date":"2026-10-16T09:00:00","date_gmt":"2026-10-16T07:00:00","guid":{"rendered":"https:\/\/yindle.com\/?p=66"},"modified":"2026-10-16T09:00:00","modified_gmt":"2026-10-16T07:00:00","slug":"idempotentie-dubbele-orders-notities-refunds","status":"publish","type":"post","link":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/","title":{"rendered":"Idempotency in e-commerce: prevent duplicate orders, notes and refunds"},"content":{"rendered":"<p>Idempotency means the same technical request can be submitted safely multiple times without duplicating the business result. This is essential in e-commerce: webhooks are repeated, network connections fail and confirmation can be missing even though the first action was completed. Without idempotency, duplicate AFAS orders, repeated WooCommerce notes or even multiple refunds can result.<\/p>\n\n<p>\u201cWe process every message only once\u201d is not a realistic foundation. Design a process in which repetition is normal and traceable instead.<\/p>\n\n<h2>Why messages arrive twice<\/h2>\n\n<p>A system that receives no timely confirmation after sending cannot be certain the recipient completed the request. Retrying is then sensible. A webhook provider may also resend an event if the response was late. Administrators can additionally restart a failed task manually.<\/p>\n\n<p>There are therefore two separate questions:<\/p>\n\n<ol>\n  <li>Have we seen this technical message before?<\/li>\n  <li>Has the desired business result already been achieved?<\/li>\n<\/ol>\n\n<p>Answering only the first question is insufficient. A new event may refer to the same order again, while the result must exist only once.<\/p>\n\n<h2>Choose a stable identity<\/h2>\n\n<p>Use a key describing the business result, such as the combination of online store, order number and action type. For a refund, the intended amount or specific return action also belongs to the identity. The key must remain the same on repeated attempts and must not be randomly regenerated.<\/p>\n\n<p>Also retain external references. If a WooCommerce order has already received an AFAS sales order number, the integration can check during recovery that the relationship still holds. A visible title or customer name is not a reliable key: it can change and is not necessarily unique.<\/p>\n\n<h2>Read before writing again<\/h2>\n\n<p>Suppose a request to AFAS or Mollie times out. Whether the action completed is unknown. Do not immediately resend the same mutation. First use the stable external identity to check whether the intended result already exists. If the outcome remains uncertain, refer the action to an employee rather than guessing.<\/p>\n\n<p>This pattern is also called reconciliation: the integration compares the desired state with the demonstrable current state before deciding the next step. It takes more design work than a simple retry, but prevents financial and administrative harm.<\/p>\n\n<h2>Different actions need different protection<\/h2>\n\n<figure class=\"wp-block-table\"><table>\n  <thead>\n    <tr><th>Action<\/th><th>Risk on repetition<\/th><th>Appropriate protection<\/th><\/tr>\n  <\/thead>\n  <tbody>\n    <tr><td>Create an AFAS order<\/td><td>Duplicate sales order<\/td><td>Check and retain the external order reference<\/td><\/tr>\n    <tr><td>Add a WooCommerce note<\/td><td>Cluttered order history and repeated email<\/td><td>Stable note identity or recognition of the existing outcome<\/td><\/tr>\n    <tr><td>Set stock to a value<\/td><td>Old value overwrites new value<\/td><td>Check version\/order; write an absolute value<\/td><\/tr>\n    <tr><td>Issue a refund<\/td><td>Multiple movements of money<\/td><td>Unique refund request plus provider verification<\/td><\/tr>\n    <tr><td>Process delivery status<\/td><td>Reversion to an older status<\/td><td>Allowed status transitions and event order<\/td><\/tr>\n  <\/tbody>\n<\/table><\/figure>\n\n<h2>Prevent webhook echoes<\/h2>\n\n<p>Duplicate processing can also arise from a loop. Connect changes a WooCommerce order, WooCommerce publishes a new webhook event and that event starts the same action again. Mark the origin of changes or recognise the already processed state. Save only when something actually changes.<\/p>\n\n<p>That final rule seems small, but matters. An unnecessary \u201csave\u201d can trigger new hooks, notifications and follow-up processes even if the content stayed the same.<\/p>\n\n<h2>Make retries visible and targeted<\/h2>\n\n<p>Administrators need more than a red error and a generic \u201cretry\u201d button. Show the intended business action, which external steps have succeeded and which step can safely run again. A multi-step return may already be recorded in AFAS while only the payment provider still needs checking.<\/p>\n\n<p>Use a limit and increasing delay for automatic retries. Permanent input errors do not improve through endless repetition. Pause a task with an understandable recovery reason when mapping, permissions or source data needs changing.<\/p>\n\n<h2>Test uncertain outcomes in particular<\/h2>\n\n<ul>\n  <li>Send the same webhook event twice.<\/li>\n  <li>Let the destination system succeed but lose the confirmation.<\/li>\n  <li>Restart a task after one of several external steps is already complete.<\/li>\n  <li>Process an older event after receiving a newer status.<\/li>\n  <li>Let two workers pick up the same order simultaneously.<\/li>\n  <li>Check that a manual retry retains the same action identity.<\/li>\n<\/ul>\n\n<p>Idempotency is therefore a functional property of the whole process, not an isolated programming technique. In <a href=\"\/en\/online-store-erp-integration\/\">reliably integrating an online store and ERP<\/a> we explain why traceability and recovery are fundamental. The specific AFAS context appears on <a href=\"\/en\/woocommerce-afas-integration-guide\/\">WooCommerce\u2013AFAS integration<\/a>, while <a href=\"\/en\/connect\/\">Yindle Connect<\/a> makes the workflows involved manageable.<\/p>\n\n<h2>Frequently asked questions about safe retries<\/h2>\n\n<h3>Is a webhook ID sufficient?<\/h3>\n\n<p>No. It may prevent exactly the same message from being processed twice, but two different messages can request the same business action. Use both message identity and a key for the intended result, such as \u201ccreate AFAS order for shop X and order Y\u201d.<\/p>\n\n<h3>Are status updates automatically idempotent?<\/h3>\n\n<p>Setting an absolute status to the same value seems safe, but associated side effects can still run twice. These include email, notes, stock changes or follow-up tasks. Check not only the field, but also whether the associated business action has demonstrably been completed.<\/p>\n\n<h3>How long should idempotency keys be retained?<\/h3>\n\n<p>Long enough to cover realistic retries, delayed events and manual recovery. For financial or administrative results, the external reference may form part of lasting process history. Align retention periods with business accountability and privacy; do not automatically retain complete payloads when a limited identity suffices.<\/p>\n\n<h2>Check protection in production<\/h2>\n\n<p>Monitor how often duplicates are blocked, how many actions need reconciliation after an uncertain outcome and which manual retries occur. A sudden increase may indicate timeouts, changed webhook settings or a key that is no longer stable. Make the signal investigable without widely exposing sensitive data in log entries.<\/p>\n\n<p>For Mollie actions, the <a href=\"https:\/\/docs.mollie.com\/reference\/api-idempotency\">official documentation on idempotency keys<\/a> is also relevant. Treat provider-specific protection as an additional layer while retaining your own business identity and result checks.<\/p>\n\n<p>Want to check whether an existing integration safely handles duplicate business actions? <a href=\"\/en\/contact\/\">Ask Yindle for a focused integration review<\/a>.<\/p>\n\n\n<div class=\"wp-block-buttons is-layout-flex wp-block-buttons-is-layout-flex\">\n<div class=\"wp-block-button\"><a class=\"wp-block-button__link wp-element-button\" href=\"\/en\/connect\/\">Explore Yindle Connect<\/a><\/div>\n\n\n\n<div class=\"wp-block-button is-style-outline is-style-outline--1\"><a class=\"wp-block-button__link wp-element-button\" href=\"\/en\/contact\/\">Have your retries reviewed<\/a><\/div>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>Why messages must be safely repeatable and how to prevent duplicate administrative and financial actions in practice.<\/p>","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-66","post","type-post","status-publish","format-standard","hentry","category-integraties"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.7 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Voorkom dubbele WooCommerce-orders en refunds<\/title>\n<meta name=\"description\" content=\"Leer hoe idempotentie, vaste actie-identiteiten en reconciliatie dubbele AFAS-orders, WooCommerce-notities en Mollie-refunds voorkomen in je koppeling.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/\" \/>\n<meta property=\"og:locale\" content=\"en_GB\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Voorkom dubbele WooCommerce-orders en refunds\" \/>\n<meta property=\"og:description\" content=\"Leer hoe idempotentie, vaste actie-identiteiten en reconciliatie dubbele AFAS-orders, WooCommerce-notities en Mollie-refunds voorkomen in je koppeling.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/\" \/>\n<meta property=\"og:site_name\" content=\"Yindle\" \/>\n<meta property=\"article:published_time\" content=\"2026-10-16T07:00:00+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/yindle.com\/wp-content\/themes\/yindle\/assets\/images\/yindle-social-share.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"630\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Yindle\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Yindle\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\\\/\"},\"author\":{\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/#organization\"},\"headline\":\"Idempotentie in e-commerce: voorkom dubbele orders, notities en refunds\",\"datePublished\":\"2026-10-16T07:00:00+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\\\/\"},\"wordCount\":938,\"publisher\":{\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/#organization\"},\"articleSection\":[\"Integraties\"],\"inLanguage\":\"en-GB\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\\\/\",\"url\":\"https:\\\/\\\/yindle.com\\\/en\\\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\\\/\",\"name\":\"Voorkom dubbele WooCommerce-orders en refunds\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/#website\"},\"datePublished\":\"2026-10-16T07:00:00+00:00\",\"description\":\"Leer hoe idempotentie, vaste actie-identiteiten en reconciliatie dubbele AFAS-orders, WooCommerce-notities en Mollie-refunds voorkomen in je koppeling.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\\\/#breadcrumb\"},\"inLanguage\":\"en-GB\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/yindle.com\\\/en\\\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/yindle.com\\\/en\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Idempotentie in e-commerce: voorkom dubbele orders, notities en refunds\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/#website\",\"url\":\"https:\\\/\\\/yindle.com\\\/en\\\/\",\"name\":\"Yindle\",\"description\":\"Software voor e-commerce en klantprocessen\",\"publisher\":{\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/yindle.com\\\/en\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-GB\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/#organization\",\"name\":\"Yindle B.V.\",\"url\":\"https:\\\/\\\/yindle.com\\\/en\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/yindle.com\\\/wp-content\\\/uploads\\\/2026\\\/09\\\/yindle-site-icon.png\",\"contentUrl\":\"https:\\\/\\\/yindle.com\\\/wp-content\\\/uploads\\\/2026\\\/09\\\/yindle-site-icon.png\",\"width\":512,\"height\":512,\"caption\":\"Yindle B.V.\"},\"image\":{\"@id\":\"https:\\\/\\\/yindle.com\\\/en\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"legalName\":\"Yindle B.V.\",\"address\":{\"@type\":\"PostalAddress\",\"streetAddress\":\"Markt 43\",\"postalCode\":\"5554 CA\",\"addressLocality\":\"Valkenswaard\",\"addressCountry\":\"NL\"},\"identifier\":{\"@type\":\"PropertyValue\",\"propertyID\":\"KvK\",\"value\":\"99695367\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Prevent duplicate WooCommerce orders and refunds","description":"Learn how idempotency, stable action identities and reconciliation prevent duplicate AFAS orders, WooCommerce notes and Mollie refunds in your integration.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/","og_locale":"en_GB","og_type":"article","og_title":"Voorkom dubbele WooCommerce-orders en refunds","og_description":"Leer hoe idempotentie, vaste actie-identiteiten en reconciliatie dubbele AFAS-orders, WooCommerce-notities en Mollie-refunds voorkomen in je koppeling.","og_url":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/","og_site_name":"Yindle","article_published_time":"2026-10-16T07:00:00+00:00","og_image":[{"width":1200,"height":630,"url":"https:\/\/yindle.com\/wp-content\/themes\/yindle\/assets\/images\/yindle-social-share.png","type":"image\/png"}],"author":"Yindle","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Yindle","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/#article","isPartOf":{"@id":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/"},"author":{"@id":"https:\/\/yindle.com\/en\/#organization"},"headline":"Idempotentie in e-commerce: voorkom dubbele orders, notities en refunds","datePublished":"2026-10-16T07:00:00+00:00","mainEntityOfPage":{"@id":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/"},"wordCount":938,"publisher":{"@id":"https:\/\/yindle.com\/en\/#organization"},"articleSection":["Integraties"],"inLanguage":"en-GB"},{"@type":"WebPage","@id":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/","url":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/","name":"Prevent duplicate WooCommerce orders and refunds","isPartOf":{"@id":"https:\/\/yindle.com\/en\/#website"},"datePublished":"2026-10-16T07:00:00+00:00","description":"Learn how idempotency, stable action identities and reconciliation prevent duplicate AFAS orders, WooCommerce notes and Mollie refunds in your integration.","breadcrumb":{"@id":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/#breadcrumb"},"inLanguage":"en-GB","potentialAction":[{"@type":"ReadAction","target":["https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/yindle.com\/en\/idempotency-in-e-commerce-prevent-duplicate-orders-notes-and-refunds\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/yindle.com\/en\/"},{"@type":"ListItem","position":2,"name":"Idempotentie in e-commerce: voorkom dubbele orders, notities en refunds"}]},{"@type":"WebSite","@id":"https:\/\/yindle.com\/en\/#website","url":"https:\/\/yindle.com\/en\/","name":"Yindle","description":"Software for e-commerce and customer processes","publisher":{"@id":"https:\/\/yindle.com\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/yindle.com\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-GB"},{"@type":"Organization","@id":"https:\/\/yindle.com\/en\/#organization","name":"Yindle B.V.","url":"https:\/\/yindle.com\/en\/","logo":{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/yindle.com\/en\/#\/schema\/logo\/image\/","url":"https:\/\/yindle.com\/wp-content\/uploads\/2026\/09\/yindle-site-icon.png","contentUrl":"https:\/\/yindle.com\/wp-content\/uploads\/2026\/09\/yindle-site-icon.png","width":512,"height":512,"caption":"Yindle B.V."},"image":{"@id":"https:\/\/yindle.com\/en\/#\/schema\/logo\/image\/"},"legalName":"Yindle B.V.","address":{"@type":"PostalAddress","streetAddress":"Markt 43","postalCode":"5554 CA","addressLocality":"Valkenswaard","addressCountry":"NL"},"identifier":{"@type":"PropertyValue","propertyID":"KvK","value":"99695367"}}]}},"_links":{"self":[{"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/posts\/66","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/comments?post=66"}],"version-history":[{"count":1,"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/posts\/66\/revisions"}],"predecessor-version":[{"id":1003,"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/posts\/66\/revisions\/1003"}],"wp:attachment":[{"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/media?parent=66"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/categories?post=66"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/yindle.com\/en\/wp-json\/wp\/v2\/tags?post=66"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}