Welcome to WebmasterWorld Guest from 54.147.20.131

Forum Moderators: coopster & jatar k

Message Too Old, No Replies

Can you get info from amazon by passing just an IBSN

Making amazon AWS script

     

Archbob

8:27 am on Feb 3, 2006 (gmt 0)

5+ Year Member



I want to create a completely customizable amazon AWS script. I've got this so far:

<snipped personal url, see TOS [webmasterworld.com]>

Now, it is dynamic but the problem is, its not automatically updated along with amazon. You have to manually enter all the info into a form, like price, title, etc. And you have to update them yourself with new prices and such. I couldn't find much in the amazon PHP developer section on amazon.com and I was wondering if there was a way I could just pass a IBSN to the amazon server and retrieve all the results from product info. That would make the script so much better.

I don't just want an RSS feed because I want to specify the exact products I wish to display in the categories which I define(not amazon categories, but categories that I create myself). I haven't found anything in PHP that actually does this.

[edited by: coopster at 2:54 pm (utc) on Feb. 3, 2006]
[edit reason] no personals please [/edit]

coopster

3:03 pm on Feb 3, 2006 (gmt 0)

WebmasterWorld Administrator coopster is a WebmasterWorld Top Contributor of All Time 10+ Year Member



Welcome to WebmasterWorld, Archbob.

I'm not certain, but perhaps this relative thread regarding Ebay and Amazon APIs Integration with PHP [webmasterworld.com] will give you some ideas or direction?

niels

3:58 pm on Feb 3, 2006 (gmt 0)

10+ Year Member



The operator for one product is "ItemLookup" you simply enter the isbn or asin and it fetches all data.

The url for that operator would be:

[webservices.amazon.com...]
&AWSAccessKeyId=[Your Access Key ID Here]
&Operation=ItemLookup
&ItemId=[An ASIN]

You should also read the amazon tos, price and availability information cant be older then 24 hours, so if you store it in a db make sure you refresh it every 24 hours.

I hope that helps a bit.

Archbob

8:42 pm on Feb 3, 2006 (gmt 0)

5+ Year Member



I'd just want to display the info straight from amazon. I'm guessing there's no way to do it without an Access Key?

niels

8:52 pm on Feb 3, 2006 (gmt 0)

10+ Year Member



Just get one by creating a account here:

[aws-portal.amazon.com...]

Its free and fruity.

edit: hope linking to amazon aws signup isnt a TOS no-no

Archbob

9:45 pm on Feb 3, 2006 (gmt 0)

5+ Year Member



Ok, I got one and I'm looking at this page now:
[amazon.com...]

However, I see all the parameters except the one I want: Price.

I'm looking at the Response group parameter hoping to find it now. You guys know which parameter it is. Parsing will not be much of a problem one I find the parameter.

niels

9:55 pm on Feb 3, 2006 (gmt 0)

10+ Year Member



Just parse the xml, price data is in there.

[webservices.amazon.com...]
&AWSAccessKeyId=[Your Access Key ID Here]
&Operation=ItemLookup
&ItemId=[An ASIN]

Maybe also look @ the ResponseGroup parameter, that defines the amount of data returned.

Archbob

10:04 pm on Feb 3, 2006 (gmt 0)

5+ Year Member



1M9S1GJNZWK2RPP4Y3FB0.0107078552246094TrueB0009PI6BQB0009PI6BQhttp://www.amazon.com/exec/obidos/redirect?tag=ws%26link_code=xm2%26camp=2025%26creative=165953%26path=http://www.amazon.com/gp/redirect.html%253fASIN=B0009PI6BQ%2526tag=ws%2526lcode=xm2%2526cID=2025%2526ccmID=165953%2526location=/o/ASIN/B0009PI6BQ%25253FSubscriptionId=009KXPFAGB44J3N05Q82Apparel

Thats what you get from the return. The price of the item at hand is $29.99 which is nowhere to be found in the return from file-get-content. I even tried response Large, and still it doesn't always have the price.

niels

10:25 pm on Feb 3, 2006 (gmt 0)

10+ Year Member



Dunno why that feed doesn't contain a price value, try it with another asin, if i remember correctly amazon has 2 price operators ListPrice and OurPrice, so look out for those.

Archbob

10:35 pm on Feb 3, 2006 (gmt 0)

5+ Year Member



Is my method right:
<?php
$var=file_get_contents("http://webservices.amazon.com/onca/xml?Service=AWSECommerceService&AWSAccessKeyId=009KXPFAGB44J3N05Q82&Operation=ItemLookup&ItemId=B0009PI6BQ");
print "$var<br>";
?>

What your seeing is var.

 

Featured Threads

Hot Threads This Week

Hot Threads This Month