Ich verwende die Amazon Product Advertising API PHP Class from Codediesel.Amazon Produkt Werbung API Lesen zuerst Angebot
Ich verwende die Funktion getItemByAsin
und verändert die ResponseGroup
zu Offers
, weil ich die IsEligibleForPrime
für das billigste Angebot erhalten möchten (siehe Amazon JSON response.
Da es mehr als 1 Angebot in der die Reaktion innerhalb des Tags offer
sind, ich weiß nicht, wie die ersten lesen
Hier ist, was eine exzellente Spielbarkeit wie folgt aussieht:.
<Item>
<ASIN>047061529X</ASIN>
<Offers>
<TotalOffers>2</TotalOffers>
<TotalOfferPages>1</TotalOfferPages>
<MoreOffersUrl>http://www.amazon.com/gp/offer-listing/047061529X/?SubscriptionId=AKIAI44QH8DHBEXAMPLE&ie=UTF8&tag=adrpik-20&creative=386001&camp=2025&linkCode=xm2 </MoreOffersUrl>
<Offer>
<OfferAttributes>
<Condition>New</Condition>
</OfferAttributes>
<OfferListing>
<OfferListingId>6vZH%2FR4dOoabV7sTSv3vC0Np5xK1c8MKOhAl5HYbCIJhxOLlJw1O2AM6mLYyVhjnI8s2gMkx7yq%2F%2BEC7yKPWkQTqhVhFBeUDm71EdpaYwrXpppfcAL1yPzyQFkOuK6MsK8aLPSNSWVs%3D </OfferListingId>
<Price>
<Amount>1025</Amount>
<CurrencyCode>USD</CurrencyCode>
<FormattedPrice>$10.25</FormattedPrice>
</Price>
<AmountSaved>
<Amount>974</Amount>
<CurrencyCode>USD</CurrencyCode>
<FormattedPrice>$9.74</FormattedPrice>
</AmountSaved>
<PercentageSaved>49</PercentageSaved>
<Availability>Usually ships in 1-2 business days</Availability>
<AvailabilityAttributes>
<AvailabilityType>now</AvailabilityType>
<MinimumHours>24</MinimumHours>
<MaximumHours>48</MaximumHours>
</AvailabilityAttributes>
<IsEligibleForSuperSaverShipping>0</IsEligibleForSuperSaverShipping>
<IsEligibleForPrime>1</IsEligibleForPrime>
</OfferListing>
</Offer>
<Offer>
<OfferAttributes>
<Condition>Used</Condition>
</OfferAttributes>
<OfferListing>
<OfferListingId>uXUlLeu7rH5t3ogkZJ%2Bd11tWCsdsj5kHhjoscRF1D1GuBuDwCyrz0XyR%2BTEOJO7PgpfwLjtX4ojhbXeHZgM0Br4DiWsPhNZTduzvYC8zLgG0z1e%2FgYiiuuR0wTyKqssY6ncHyVjZK1A%3D </OfferListingId>
<Price>
<Amount>1110</Amount>
<CurrencyCode>USD</CurrencyCode>
<FormattedPrice>$11.10</FormattedPrice>
</Price>
<AmountSaved>
<Amount>889</Amount>
<CurrencyCode>USD</CurrencyCode>
<FormattedPrice>$8.89</FormattedPrice>
</AmountSaved>
<PercentageSaved>44</PercentageSaved>
<Availability>Usually ships in 1-2 business days</Availability>
<AvailabilityAttributes>
<AvailabilityType>now</AvailabilityType>
<MinimumHours>24</MinimumHours>
<MaximumHours>48</MaximumHours>
</AvailabilityAttributes>
<IsEligibleForSuperSaverShipping>0</IsEligibleForSuperSaverShipping>
<IsEligibleForPrime>1</IsEligibleForPrime>
</OfferListing>
</Offer>
</Offers>
Wie kann ich die IsEligibleForPrime
von der ersten <Offer></Offer>
lesen?
Auf angeben, welches Element Sie bestellen möchten? Das billigste oder das erste Angebot? – Zl3n
Ich möchte den Inhalt von IsEigibleForPrime des ersten (günstigsten) Angebots bekommen, wo die Bedingung "neu" ist. – Paul
Ok, lass uns etwas versuchen – Zl3n