Walmart MWS API not returning nextCursor - node.js

After checking the Walmart Markeptlace API to retrieve all the items in the catalog, you can see that it will return:
errors (array of objects)
itemResponse (array of objects)
additionalAttributes (object)
totalItems (integer)
nextCursor (string)
In my case I have over 2000 items in the catalog, but by default it will just return 20 items with a nextCursor so I can retrieve the next items. Unfortunately, i'm not getting my nextCursor in the response. I tried contacting walmart and been waiting for a reply over 2 weeks, but never got a single reply.
This is what my response looks like:
Is there anybody running into the same issue as me? I really don't know what to do in order to retrieve the nextCursor.

Walmart's documentation is unclear, and contradictory. They could use some good examples. I was having the same problems as you were.
What worked for me was explicitly passing nextCursor=* for the first page.
I know the documentation says that's the default, but that doesn't seem to be the case.
The response will have the nextCursor value for the next page.

Related

GetMyeBaySelling API does not return Unsold items even though they exist

Please bear with me because I'm new to eBay APIs but basically I'm trying to:
Get a list of item IDs which are Active
Get a list of item IDs which are Unsold
So the problem is pretty straightforward and I'm currently using the GetMyeBaySelling API call with an XML input that looks like this:
<?xml version="1.0" encoding="utf-8"?>
<GetMyeBaySellingRequest xmlns="urn:ebay:apis:eBLBaseComponents">
<RequesterCredentials>
<eBayAuthToken>{eBayAuthToken}</eBayAuthToken>
</RequesterCredentials>
<DetailLevel>ReturnAll</DetailLevel>
</GetMyeBaySellingRequest>
Again, very simple. I understand that I will get the list of all Active items, the list of all Unsold/Sold items, etc. because I've set the <DetailLevel> field to ReturnAll in the input XML above
The problem is that for some reason, for one account that I'm testing this call on, it doesn't return the list of unsold items, as in, it doesn't return the container in the XML response, I'm talking about this one:
<UnsoldList> .... </UnsoldList>
This is weird because that one particular eBay account has more than 20 unsold items in it
Now this is where things get really weird, if I tested the API call on other eBay accounts, it works just fine and returns the list of all Unsold items with no problem 😕
Did I do something wrong here or is there some kind of bug in this eBay API call?
SOLVED!
It turns out that we have to specify
<DurationInDays>{numberOfDays}</DurationInDays>
Where {numberOfDays} is an integer value which represents how far back in the past do the unsold listings we want to extract have to be?
In this case, we can specify 60, which is the maximum number of days accepted by the GetMyeBaySelling API to indicate that we want all unsold listings which ended within the past 60 days.
So what happened was that on this one particular account, all of the unsold listings ended on 5th of December 2020. Whatever the default {numberOfDays} for DurationInDays value set by eBay is, it's clearly not big enough to cover these listings which ended on 5th of December 2020. Hence, by specifying it to 60 days, I got all of the unsold listings just fine :)
So for whoever out there who's facing a similar problem, remember this field, it could very well fix the problem that you have (if it's anything similar to mine).

Instagram max_id not working

We have been using below end point to fetch the Instagram feeds
https://www.instagram.com/saintgobaingroup/?__a=1&max_id=
Later, for further feeds we use to fill the max_id parameter with last entry's id. It was working fine but now Instagram end point seems to have change the response format.
We are able to update the piece of code to match the response. However the max_id parameter seems to be not working now.
We are getting same 12 records even when we have more than 400 records. We are properly updating the max_id parameter like we use to do earlier. But we are unable to get further records only 12 records being getting repeated.
Any idea on this?
Note : As of now we're not focusing on using the Instagram API. We would like to get it done with end point ?__a=1
The answer doesn't work with ?__a=1, but it does get you pagination here: https://stackoverflow.com/a/49266320/929540

Outlook REST API: How to page through $search results, when searching for messages

