PerlさんPerlくん
[perl][module][amazon]similarを取得する
最終更新:
atwikimyj
-
view
(1)uaを作る
$ua = Net::Amazon->new(
token => '02BX0Y9XTKT1XZ7F7882',
affiliate_id => "mturbo-22",
locale => 'jp',
cache => $cache,
);
token => '02BX0Y9XTKT1XZ7F7882',
affiliate_id => "mturbo-22",
locale => 'jp',
cache => $cache,
);
(2)asinから似た商品を出す
#似た商品
my $req = Net::Amazon::Request::Similar->new(similar => $asin ,
type => 'lite',
page => 1,offer => 'All',
) ;
type => 'lite',
page => 1,offer => 'All',
) ;
(3)値の取得はpropertiesで行う。
for ($req -> properties)
{
my $Catalog= $_ -> Catalog
}
{
my $Catalog= $_ -> Catalog
}