<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Bobonajaf</title>
    <description>The latest articles on DEV Community by Bobonajaf (@bobonajaf_84).</description>
    <link>https://dev.to/bobonajaf_84</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3997260%2F57e0230d-344e-4e80-ac9a-0c7ba64c4039.png</url>
      <title>DEV Community: Bobonajaf</title>
      <link>https://dev.to/bobonajaf_84</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/bobonajaf_84"/>
    <language>en</language>
    <item>
      <title>How I Automated Amazon's "Request a Review" Button with the SP-API</title>
      <dc:creator>Bobonajaf</dc:creator>
      <pubDate>Mon, 22 Jun 2026 16:07:13 +0000</pubDate>
      <link>https://dev.to/bobonajaf_84/how-i-automated-amazons-request-a-review-button-with-the-sp-api-115g</link>
      <guid>https://dev.to/bobonajaf_84/how-i-automated-amazons-request-a-review-button-with-the-sp-api-115g</guid>
      <description>&lt;p&gt;Every Amazon order has a "Request a Review" button in Seller Central. When you click it, Amazon sends a standardised email to the buyer asking for a product review and seller feedback. It's compliant, it works, and it's tedious at scale.&lt;/p&gt;

&lt;p&gt;I built &lt;a href="https://reevy.app" rel="noopener noreferrer"&gt;Reevy&lt;/a&gt; to automate this. Here's how the SP-API Solicitations endpoint works and what I learned building around it.&lt;/p&gt;

&lt;h2&gt;
  
  
  The endpoint
&lt;/h2&gt;

&lt;p&gt;Amazon's Selling Partner API has a Solicitations section. The key call:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight http"&gt;&lt;code&gt;&lt;span class="err"&gt;POST /solicitations/v1/orders/{orderId}/solicitations/productReviewAndSellerFeedback
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This triggers the exact same review request as clicking the button manually. Amazon handles the email content, language localisation, and delivery. You just tell it which order.&lt;/p&gt;

&lt;h2&gt;
  
  
  Authentication
&lt;/h2&gt;

&lt;p&gt;SP-API uses a two-layer auth system:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Login with Amazon (LWA)&lt;/strong&gt; — OAuth2 flow to get a refresh token from the seller&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AWS IAM&lt;/strong&gt; — your app signs requests with AWS credentials (STS AssumeRole)&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The seller authorises your app once. You store their refresh token, exchange it for access tokens as needed, and sign every API call with your IAM role. Standard OAuth + AWS SigV4 — straightforward if you've done either before, a bit of a maze if you're new to both.&lt;/p&gt;

&lt;h2&gt;
  
  
  Eligibility rules
&lt;/h2&gt;

&lt;p&gt;You can't request a review for every order. Amazon enforces:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Timing window&lt;/strong&gt;: 5–30 days after delivery. Too early or too late and the API returns a 403.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;One request per order&lt;/strong&gt;: Call it twice and you get a 403 on the second attempt.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Order status&lt;/strong&gt;: Must be delivered (not shipped, not cancelled, not returned).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This means you need to track delivery dates and manage a queue of eligible orders. I poll the Orders API daily, filter by delivery date, and queue orders that fall within my configured window (default: 7–14 days post-delivery).&lt;/p&gt;

&lt;h2&gt;
  
  
  Rate limits
&lt;/h2&gt;

&lt;p&gt;The Solicitations endpoint has a rate limit of 1 request per second per seller, with a burst of 5. At scale (hundreds of orders per day per seller), this means you need to throttle your queue and handle 429 responses gracefully.&lt;/p&gt;

&lt;p&gt;My approach: a cron job processes the queue every hour, sending requests with a 1.2-second delay between calls. Failed requests (429s, 5xx errors) go back in the queue with exponential backoff.&lt;/p&gt;

&lt;h2&gt;
  
  
  Multi-marketplace
&lt;/h2&gt;

&lt;p&gt;A single seller often sells on Amazon US, UK, DE, FR, IT, ES, and more. Each marketplace has its own SP-API endpoint:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;North America: &lt;code&gt;sellingpartnerapi-na.amazon.com&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Europe: &lt;code&gt;sellingpartnerapi-eu.amazon.com&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Far East: &lt;code&gt;sellingpartnerapi-fe.amazon.com&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The seller authorises once per region, and you route API calls to the correct endpoint based on the marketplace. Orders from Amazon.de go through the EU endpoint; orders from Amazon.com go through NA.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I'd do differently
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Don't poll the Orders API on a schedule.&lt;/strong&gt; Use SP-API notifications (SQS) to get real-time order updates. I started with polling because it was simpler, but at scale the notification approach is more efficient and reduces API calls.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Store raw API responses.&lt;/strong&gt; When something goes wrong (and it will — Amazon's API has occasional inconsistencies), having the raw response makes debugging much faster.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Test with sandbox first.&lt;/strong&gt; SP-API has a sandbox environment. Use it before hitting production, especially for the Solicitations endpoint where a bad call can burn a seller's one-per-order request.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The product
&lt;/h2&gt;

&lt;p&gt;This became &lt;a href="https://reevy.app" rel="noopener noreferrer"&gt;Reevy&lt;/a&gt; — a standalone tool that automates the Request a Review button across all 21 Amazon marketplaces. Built with PHP and MariaDB, Stripe for billing, deployed on Krystal hosting. Listed in the Amazon Selling Partner Appstore.&lt;/p&gt;

&lt;p&gt;If you're building on Amazon's SP-API and have questions about the auth flow, rate limiting, or the Solicitations endpoint specifically — happy to answer in the comments.&lt;/p&gt;

</description>
      <category>aws</category>
      <category>api</category>
      <category>php</category>
      <category>sass</category>
    </item>
  </channel>
</rss>