I have troubles paging through message search results with the rest API.
I have a request looking like this:
outlook.office.com/api/v2.0/me/messages/?$search="deni"
the request returns a proper result and also includes a 'next page' looking like this:
"#odata.nextLink": "https://outlook.office.com/api/v2.0/me/messages/?%24search=%22deni%22&%24top=10&%24skiptoken=aT01NjMzYWQ3OS02MmJjLTQ5ZDEtODg4ZC0zYTgwNDlhOTY3Nzkmcz0xMA%3d%3d"
I guess this link is URL encoded so I URL decode it to get this:
outlook.office.com/api/v2.0/me/messages/?$search="deni"&$top=10&$skiptoken=aT01NjMzYWQ3OS02MmJjLTQ5ZDEtODg4ZC0zYTgwNDlhOTY3Nzkmcz0xMA==
However, when i try to make request with the next link I'm getting 405 Method Not Allowed with the following error:
"The OData request is not supported."
I've tried it in the sandbox as well (oauthplay.azurewebsites.net) - same result. What could it be that I am doing wrong. What is the right way to page through the search results?
I know that there is a limit of 250 messages that could be searched, but this is not the case here. I have 10 and I am trying to read the next 10.
Of course I have tried paging with the $skip and $top parameters, but $kip is not supported together with $search.
I can't seem to find a definitive answer in the documentation on how to page through search results and is it possible at all.
Thanks to anyone willing to help.

Amazon MWS Api usage

I am using "http://www.amazon.de/dp/{ASIN}" to get product info.
But after getting response it doesn't return product "SellerSKU"
Is there any way that I can get "SellerSKU" of a product specified by "ASIN"?
I also had same situation.
And I found that there is only some limited way to get it.
https://mws.amazonservices.com/FulfillmentInventory/2010-10-01?Action=ListInventorySupply
ListInventorySupply api of Fulfillment Inventory lists returns information about the availability of a seller's inventory.
Request parameter includes SellerSKUs, QueryStartDateTime, MarketplaceId, ResponseGroup
Here you can omit SellerSKUs, and you can pass QueryStartDateTime.
Then you will get InventorySupplyList including SellerSKU and ASIN matches.
You should find the product's SellerSKU in this list.
But the problem is that it returns only available inventory list.
It will not work when product you are finding is not in available inventory list.
In this case you should make the user manually add SellerSKU in your application.
For more information, please take a look at http://docs.developer.amazonservices.com/en_US/fba_inventory/FBAInventory_ListInventorySupply.html
Hope this would help you.

eBay API in Sandbox returns response as a continuous string

Just started using the eBay API.
I created some products and purchased it with another Sandbox account.
In the Sellers account, I can see 2 products under the 'Sold' section.
I am using the GetOrders API call to fetch the orders/sales.
And in the response I am getting a continuous string.
2013-04-20T07:28:55.919ZSuccess819E819_CORE_API_15993720_R111false260765010Completed0.038.00.0NoPaymentFailure2013-04-09T07:15:25.000ZPayPalCompletefalse0.0false0.0StandardShippingFromOutsideUS4.01false510103falseBuyer2013-04-09T07:15:25.000ZPayPalTest UseraddresscityWAUSUnited States1 800 111 1111981026806769eBayStandardShippingFromOutsideUS4.034.038.0xxx.yyy#gmail.com1012013-04-06T11:32:41.000Z110115066261US1000New1None023.0112.51USeBay2.00.0110115066261-0xxx.yyy#gmail.com1022013-04-09T07:13:20.000Z110115066411US1000Brand New1None2705398200111.078.41USeBay2.00.0110115066411-27053982001testuser_xxxyyy252013-04-09T07:15:25.000ZfalsenY+sHZ2PrBmdj6wVnY+sEZ2PrA2dj6wFk4GhCpKBpwidj6x9nY+seQ==None10011
I don't see any labels associated with the values, like date = 2013-04-09T07:15:25.000Z
And why is it not formatted?
Any help would be appreciated.
Thank you.
as i thought your problem is when you echo the answer, your browser will automatically set header as html and that cause your view. so just add xml header at the top of the file (rember to not echo anything else but one xml otherwise you will get header error).
header ("Content-Type:text/xml");
About your question about filter by time your response i would definitly go for NumberOfDays as i saw you used. Otherwise you can either add ModTimeFrom and ModTimeTo for last x time modified orders or CreateTimeFrom and CreateTimeTo to check new orders entered.

Resources