Shopping Discussion

Using the Walmart Canada API to get inventory counts

  • Last Updated:
  • Aug 20th, 2017 11:04 am
Deal Addict
Aug 3, 2005
1336 posts
408 upvotes
kennyt18 wrote:
May 18th, 2017 10:01 pm
Thanks for the reply. I just tried this exact line:

stores=["1031","1200","1190","1086"]&products={"6000001842788":[{"sku":"10174150","upc":["60538888131"]}]}&csrfToken=9570b81021ab63bcf57a55f73dbbe444fedce2ef-1495156311281-ac6e6b7601505843c7b35e44

and it still failed. I got the same "Access Denied" message as per the screenshot.
Never mind, I forgot to toggle the "Use XHR". It is working now. Thank you.
I'll Keep It Short and Sweet. Family, Religion, Friendship ... These Are the Three Demons You Must Slay if You Wish to Succeed in Business
Newbie
May 15, 2017
92 posts
31 upvotes
It needs all three SKU, ITEM# and UPC to work. Putting one of them doesnt. Means you can't look up an item that isn't on website, but with someone posting reciept.
[OP]
Newbie
Apr 15, 2017
20 posts
22 upvotes
pc1705 wrote:
May 18th, 2017 11:15 pm
It needs all three SKU, ITEM# and UPC to work. Putting one of them doesnt. Means you can't look up an item that isn't on website, but with someone posting reciept.
Have you tried using an unrelated product ID with your receipt UPC?
Newbie
May 15, 2017
92 posts
31 upvotes
vintazh wrote:
May 18th, 2017 11:31 pm
Have you tried using an unrelated product ID with your receipt UPC?
Correct UPC with Random SKU works, however one store at a time. just FYI for everyone.
Deal Addict
User avatar
Dec 25, 2012
4124 posts
2397 upvotes
Toronto
Actually it seems like you can't check multiple stores at once, as the first store's result will be displayed for all other stores?

But if you use 1 store, it seems to work.

Second of all the string you posted is not for invisible glass spray, as product 6000001842788 is Great Value Dry Pasta, you are also missing SKU and UPC which is needed. Product ID doesn't even seem to be needed. Product you are checking is this? https://www.walmart.ca/en/ip/invisible- ... 0193974462

Here is my example: stores=["3013"]&products={"":[{"sku":"6000193974463","upc":["79316599564"]}]}&csrfToken=YourCustomToken

Code: Select all

{
: {
"online": [
  {
"maxRegularPrice": 7.98,
"minRegularPrice": 7.98,
"mapPrice": 0,
"minCurrentPrice": 6.97,
"maxCurrentPrice": 6.97,
"inventory": 4,
"sku": "6000193974463",
"clearance": false,
"offerId": "6000193974463",
"limited": false,
"reducedPrice": false,
"offerType": "1P",
"limitedStock": true,
"sellerId": "0",
"rollback": true,
"date": "",
"status": "Available",
"eligible": false,
"sellerName": "Walmart",
"asAdvertised": false
}
],
"stores": [
  {
"minRegularPrice": 7.98,
"maxRegularPrice": 7.98,
"minCurrentPrice": 6.97,
"maxCurrentPrice": 6.97,
"inventory": 8,
"sku": "6000193974463",
"clearance": false,
"limited": false,
"limitedStock": false,
"rollback": false,
"date": "",
"status": "Available",
"storeNumber": "3013",
"eligible": false,
"asAdvertised": false
}
],
"onlineSummary": {
"status": "Available",
"date": "",
"eligible": false,
"clearance": false,
"rollback": true,
"asAdvertised": false,
"limited": false,
"limitedStock": true,
"minRegularPrice": 7.98,
"maxRegularPrice": 7.98,
"minCurrentPrice": 6.97,
"maxCurrentPrice": 6.97
},
"storeSummary": {
"status": "Available",
"date": "",
"eligible": false,
"clearance": false,
"rollback": false,
"asAdvertised": false,
"limited": false,
"limitedStock": false,
"minRegularPrice": 7.98,
"maxRegularPrice": 7.98,
"minCurrentPrice": 6.97,
"maxCurrentPrice": 6.97
}
}
}
Basically says online inventory is 4 and store #3013 has 8
Deal Addict
User avatar
Dec 25, 2012
4124 posts
2397 upvotes
Toronto
pc1705 wrote:
May 18th, 2017 11:36 pm
Correct UPC with Random SKU works, however one store at a time. just FYI for everyone.
I just figured this out as well. Face With Tears Of Joy
[OP]
Newbie
Apr 15, 2017
20 posts
22 upvotes
zentro wrote:
May 18th, 2017 11:40 pm
I just figured this out as well. Face With Tears Of Joy
So that means we can check stock with just an UPC number?
Newbie
May 15, 2017
92 posts
31 upvotes
vintazh wrote:
May 18th, 2017 11:42 pm
So that means we can check stock with just an UPC number?
Yes. It appears to pull up correct price for an item with correct UPC and a random SKU.
Deal Addict
User avatar
Dec 25, 2012
4124 posts
2397 upvotes
Toronto
From what I can tell SKU gives you online inventory stock, and min/max price. Otherwise Store, UPC & an up to date csrfToken is all you need if you just want check store stock.

Correct me if I am wrong.
[OP]
Newbie
Apr 15, 2017
20 posts
22 upvotes
pc1705 wrote:
May 18th, 2017 11:48 pm
Yes. It appears to pull up correct price for an item with correct UPC and a random SKU.
That's great news! Especially for the guys hunting for the $200 Lenovo laptop.
Newbie
May 15, 2017
92 posts
31 upvotes
Type anything in sku #. a letter, or a number. It does not like a blank. So yes you can look up with UPC only + random character in SKU field

If there's a way to look up multiple stores that would be fantastic but one at a time isn't too bad.
Deal Addict
User avatar
Dec 25, 2012
4124 posts
2397 upvotes
Toronto
blank seems to work for me?

I think I just figured it out.

SKU is used for Online check
UPC is used for Store check
Newbie
May 15, 2017
92 posts
31 upvotes
Very weird. Now I can get results just by UPC. Well, if anyone is having issue of no results returning, just type something in SKU field, hope that helps.
Deal Addict
User avatar
Dec 25, 2012
4124 posts
2397 upvotes
Toronto
As far as automation for multiple stores, the only way I can think at the top of my head is to write an AutoHotKey, so a macro can check multiple stores from a list of your closest stores and maybe even output and format the results.

I'm sure it's also possible to just make an extension so it automatically does everything when you visit an item page, but this is a super long tedious & complicated thing to make.
[OP]
Newbie
Apr 15, 2017
20 posts
22 upvotes
I just tried this. It works! Just use blank values on everything except UPC and csrfToken.
On an unrelated note, do you guys have any idea why some stores have inventories of 1 and 2 but show "OutOfStock" as status? Others are out of stock as well but inventories of 0, which makes sense.

Top