eBay API: get watch count for the particular item - ebay-api

I want to retrieve a number of watchers for the particular item using eBay API. I tried setting IncludeWatchCount to true in GetSingleItem request, but it appears that it works only for the seller of the item. Is it possible to get the number of watchers without being a seller?

I literally just joined in on SO with a new account because I lost my previous email with which I had the old one just to answer your question.
Anyway, If you call findItemsAdvanced, under listingInfo there is a watchCount field. It only works with findItemsAdvanced and not with any other.
[NOTE] The watchCount variable is not in the documentation. You should dump the response given by findItemsAdvanced, find listingInfo and it will be there

Related

ebay finding api finditemsbykeywords pagination problem

I tried the following calls:
https://svcs.ebay.com/services/search/FindingService/v1?X-EBAY-SOA-OPERATION-NAME=findItemsByKeywords&SERVICE-VERSION=1.13.0&keywords=waschbecken&RESPONSE-DATA-FORMAT=JSON&GLOBAL-ID=EBAY-DE&outputSelector(0)=ItemSpecifics&paginationInput.entriesPerPage=100&paginationInput.pageNumber=2
then on the ebay API explorer for the post request body,
<findItemsByKeywordsRequest xmlns="http://www.ebay.com/marketplace/search/v1/services">
<keywords>waschbecken</keywords>
<paginationInput>
<entriesPerPage>100</entriesPerPage>
<pageNumber>2</pageNumber>
</paginationInput>
</findItemsByKeywordsRequest>
but I do not get 100 searchResult count per page, in Postman I get 32 searchResult and in API explorer 56; furthermore 2nd page forward I do not get any searchResult count, I am trying to understand is there something wrong that I am writing in the call or there is some another problem or any parameter I am missing.
Thanks for the help.
I am also running into this problem. I am guessing that the pagination results are for the entire store, but not for the search by keywords....Seems like they dropped the ball on this.
Sorry, I did not update on the question, I forgot about it.
The problem was not with the pagination, the problem is the variants.
Simply explained, the output of the query doesn't count for the variants listed on the Ebay search by the same seller. If you have from a same seller the same product with the different variant, the query does not show the variants from those product from the same seller just different variant, as it would if you do an ebay search.
The mechanism of the query is different as that of the product search on Ebay.

How to get maximum number of tweets on an user

i have this code
("https://api.twitter.com/1.1/statuses/user_timeline.json?screen_name=".$twitteruser.'&count=500'
But it is giving me only 200 records , I found in twitter document that it will give 3200 tweets.Is i am doing wrong what should i do to get that much tweet.
Since there is no page system in twitter 's API, to go throught timelines, you must use the "max_id" parameter.
Here is an helpful link that explains how to work with timelines with nice illustrations: https://dev.twitter.com/rest/public/timelines.
Edit: here is how you do it.
"To use max_id correctly, an application’s first request to a timeline endpoint should only specify a count."
Make your request "https://api.twitter.com/1.1/statuses/user_timeline.json?screen_name=".$twitteruser.'&count=500 (you can put 200).
Then when you get all your data, " keep track of the lowest ID received" and use it as parameter (the same way you do for the count) for your next request. it will give you the 200 next posts with a lower id than the one you specified. Do it again until you reach the end.

eBay API change currency of returned price

Is there a way to get an item in another currency using the eBay API?
Very simple. All you have to do is change the site ID parameter. Since you didn't specify a language, I'm going to assume you're doing this HTTP-GET and just parsing the XML. The same principles will apply regardless of how you do it, programatically or not.
For a URL:
"http://open.api.ebay.com/shopping"
?callname=GetSingleItem
&responseencoding=XML
&appid=[APPID]
&siteid=2 <------------This, for example, is Canada's siteid. 0 is US. This will change the currency returned under < ConvertedCurrentPrice>
&version=839
&ItemID=181195344321
Put it all together and you get this copy/paste-friendly "http://open.api.ebay.com/shopping?callname=GetSingleItem&responseencoding=XML&appid=[APPID]&siteid=2&version=839&ItemID=181195344321"
Make sure to use your app ID as the parameter.
You can use this call for currency change:
Currency type can be changed in Ebay while listing an item using Add Item call in Ebay's trading API.
http://developer.ebay.com/devzone/xml/docs/Reference/eBay/extra/additms.rqst.additmrqstcntnr.itm.crrncy.html
Thanks CedCommerce
You can and it's actually very simple. You can use the Shopping API GetSingleItem.
Depending on what currency you are interested in, all you have to do is change the SiteID on which you are making the call. For example, if you want to get the price in EUR, you can set the SiteID to 3(UK), or 77(Germany). You will also have to set the IncludeSelector to "Details". This way, you will get a response that will contain the following fields.
<ConvertedCurrentPrice currencyID="GBP">68.55</ConvertedCurrentPrice>
<CurrentPrice currencyID="USD">92.9</CurrentPrice>
where the CurrentPrice is the original price of the listing, on the ebay site the listing was made, and the ConvertedCurrentPrice is the price of the listing on the site that corresponds to the SiteID you supplied.
You can see a full list of SiteIDs with the currencies they are using here

Instagram tag search - filter for images and tags after a certain time or id

I am using the Instagram API to fetch a list of photos tagged with a certain hashtag. I've got a real-time subscription set up so it will notify me whenever new photos have been posted. However, I have to fetch the new results myself.
My problem: When I request the list of recently tagged photos, I get a large list and I don't want to process all of the results in the recent list every time I do this. The api docs say I can pass these optional parameters, but they seem counter-intuitive. They seem to be the opposite of what I would expect:
MIN_ID Return media before this min_id.
MAX_ID Return media after this max_id.
If I keep track of the most recent media id I've seen in my recent requests, how do I construct my next request to only return results newer than that id?
I've posted two photos with a test hashtag. When I use the following url (with my real access_token in it), I get back a json response listing both of those photos:
https://api.instagram.com/v1/tags/weirdtest/media/recent?access_token=xxx
The two photos have these ids:
221201236060507271_179249322
221190263853517857_179249322
How do I construct a query that returns only the newer of those two photos?
Tack the most recent ID you've seen on the end, using the MAX_ID request parameter:
https://api.instagram.com/v1/tags/weirdtest/media/recent?access_token=xxx&MAX_ID=221201236060507271_179249322
This should tell Instagram, *"The most recent photo I've seen is 221201236060507271_179249322, return only newer photos"*.

Is the checkin object's type=mayorship notification appears fickle?

I have some questions about 4sq's API.
Chceckin object obtained by checkins/add endpoint's response sometimes has mayorship field and at other times not.
And mayorship's checkins count field seems not reliable (often appears count 0, but actual count is 2).
Is it so?
thanks.
The notification only contains mayor information if the user is somewhat close to being able to claim the mayorship.
As for incorrect checkin counts, you'll need to provide an example response for us to be able to debug.