Title: Inventory synced but incorrect
Last modified: December 8, 2021

---

# Inventory synced but incorrect

 *  Resolved [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/)
 * Hi guys,
 * A client’s been in touch to let me know the following:
 * > Hi Matt, really strange one for you – we had 1 item left of a particular beer.
   > I hadn’t tried it, so I thought I’d buy it. Website said 1 left in stock. Bought
   > it at the shop via Zettle. Zettle updates stock to 0. Ideal. Refreshed the 
   > website page, and it now says we have 3 (!) in stock.
 * I’ve had a look at the logs and the only clue is the plugin ‘attempting’ to reduce
   the stock level: `Attempting to update stock of product 6015 with an amount of
   2`
 * This suggests the website thought there were 3 items in stock but the client 
   is adamant it read 1 on the front-end. They say this isn’t the first issue like
   this but have assumed it was their error in the past. The first other item I 
   checked says it’s syncing according to the plugin but the stock levels are wildly
   different (2 in Zettle, 9 in WooCommerce). I’ve not checked more products but
   looks like we have a major issue with inventory levels 🙈
 * What steps can we take to find out why these are so out of whack? All help greatly
   appreciated!
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Finventory-synced-but-incorrect%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 15 replies - 1 through 15 (of 32 total)

1 [2](https://wordpress.org/support/topic/inventory-synced-but-incorrect/page/2/?output_format=md)
[3](https://wordpress.org/support/topic/inventory-synced-but-incorrect/page/3/?output_format=md)
[→](https://wordpress.org/support/topic/inventory-synced-but-incorrect/page/2/?output_format=md)

 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15144889)
 * The client has now reported numerous instances of inventory level discrepancies,
   these seem to be occurring most often when a purchase is made in Zettle but many
   times the inventory levels are already wrong between the 2 platforms prior to
   purchase. Their most recent report is as follows:
 * > Website said we had 11
   >  Zettle said 46 (we have 46) I bought 4 online Website
   > changed to 7 Zettle changed to 7
 * Log states `Attempting to update stock of product 6073 with an amount of -36`
 * WordPress, WooCommerce and this plugin were all on the latest versions (5.8.2,
   5.9.0 and 1.5.2 respectively), the latter of which was updated recently so I’ve
   rolled it back to 1.4.2 in the hopes that will improve things.
 * Need input from your end regarding how to proceed ASAP.
 *  Plugin Support [Syde Joost](https://wordpress.org/support/users/joostvandevijver/)
 * (@joostvandevijver)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15146654)
 * Hello [@matthewdixon](https://wordpress.org/support/users/matthewdixon/)
 * thank you for reaching out to us, we are here to help.
    There are 2 situations
   that can cause this that we have identified. 1) Other plugins adjusting stock
   count. 2) Hosting firewall settings cause webhooks to fail.
 * Let me answer both cases:
    1) In the past we have seen other plugins that also
   have a stock adjustment function that could cause malfunctions in the stock updates.
   Sometimes they would avoid the change or they would cause multiplications of 
   the changes. 2) your situation sounds more like the webhook issue. It seems that
   the updates that need to come from Zettle to WooCommerce are not going through.
   We have been seeing this in some cases where the webhooks for this activity are
   being blocked by the hosting provider’s firewall. I have looked at the webhook
   logs that we have access to and see multiple entries for this website (redelephantbeercellar.
   co.uk/), so I would start by contacting your hosting partner to have this reviewed.
   In one of my last cases that we got resolved the merchant informed us the following:
 * > It may seem that PayPal’s server, which is trying to contact your web site 
   > via webhook, has ended up in our automatic firewall due to the large number
   > of requests.
   >  I have removed these blocks now, and will look at the possibility
   > of adjusting the filter so that these are not caught again.
 * Please see if you can do the same.
 * Kind regards,
    Joost
 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15147551)
 * Hi Joost,
 * Thanks very much for the info, that’s really helpful. There are no other plugins
   on the site which could be interfering with the stock levels so I think it’s 
   safe to assume number 2 is the culprit! Hosting support say there’s nothing on
   the server that could be blocking traffic but there are 2 other possibilities:
   Cloudflare and Wordfence.
 * Cloudflare – are you aware of anything here which could cause this issue? There
   are options here to add firewall rules.
 * Wordfence – there are options to whitelist IPs and URLs, could you let me know
   what would need whitelisting? I’ve disabled the plugin completely for now but
   would like it enabled in the long run.
 * Kind regards,
    Matthew
 *  Plugin Support [Syde Joost](https://wordpress.org/support/users/joostvandevijver/)
 * (@joostvandevijver)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15147735)
 * Hello [@matthewdixon](https://wordpress.org/support/users/matthewdixon/)
 * we are not aware of any issue with these 2 plugins, but you should be able to
   test if one of these 2 is the culprit or not, right? You could deactivate them
   and test manually if the issue still is there.
 * Regarding the IPS’s/URL’s, we had this question before, but the answer is not
   that straightforward, since Zettle is hosted on AWS and there is no 1 IP or range
   for this. We have to advise against using IP ranges, but if they want to they
   need to add the whole AWS IP range for region eu-west-1 from here: [https://docs.aws.amazon.com/general/latest/gr/aws-ip-ranges.html](https://docs.aws.amazon.com/general/latest/gr/aws-ip-ranges.html)
   
   Using such a broad range doesn’t give any real value and probably won’t fix your
   issue (as we saw in previous instances of this).
 * Let me know if you get any results on this.
 * Kind regards,
    Joost
 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15150329)
 * Hi Joost,
 * Testing this won’t be easy, manually updating stock levels on either platform
   has never been a problem, we’re seeing the issue when a purchase is made and 
   each case it looks like the stock levels were already out of sync prior to the
   purchase. The only thing I can do right now is deactivate Wordfence and cross
   fingers which is far from ideal.
 * > I have removed these blocks now, and will look at the possibility of adjusting
   > the filter so that these are not caught again.
 * Who was this quote from? How were they able to remove ‘these blocks’? If IPs 
   aren’t going to work is there a domain the requests originate from that could
   be allowed?
 *  Plugin Support [Syde Joost](https://wordpress.org/support/users/joostvandevijver/)
 * (@joostvandevijver)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15150690)
 * Hello Matthew,
 * This response was from the other merchant that was contacting us when encountering
   similar issues.
 * Just to clear up the situation: you are not able to reproduce any issue by manually
   adjusting the stock in Zettle? In the related cases, the merchants can normally
   reproduce the issue when adjusting Zettle stock (and WC stock does not sync to
   that change).
 * When I reviewed the webhook notification, I see that these notifications are 
   all concerning 1 product, this product has got UUID 64f0e1fa-9ba4-11eb-a084-3347a5462f41
   
   Maybe you can take a look into that product and see what is causing that to encounter
   issues?
 * However, stating before that this is not as clearly related to our known bug 
   with the hosting partner (if you confirm my statements above), then it would 
   indeed be best to continue looking into the plugins you are using.
    If you want
   us to take a look, it would be best to get the system report and Zettle logs.
   You can copy the logfiles from here: – WooCommerce > Status > Get system report
   > Copy for support – WooCommerce > Status > Logs > select “zettle-pos-integration-\[…\]”
   in the dropdown and click on view.
 * If you don’t feel comfortable sharing those details on a public forum, please
   open a ticket with our service desk. You can find the instruction for this here:
   [https://zettle.inpsyde.com/docs/request-support/](https://zettle.inpsyde.com/docs/request-support/)
   (
   please add the URL of this thread in the ticket as well)
 * Kind regards,
    Joost
 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15151606)
 * Yes to confirm when I manually update the stock levels, either on the site or
   in Zettle, the other platform reflects this change pretty much instantly (this
   is just my experience and I’ll check with the client but they’ve never complained
   of it not working).
 * Issues from them are coming in thick and fast, they’re all over the place:
 * > I don’t know if you need/want any more examples but the Verdant – Italian Pilsner(
   > we have 6) has suddenly shot up to 15! Changing it back to 6, but yeah… it 
   > just seems like it is happening to random items.
   > Oh christ, there are so many new items that it’s happening to! 🙈
 * I’ve generated the report with the current plugins but am going to roll them 
   back to their state before I did the latest maintenance updates. I don’t think
   any other plugin on the site could be interfering but I’ll send over the system
   report and logs.
 * Regarding the previous comment of ‘I have removed these blocks now’, can you 
   let me know what this refers to? Maybe it will be helpful in this case if a URL
   can be whitelisted or something?
 * Also, regarding UUID 64f0e1fa-9ba4-11eb-a084-3347a5462f41, how can I tell which
   product this is on the website?
 * Kind regards,
    Matthew
 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15153535)
 * Morning fellas, me again!
 * I was wrong above, editing inventory levels in Zettle manually **does not** sync
   with the website, but crucially it **does** with Red Elephant’s sister site, 
   _Green_ Elephant!
 * These sites are pretty much identical with only a few styling differences. They
   have the same plugins and both run through Cloudflare, so we now have a working
   setup (Green Elephant) to compare against.
 * I’m using the same product on each site to test with:
 * [https://redelephantbeercellar.co.uk/product/la-trappe-blonde/](https://redelephantbeercellar.co.uk/product/la-trappe-blonde/)
   
   vs [https://greenelephantbeercellar.co.uk/product/la-trappe-blonde/](https://greenelephantbeercellar.co.uk/product/la-trappe-blonde/)
 * Manually updating the stock level in Zettle works perfectly for GEBC but not 
   at all for REBC. Both update fine if the level is manually changed in WooCommerce,
   so the issue is communication from Zettle to the website on REBC only. Please
   could you look at things your end to see why this works for one and not the other?
 * Looking at the logs I see this reference on GEBC:
 *     ```
       2021-12-11T09:33:12+00:00 INFO Received Webhook: InventoryBalanceChanged
       2021-12-11T09:33:12+00:00 INFO Attempting to update stock of product 816 with an amount of -1
       2021-12-11T09:33:25+00:00 INFO Received Webhook: InventoryBalanceChanged
       2021-12-11T09:33:25+00:00 INFO Attempting to update stock of product 816 with an amount of 1
       ```
   
 * But nothing similar on REBC, the only reference to `Received Webhook: InventoryBalanceChanged`
   is:
 *     ```
       2021-12-11T08:35:05+00:00 INFO Received Webhook: InventoryBalanceChanged
       2021-12-11T08:35:05+00:00 INFO Ignoring InventoryBalanceChanged event since it was triggered from our plugin
       ```
   
 * (I assume this is from me changing the stock level on the website, the odd thing
   is I’ve changed more than one on the website but this is the only reference to`
   Received Webhook: InventoryBalanceChanged`)
 * Kind regards,
    Matthew
 *  Plugin Support [Syde Joost](https://wordpress.org/support/users/joostvandevijver/)
 * (@joostvandevijver)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15157067)
 * Thanks Matthew, as informed on the Service Desk ticket, it looks like there is
   an issue ongoing, since I see more people having this issue since last week. 
   I have created a bug for our developer to take a look and I will add these details
   to this bug.
 * If you did any further testing or can tell me more details on where these 2 sites
   differ, please do so (here or in the SD ticket).
 * Thanks again for your support.
 * Kind regards,
    Joost
 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15159003)
 * Hi Joost,
 * Leaving this comment here as might be relevant to others in the future. The main
   difference between REBC and GEBC is their age, REBC where we have the problem
   is a year or so older. A thought occurred to me that this could be an issue with
   older API keys not having the correct permissions, so I created a new one for
   REBC and replaced the old one on the site. This hasn’t made any difference, manual
   inventory changes I make in Zettle are still not reflected on the site and I 
   keep coming across discrepancies which I’ll detail and to the Jira ticket.
 * Kind regards,
    Matthew
 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15161591)
 * Hi again Joost,
 * Just wondering if you could confirm one thing to be absolutely clear – when updating
   stock levels in Zettle > Products > Inventory, should this update WooCommerce?
   Looks like it works perfectly on GEBC, but I don’t think it ever has on REBC..
 *  Plugin Support [Syde Joost](https://wordpress.org/support/users/joostvandevijver/)
 * (@joostvandevijver)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15161705)
 * yes, that should be the case. That is how I tested this issue to occur on another
   merchant’s staging site when I connected it to my own Zettle account.
 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15161923)
 * And you saw the same behaviour on a site experiencing problems? Ie. manually 
   changing stock in Zettle failing to update WooCommerce?
 * I wonder if this is the case for all the other merchants experiencing issues 
   you mentioned in the Jira ticket, if this is a pattern it could be key to finding
   the issue.
 *  Plugin Support [Syde Joost](https://wordpress.org/support/users/joostvandevijver/)
 * (@joostvandevijver)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15161981)
 * I only have 1 other site that was able to test on, but yes: when I changed the
   stock for variation of a product, other variations of the same product were changed
   in different amounts on WooCommerce.
 *  Thread Starter [Matthew Dixon](https://wordpress.org/support/users/matthewdixon/)
 * (@matthewdixon)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/#post-15163005)
 * Hi [@joostvandevijver](https://wordpress.org/support/users/joostvandevijver/),
 * Any progress on this one? Have Zettle shed any light yet?
 * Just had an update from REBC that they have checked through WooCommerce and they‘
   would say that 70% of the stock levels are wrong’ – which equates to hundreds
   of products. This is causing them all kinds of headaches and is incredibly frustrating
   for me as I’m not sure what else I can try my end, other than doing a fresh sync
   of products from WooCommerce to Zettle – do you guys think this is worth a go?
   I imagine the issue will persist as looks like it’s on Zettle’s end but if you
   think it’s worth a go we can try it..

Viewing 15 replies - 1 through 15 (of 32 total)

1 [2](https://wordpress.org/support/topic/inventory-synced-but-incorrect/page/2/?output_format=md)
[3](https://wordpress.org/support/topic/inventory-synced-but-incorrect/page/3/?output_format=md)
[→](https://wordpress.org/support/topic/inventory-synced-but-incorrect/page/2/?output_format=md)

The topic ‘Inventory synced but incorrect’ is closed to new replies.

 * ![](https://ps.w.org/zettle-pos-integration/assets/icon-256x256.png?rev=2694076)
 * [PayPal Zettle POS for WooCommerce](https://wordpress.org/plugins/zettle-pos-integration/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/zettle-pos-integration/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/zettle-pos-integration/)
 * [Active Topics](https://wordpress.org/support/plugin/zettle-pos-integration/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/zettle-pos-integration/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/zettle-pos-integration/reviews/)

 * 32 replies
 * 4 participants
 * Last reply from: [Syde Joost](https://wordpress.org/support/users/joostvandevijver/)
 * Last activity: [4 years, 7 months ago](https://wordpress.org/support/topic/inventory-synced-but-incorrect/page/3/#post-15217690)
 * Status: resolved