<?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: Lodestone</title>
    <description>The latest articles on DEV Community by Lodestone (@lodestone_shop).</description>
    <link>https://dev.to/lodestone_shop</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%2F4196977%2Fdaca4ba1-c725-4031-9f21-7774b1c24e03.png</url>
      <title>DEV Community: Lodestone</title>
      <link>https://dev.to/lodestone_shop</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/lodestone_shop"/>
    <language>en</language>
    <item>
      <title>I built a USDC checkout with no payment processor, ~400 lines of Python stdlib</title>
      <dc:creator>Lodestone</dc:creator>
      <pubDate>Tue, 20 Oct 2026 22:39:11 +0000</pubDate>
      <link>https://dev.to/lodestone_shop/i-built-a-usdc-checkout-with-no-payment-processor-400-lines-of-python-stdlib-4heh</link>
      <guid>https://dev.to/lodestone_shop/i-built-a-usdc-checkout-with-no-payment-processor-400-lines-of-python-stdlib-4heh</guid>
      <description>&lt;p&gt;Most "accept crypto" options either want KYC or take a cut. For a small digital shop I wanted neither, so here's the design:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. A unique amount per checkout.&lt;/strong&gt; A 15 USDC product becomes 15.000437 USDC. The 1–999 micro-unit suffix is the order ID, so there are no accounts, no memo fields and no per-order wallets.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Watch the chain with eth_getLogs.&lt;/strong&gt; Poll the USDC contract on Base for &lt;code&gt;Transfer(from, to=shop, value)&lt;/code&gt; logs every few seconds, using a couple of public RPCs as fallbacks (some don't serve getLogs). When a log value matches a pending session, mark it paid.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Tx-hash fallback.&lt;/strong&gt; If the poller misses it, the buyer pastes the hash and the server checks the receipt directly.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. HMAC download tokens.&lt;/strong&gt; A paid session gets a 24h signed link. SQLite holds the sessions. Nothing else.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;5. Discounts without double-dipping.&lt;/strong&gt; A code's uses are counted only from &lt;em&gt;paid&lt;/em&gt; sessions, server-side, and the discount is baked into the unique amount.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;6. Optional emailed receipt.&lt;/strong&gt; The buyer can enter an email. It's used once for the link and receipt, then nulled in the DB.&lt;/p&gt;

&lt;p&gt;Gotchas: public RPC getLogs limits, 6-decimal USDC, race conditions on limited codes, and QR codes (EIP-681 &lt;code&gt;ethereum:&amp;lt;token&amp;gt;@8453/transfer?address=…&amp;amp;uint256=…&lt;/code&gt;).&lt;/p&gt;

&lt;p&gt;It's running the Lodestone shop (templates, Notion, spreadsheets, dev kits): &lt;a href="https://jackiscool.com/shop/" rel="noopener noreferrer"&gt;https://jackiscool.com/shop/&lt;/a&gt;. LAUNCH10 takes 10% off for the first 3 orders if you want to watch it work.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>python</category>
      <category>crypto</category>
      <category>sideprojects</category>
    </item>
  </channel>
</rss>
