I would like to know if there is an API I can use to get a LinkShare merchant domain URL.
The merchant search endpoint only returns their uid
and name
.
Asked
Active
Viewed 3,291 times
2

Shashank Agrawal
- 25,161
- 11
- 89
- 121

Roch
- 21,741
- 29
- 77
- 120
2 Answers
2
According to the Linkshare help docs you can get a list of default URLs for all advertisers in your program (by joining data from two APIs), but those will still be affiliate links on Linkshare redirect domains. You would then need to write a script to visit those links and return the final destination URL, then grab the root domain of the URL.
Steps:
- Follow the instructions here: http://helpcenter.linkshare.com/publisher/questions.php?questionid=1030
- Write a script in your language of choice to cURL the affiliate link and grab
curl_getinfo(curl_init(), CURLINFO_EFFECTIVE_URL);
to see where it's redirecting to. - Parse the response with a RegExp to grab just the root domain like
http[s]?://([^/]+)

jonaz
- 2,096
- 1
- 17
- 30
-
It's a bit of a hack, but I guess I don't have any other solution ;) – Roch Aug 12 '13 at 07:47
-
1If you have budget, your life might be simpler if you just consume feeds from [PopShops](http://www.popshops.com/) or [ForMeToCoupon](http://www.formetocoupon.com/). Those guys both have APIs in the format of your choice that deliver everything you need, but you need to pay for the service. – jonaz Aug 13 '13 at 19:41
0
This is a duplicate of this Stack Overflow question this is what worked for me:
The following URL will allow you to get a list of merchants with data that you have permission to access without the need to login. It will return an XML list of your merchants:
http://findadvertisers.linksynergy.com/merchantsearch?token=YOUR_LINKSHARE_ACCESS_TOKEN

Kmeixner
- 1,664
- 4
- 22
- 32