<?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: Mr Hamlin</title>
    <description>The latest articles on DEV Community by Mr Hamlin (@mr_hamlin).</description>
    <link>https://dev.to/mr_hamlin</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%2F3815462%2F608d44c9-7dbf-4f19-bf5c-211f31b318fb.jpg</url>
      <title>DEV Community: Mr Hamlin</title>
      <link>https://dev.to/mr_hamlin</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mr_hamlin"/>
    <language>en</language>
    <item>
      <title>I Ship Paid APIs in a Weekend. Here's the Exact Stack I Use Every Time.</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Sat, 20 Jun 2026 00:10:11 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/i-ship-paid-apis-in-a-weekend-heres-the-exact-stack-i-use-every-time-5166</link>
      <guid>https://dev.to/mr_hamlin/i-ship-paid-apis-in-a-weekend-heres-the-exact-stack-i-use-every-time-5166</guid>
      <description>&lt;p&gt;I've shipped three paid API products in the past six months. Each one took a weekend to reach a working, billable state — users signing up, generating API keys, making authenticated requests, and paying me through Stripe.&lt;/p&gt;

&lt;p&gt;Not because I'm fast. Because the infrastructure is the same every time.&lt;/p&gt;

&lt;p&gt;Auth is the same. API key management is the same. Stripe billing is the same. Rate limiting, usage tracking, the dashboard — all the same. The only thing that changes is the business logic behind the endpoints.&lt;/p&gt;

&lt;p&gt;After the third time wiring Stripe webhooks to Supabase to API key validation, I wrote down the pattern. Here it is.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Stack
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Layer&lt;/th&gt;
&lt;th&gt;Tool&lt;/th&gt;
&lt;th&gt;Cost&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Runtime&lt;/td&gt;
&lt;td&gt;Node.js + Express&lt;/td&gt;
&lt;td&gt;Free&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Auth &amp;amp; Database&lt;/td&gt;
&lt;td&gt;Supabase&lt;/td&gt;
&lt;td&gt;Free tier&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Billing&lt;/td&gt;
&lt;td&gt;Stripe&lt;/td&gt;
&lt;td&gt;2.9% + 30¢ per txn&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Rate Limiting&lt;/td&gt;
&lt;td&gt;Redis (Upstash)&lt;/td&gt;
&lt;td&gt;Free tier&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Dashboard&lt;/td&gt;
&lt;td&gt;React + Vite&lt;/td&gt;
&lt;td&gt;Free&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Deployment&lt;/td&gt;
&lt;td&gt;Railway&lt;/td&gt;
&lt;td&gt;$5/month&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Total cost at launch: &lt;strong&gt;$5/month&lt;/strong&gt;. Everything else is free until you have paying customers.&lt;/p&gt;

&lt;p&gt;Why these specific tools? I've tried the alternatives. Supabase beats Firebase for API businesses because relational data (users → keys → usage logs) is natural in Postgres and painful in document stores. Express beats Next.js for API servers because you don't need SSR, file-based routing, or React Server Components — you need a fast request-response pipeline. Upstash Redis beats Postgres for rate limiting because checking a counter needs to be sub-millisecond, not 5-20ms.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Middleware Chain
&lt;/h2&gt;

&lt;p&gt;This is the architecture pattern that makes everything work. Every API request passes through a chain of middleware before it hits your business logic:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Request arrives
  → validateApiKey    (reject if invalid)
  → rateLimit         (reject if over per-minute limit)
  → trackUsage        (reject if monthly quota exceeded)
  → YOUR LOGIC        (do the actual work)
Response sent
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;By the time your route handler runs, you &lt;strong&gt;know&lt;/strong&gt; three things: the key is valid, the request is within rate limits, and the monthly quota hasn't been exceeded. Your business logic never checks any of this. The middleware guarantees it.&lt;/p&gt;

&lt;h2&gt;
  
  
  API Keys: The Pattern Everyone Skips
&lt;/h2&gt;

&lt;p&gt;Most tutorials use Bearer tokens for API auth and move on. That doesn't work for a business. Your customers need to generate keys from a dashboard, name them, revoke them, and see when they were last used.&lt;/p&gt;

&lt;p&gt;The security model matters:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Never store raw keys.&lt;/strong&gt; Store a SHA-256 hash. When a request comes in, hash the provided key and look up the hash.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Show the key once.&lt;/strong&gt; After generation, you only show a masked preview like &lt;code&gt;sk_live_abc...xyz&lt;/code&gt;. Lost key? Generate a new one.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Use a recognizable prefix.&lt;/strong&gt; &lt;code&gt;sk_live_&lt;/code&gt; tells GitHub's secret scanning that this is a credential. A leaked prefixed key gets caught before it causes damage.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nx"&gt;crypto&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;crypto&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;PREFIX&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;sk_live_&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;generateApiKey&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;random&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;crypto&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;randomBytes&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;32&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;toString&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;hex&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;raw&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;PREFIX&lt;/span&gt;&lt;span class="p"&gt;}${&lt;/span&gt;&lt;span class="nx"&gt;random&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;hash&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;crypto&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;createHash&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;sha256&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;raw&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;digest&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;hex&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;raw&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;hash&lt;/span&gt; &lt;span class="p"&gt;};&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;256 bits of entropy. The same pattern Stripe and OpenAI use.&lt;/p&gt;

&lt;h2&gt;
  
  
  Rate Limiting: The Sliding Window
&lt;/h2&gt;

&lt;p&gt;A fixed window rate limiter resets at the top of every minute, which means a customer can send their full quota at 0:59 and again at 1:01 — effectively doubling their rate. The sliding window counts the actual last 60 seconds from &lt;em&gt;right now&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Four Redis commands, one pipeline, one network round-trip:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;checkRateLimit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;apiKeyId&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;maxPerMinute&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;key&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;`ratelimit:&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;apiKeyId&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;now&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Date&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;windowStart&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;now&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="mi"&gt;60000&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;pipe&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;redis&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;pipeline&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
  &lt;span class="nx"&gt;pipe&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;zremrangebyscore&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;windowStart&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="c1"&gt;// remove old&lt;/span&gt;
  &lt;span class="nx"&gt;pipe&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;zadd&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;now&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;now&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;              &lt;span class="c1"&gt;// add current&lt;/span&gt;
  &lt;span class="nx"&gt;pipe&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;zcard&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;                            &lt;span class="c1"&gt;// count window&lt;/span&gt;
  &lt;span class="nx"&gt;pipe&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;expire&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;key&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;                       &lt;span class="c1"&gt;// auto-cleanup&lt;/span&gt;

  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;results&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;pipe&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;exec&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;count&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;results&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;allowed&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;count&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;=&lt;/span&gt; &lt;span class="nx"&gt;maxPerMinute&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;remaining&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;max&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;maxPerMinute&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nx"&gt;count&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
  &lt;span class="p"&gt;};&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then set the standard headers on every response — not just 429s:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;X-RateLimit-Limit&lt;/code&gt; — max per minute for this tier&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;X-RateLimit-Remaining&lt;/code&gt; — requests left in window&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;X-RateLimit-Reset&lt;/code&gt; — when the window resets&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Your API consumers use these headers to implement client-side backoff. The good ones slow down before they hit the wall.&lt;/p&gt;

&lt;h2&gt;
  
  
  Stripe Billing: The Four Webhooks That Matter
&lt;/h2&gt;

&lt;p&gt;Stripe sends dozens of event types. You need four:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;&lt;code&gt;checkout.session.completed&lt;/code&gt;&lt;/strong&gt; — customer paid. Create the subscription record, upgrade their tier, update all their API keys to the new limits.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;&lt;code&gt;customer.subscription.updated&lt;/code&gt;&lt;/strong&gt; — plan change or renewal. Look up the new price, determine the tier, update the database.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;&lt;code&gt;customer.subscription.deleted&lt;/code&gt;&lt;/strong&gt; — cancellation. Downgrade to free tier.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;&lt;code&gt;invoice.payment_failed&lt;/code&gt;&lt;/strong&gt; — card declined. Flag the account, notify the user.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The critical gotcha: Stripe signs webhooks against the &lt;strong&gt;raw request body&lt;/strong&gt;. If Express parses the body into JSON first, the signature verification fails. Mount your webhook route with &lt;code&gt;express.raw()&lt;/code&gt; &lt;em&gt;before&lt;/em&gt; &lt;code&gt;express.json()&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// This line MUST come before express.json()&lt;/span&gt;
&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;use&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;/billing/webhook&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;express&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;raw&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;application/json&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="p"&gt;}));&lt;/span&gt;
&lt;span class="nx"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;use&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;express&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I lost two hours to this bug on my first API. You don't have to.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Weekend Timeline
&lt;/h2&gt;

&lt;p&gt;Here's how I actually spend the weekend:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Friday evening:&lt;/strong&gt; Set up the project, install deps, create Supabase project, get a health check endpoint running. 1 hour.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Saturday morning:&lt;/strong&gt; Auth routes, API key system, validation middleware, first authenticated API call. 3 hours.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Saturday afternoon:&lt;/strong&gt; Rate limiting in Redis, Stripe billing with all four webhook handlers. 3 hours.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Sunday morning:&lt;/strong&gt; Usage tracking, React dashboard with five pages (login, overview, keys, usage, billing). 2 hours.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Sunday afternoon:&lt;/strong&gt; Deploy to Railway, custom domain, write docs, post about it. 2 hours.&lt;/p&gt;

&lt;p&gt;Nine hours of building. A live, paid API on the internet.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Learned
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Price higher than you think.&lt;/strong&gt; At $9/month you need 111 customers to make $1,000. At $29/month you need 35. At $79/month you need 13. Fewer customers = less support = more time building.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The free tier is a conversion mechanism.&lt;/strong&gt; A developer integrates your API, their project succeeds, they hit the limit, they upgrade. By then they've written code against your endpoints. Switching costs are real.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Good docs beat good marketing.&lt;/strong&gt; A developer who can integrate in five minutes becomes a customer. A developer who has to email you a question probably doesn't.&lt;/p&gt;




&lt;p&gt;I wrote the full process — all twelve chapters, every code file, the complete middleware chain, the dashboard, deployment, and launch strategy — into a book:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;a href="https://brenthamlin.gumroad.com/l/ship-api-weekend" rel="noopener noreferrer"&gt;The Solo Developer's Guide to Shipping a Paid API in a Weekend&lt;/a&gt;&lt;/strong&gt; — 82 pages, $29, every line of code is production code.&lt;/p&gt;

&lt;p&gt;If you've been sitting on an API idea waiting for the right time to build the billing infrastructure, the right time is this weekend.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;I'm Brent Hamlin. I build paid APIs and write about the stack behind them. Find me at &lt;a href="https://dev.to/mr_hamlin"&gt;dev.to/mr_hamlin&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>node</category>
      <category>javascript</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>I Added x402 Payments to Base's Agent Skills — Here's How</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Tue, 09 Jun 2026 21:09:24 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/i-added-x402-payments-to-bases-agent-skills-heres-how-17b8</link>
      <guid>https://dev.to/mr_hamlin/i-added-x402-payments-to-bases-agent-skills-heres-how-17b8</guid>
      <description>&lt;p&gt;If you build agents on Base, two things landed recently that are worth connecting.&lt;/p&gt;

&lt;p&gt;First: &lt;strong&gt;Base shipped its own Agent Skills.&lt;/strong&gt; There's now a &lt;code&gt;base/skills&lt;/code&gt; repo with consolidated skills that teach an AI agent to connect to Base, deploy contracts, authenticate wallets, and run nodes — installed with one command via Vercel's &lt;code&gt;npx skills&lt;/code&gt; CLI.&lt;/p&gt;

&lt;p&gt;Second: that CLI is part of a fast-growing, cross-agent ecosystem most crypto devs haven't clocked yet. So this post does two things — explains how &lt;code&gt;npx skills&lt;/code&gt; and &lt;code&gt;skills.sh&lt;/code&gt; actually work, and shows where the payment layer in Base's skills stops and how to extend it with &lt;strong&gt;x402 pay-per-call&lt;/strong&gt; and &lt;strong&gt;batch disbursement&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  What &lt;code&gt;npx skills&lt;/code&gt; actually is
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;npx skills&lt;/code&gt; is an open CLI from Vercel Labs for installing "skills" — modular &lt;code&gt;SKILL.md&lt;/code&gt; files that teach an agent a specific capability without stuffing everything into its context window. A few things make it different from what crypto devs usually expect:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;GitHub is the registry.&lt;/strong&gt; There's no central package server. Any public GitHub repo with a &lt;code&gt;SKILL.md&lt;/code&gt; at its root is a valid, installable skill. Install with &lt;code&gt;npx skills add owner/repo&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;It's cross-agent.&lt;/strong&gt; The same skill installs into Claude Code, Cursor, Codex, GitHub Copilot, Goose, Windsurf, Gemini, and dozens more. You write once; it works across the agent you (or your users) actually run.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;skills.sh&lt;/code&gt; is the directory + leaderboard.&lt;/strong&gt; It ranks skills by real install counts pulled from telemetry, with all-time, trending, and hot lists. There's no editorial submission step — you publish by putting a skill in a repo, and installs surface it.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The format underneath — &lt;code&gt;SKILL.md&lt;/code&gt; — is an open spec, which is why Base, Vercel, Anthropic, and a long tail of independent devs all use the same files.&lt;/p&gt;

&lt;p&gt;Here's Base's install, for reference:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Base's official agent skills&lt;/span&gt;
npx skills add base/skills &lt;span class="nt"&gt;--skill&lt;/span&gt; build-on-base
npx skills add base/skills &lt;span class="nt"&gt;--skill&lt;/span&gt; base-mcp
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;build-on-base&lt;/code&gt; is a consolidated Base dev playbook; &lt;code&gt;base-mcp&lt;/code&gt; wires up a Base MCP server that gives an agent a wallet — sending, swapping, signing, batched calls, balances.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where Base's skills stop
&lt;/h2&gt;

&lt;p&gt;This is the interesting gap. Base's skills give an agent a wallet and the ability to &lt;em&gt;transact&lt;/em&gt;: send a payment, swap a token, sign, batch several calls into one transaction. That's the on-chain action layer, and it's well covered.&lt;/p&gt;

&lt;p&gt;What that layer doesn't do is two distinct things the agent economy actually runs on:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Pay-per-call consumption.&lt;/strong&gt; When an agent needs to &lt;em&gt;buy&lt;/em&gt; data or compute — a price feed, a web search, an LLM completion — it needs to pay for that call, per call, without an API key or a billing account. That's &lt;a href="https://x402.org" rel="noopener noreferrer"&gt;x402&lt;/a&gt;: the HTTP 402 "Payment Required" status code turned into a machine-readable micropayment handshake. The agent hits an endpoint, gets a 402 with a price, signs a USDC authorization, retries, and gets the data. No signup.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Batch disbursement.&lt;/strong&gt; "Batched calls" (bundling operations into one tx) is not the same as paying &lt;em&gt;many different recipients&lt;/em&gt; in one transaction — payroll, airdrops, contributor payouts, refunds. That's a disbursement primitive, and it's what the &lt;a href="https://docs.spraay.app/bpa/1.0/" rel="noopener noreferrer"&gt;Batch Payments for Agents (BPA 1.0)&lt;/a&gt; spec standardizes.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Both settle in USDC on Base. Neither is something a wallet-only skill handles. So they're a clean, complementary layer to drop on top of what Base ships.&lt;/p&gt;

&lt;h2&gt;
  
  
  Adding the payment layer
&lt;/h2&gt;

&lt;p&gt;I published three skills that fill exactly that gap, each its own repo so you install only what you need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;&lt;a href="https://github.com/plagtech/defi-intelligence-x402" rel="noopener noreferrer"&gt;defi-intelligence-x402&lt;/a&gt;&lt;/strong&gt; — pay-per-call data + market intelligence on Base (prices, oracles, swap quotes, wallet analytics, ENS/Basename)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;a href="https://github.com/plagtech/ai-compute-x402" rel="noopener noreferrer"&gt;ai-compute-x402&lt;/a&gt;&lt;/strong&gt; — pay-per-call AI inference (200+ LLMs, Bittensor, image gen, embeddings, GPU)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;a href="https://github.com/plagtech/agent-payments-x402" rel="noopener noreferrer"&gt;agent-payments-x402&lt;/a&gt;&lt;/strong&gt; — batch payments, payroll, invoicing, escrow (BPA 1.0)
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Pay-per-call data + market intelligence on Base&lt;/span&gt;
npx skills add plagtech/defi-intelligence-x402

&lt;span class="c"&gt;# Pay-per-call AI inference (200+ LLMs, Bittensor, GPU)&lt;/span&gt;
npx skills add plagtech/ai-compute-x402

&lt;span class="c"&gt;# Batch payments, payroll, invoicing, escrow (BPA 1.0)&lt;/span&gt;
npx skills add plagtech/agent-payments-x402
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;All three call the &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;Spraay x402 Gateway&lt;/a&gt;, which is x402-native end to end — no API keys, no accounts. You fund a wallet with USDC on Base, set one env var, and the x402 client signs and retries payments automatically.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nb"&gt;install &lt;/span&gt;x402-client
&lt;span class="nb"&gt;export &lt;/span&gt;&lt;span class="nv"&gt;EVM_PRIVATE_KEY&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;0x...   &lt;span class="c"&gt;# wallet holding USDC on Base&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Worked example: an agent that prices before it acts
&lt;/h3&gt;

&lt;p&gt;A read call costs a fraction of a cent and needs no key:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;createClient&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;x402-client&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;createClient&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;baseUrl&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://gateway.spraay.app&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;privateKey&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;process&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;EVM_PRIVATE_KEY&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="c1"&gt;// Live oracle prices — pays ~$0.008 USDC, automatically&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;prices&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/oracle/prices&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="c1"&gt;// { ETH: 2847.50, BTC: ... }&lt;/span&gt;

&lt;span class="c1"&gt;// Profile a wallet before interacting with it&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;profile&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/analytics/wallet?address=0xabc...&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Worked example: pay 50 people in one transaction
&lt;/h3&gt;

&lt;p&gt;This is the disbursement primitive a wallet-only skill can't express:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// Batch-send USDC to many recipients in a single tx&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;tx&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;post&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/batch/execute&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;chain&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;base&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;USDC&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;recipients&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;address&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xabc...&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;amount&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;10.00&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;address&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xdef...&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;amount&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;25.50&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="c1"&gt;// ...up to your full roster&lt;/span&gt;
  &lt;span class="p"&gt;],&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Estimate first with &lt;code&gt;/api/v1/batch/estimate&lt;/code&gt; (≈$0.001) if you want a gas/fee preview before sending.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why this matters for agents on Base
&lt;/h2&gt;

&lt;p&gt;The mental model is two layers:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Base's skills&lt;/strong&gt; = the agent has a wallet and can transact.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;x402 skills&lt;/strong&gt; = the agent can pay for each call it makes, and pay many parties at once.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Put them together and you have an agent that can read on-chain state, buy the data and compute it needs per call, and disburse funds — all in USDC on Base, all without a single API key or account. That's most of what an autonomous economic agent actually needs to do a job end to end.&lt;/p&gt;

&lt;p&gt;If you're building on Base, the install lines above are the fastest way to try the payment layer. Skills are just &lt;code&gt;SKILL.md&lt;/code&gt; files — open them before you install (it takes 30 seconds) and you'll see exactly which endpoints get called and what they cost.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Skills:&lt;/strong&gt; &lt;a href="https://github.com/plagtech/agent-payments-x402" rel="noopener noreferrer"&gt;agent-payments-x402&lt;/a&gt; · &lt;a href="https://github.com/plagtech/defi-intelligence-x402" rel="noopener noreferrer"&gt;defi-intelligence-x402&lt;/a&gt; · &lt;a href="https://github.com/plagtech/ai-compute-x402" rel="noopener noreferrer"&gt;ai-compute-x402&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Links:&lt;/strong&gt; &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;Spraay Gateway&lt;/a&gt; · &lt;a href="https://docs.spraay.app" rel="noopener noreferrer"&gt;Docs / full endpoint catalog&lt;/a&gt; · &lt;a href="https://live.spraay.app" rel="noopener noreferrer"&gt;Live gateway traffic&lt;/a&gt; · &lt;a href="https://docs.spraay.app/bpa/1.0/" rel="noopener noreferrer"&gt;BPA 1.0 spec&lt;/a&gt;&lt;/p&gt;

</description>
      <category>base</category>
      <category>ai</category>
      <category>web3</category>
      <category>x402</category>
    </item>
    <item>
      <title>📚 Why Every AI Agent Needs a Research Library</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Fri, 05 Jun 2026 02:39:03 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/why-every-ai-agent-needs-a-research-library-434p</link>
      <guid>https://dev.to/mr_hamlin/why-every-ai-agent-needs-a-research-library-434p</guid>
      <description>&lt;p&gt;Your AI agent just hit a wall.&lt;/p&gt;

&lt;p&gt;It needs to look up a chemical compound for a drug interaction check. Or find the latest papers on transformer architectures. Or pull US Census demographics for a market analysis. What does it do?&lt;/p&gt;

&lt;p&gt;It hallucinates.&lt;/p&gt;

&lt;p&gt;Training data is months or years old. Web searches return noisy HTML, not structured data. And the agent has no way to verify what it "knows" against the actual source of record. For any task that requires factual accuracy — scientific, medical, legal, demographic — the agent is guessing.&lt;/p&gt;

&lt;p&gt;This is a solvable problem.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Research Gap in Agent Infrastructure
&lt;/h2&gt;

&lt;p&gt;Look at what the agent ecosystem has built so far: payment rails, wallet provisioning, DeFi integrations, compute access, communication protocols. These are all critical. But there's a missing layer that nobody's talking about.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Knowledge access.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;When a human researcher needs to verify a claim, they check PubMed. When they need a chemical structure, they check PubChem. When they need citation data, they check Crossref. When they need demographic trends, they check the Census Bureau.&lt;/p&gt;

&lt;p&gt;AI agents have no equivalent. They're making consequential decisions — medical summaries, investment research, compliance checks, scientific literature reviews — without access to the same authoritative sources that human experts rely on.&lt;/p&gt;

&lt;p&gt;That's the gap we just filled.&lt;/p&gt;

&lt;h2&gt;
  
  
  What We Built
&lt;/h2&gt;

&lt;p&gt;We added a full Research &amp;amp; Reference category to the &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;Spraay x402 gateway&lt;/a&gt; — 23 endpoints spanning 7 research domains, all accessible via micropayment (USDC on Base or Solana).&lt;/p&gt;

&lt;p&gt;Here's what an agent can now look up on demand:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Language &amp;amp; Definitions&lt;/strong&gt; — word definitions, synonyms, antonyms, phonetics, and pronunciation audio across 9 languages. The foundation for any agent that processes or generates natural language.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Academic Papers&lt;/strong&gt; — search across 250 million scholarly works spanning every discipline: physics, biology, computer science, economics, social sciences, humanities, engineering, medicine, law, education. Filter by field, year, author, or ORCID. Pull citation graphs. Track what's trending.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Preprints&lt;/strong&gt; — the bleeding edge of science. 2.4 million preprints across physics, mathematics, computer science, quantitative biology, quantitative finance, statistics, and economics. These are the papers that haven't been published yet — the ones that move markets and shift research directions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Scholarly Metadata&lt;/strong&gt; — 150 million published works with full metadata: journal articles, books, conference papers, and datasets. Citation counts, reference lists, journal info by ISSN. When an agent needs to verify a source exists and check its impact, this is the endpoint.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Chemistry&lt;/strong&gt; — 110 million chemical compounds with molecular structures, physical properties, safety and toxicity data, and biological assay results. Structural similarity search for finding related compounds. This is the same database that pharmaceutical researchers and chemists use daily.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Biomedical Literature&lt;/strong&gt; — 36 million papers covering medicine, pharmacology, genomics, neuroscience, public health, and more. Related article discovery for any given paper. When your agent is summarizing medical research or checking drug interactions, this is the authoritative source.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Demographics &amp;amp; Government Data&lt;/strong&gt; — US Census data by state, county, and zip code: population, income, housing, education, employment. Plus the entire federal open data catalog — transportation, climate, health, agriculture, energy, and crime statistics.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Endpoint Map
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight http"&gt;&lt;code&gt;&lt;span class="err"&gt;# Dictionary &amp;amp; Language
GET /api/v1/research/dictionary/define        $0.001
GET /api/v1/research/dictionary/synonyms      $0.001
GET /api/v1/research/dictionary/phonetics     $0.001

# Academic Papers (250M+ works)
GET /api/v1/research/papers/search            $0.002
GET /api/v1/research/papers/by-doi            $0.001
GET /api/v1/research/papers/by-author         $0.002
GET /api/v1/research/papers/citations         $0.002
GET /api/v1/research/papers/trending          $0.002

# Preprints (2.4M+ papers)
GET /api/v1/research/preprints/search         $0.002
GET /api/v1/research/preprints/by-id          $0.001
GET /api/v1/research/preprints/recent         $0.002

# Scholarly Metadata (150M+ works)
GET /api/v1/research/scholarly/search         $0.002
GET /api/v1/research/scholarly/by-doi         $0.001
GET /api/v1/research/scholarly/citations-count $0.001
GET /api/v1/research/scholarly/journal-info   $0.001

# Chemistry (110M+ compounds)
GET /api/v1/research/chemistry/compound       $0.002
GET /api/v1/research/chemistry/similarity     $0.002
GET /api/v1/research/chemistry/bioactivity    $0.002

# Biomedical (36M+ papers)
GET /api/v1/research/biomedical/search        $0.002
GET /api/v1/research/biomedical/by-pmid       $0.001
GET /api/v1/research/biomedical/related       $0.002

# Demographics &amp;amp; Government Data
GET /api/v1/research/demographics/census      $0.001
GET /api/v1/research/demographics/datasets    $0.001
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every response returns a unified JSON envelope with the source, license info, attribution, and a consistent result structure — regardless of which domain the query hits. One integration, every domain.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where the Demand Is
&lt;/h2&gt;

&lt;p&gt;These aren't hypothetical use cases. This is what agents are already trying to do, badly, with web scraping and hallucination:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Pharmaceutical &amp;amp; biotech agents&lt;/strong&gt; — compound lookup, drug interaction screening, literature review across 36M biomedical papers. An agent advising on drug safety needs PubChem and PubMed, not a Google search.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Academic writing assistants&lt;/strong&gt; — paper discovery, citation graph traversal, related work identification. Every grad student's AI assistant needs structured access to the scholarly record.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Market research agents&lt;/strong&gt; — Census demographics for TAM sizing, government datasets for industry analysis, trend tracking across academic publications for emerging technology identification.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Fact-checking and verification&lt;/strong&gt; — DOI lookup confirms a source actually exists. Citation counts indicate impact. Cross-referencing preprints against published papers catches retractions and updates.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Scientific monitoring&lt;/strong&gt; — agents that watch arXiv daily for new preprints in specific categories, track citation velocity on key papers, and flag when a trending paper crosses a threshold.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Compliance and regulatory&lt;/strong&gt; — biomedical literature search for adverse event signals, chemical safety data for REACH/GHS compliance, demographic data for fair lending analysis.&lt;/p&gt;

&lt;p&gt;The pattern is the same in every case: the agent needs structured, authoritative, verifiable data — not a web search result. And it needs it on demand, per call, without managing API keys and parsing 7 different response formats.&lt;/p&gt;

&lt;h2&gt;
  
  
  One Gateway, Every Domain
&lt;/h2&gt;

&lt;p&gt;The value proposition for agent builders is simple: integrate once with Spraay, and your agent gets access to the same research infrastructure that universities and pharmaceutical companies use. Pay per call. No subscriptions, no rate limit negotiations, no format wrangling.&lt;/p&gt;

&lt;p&gt;The research endpoints sit alongside 115 existing endpoints on the gateway covering payments, DeFi, oracle, compute, communication, and more — 138 total across 34 categories. If your agent needs to look something up &lt;em&gt;and&lt;/em&gt; take action on what it finds, the entire stack is already wired together.&lt;/p&gt;

&lt;p&gt;The gateway is live at &lt;code&gt;gateway.spraay.app&lt;/code&gt;. The MCP server on &lt;a href="https://smithery.ai/servers/Plagtech/Spraay-x402-mcp" rel="noopener noreferrer"&gt;Smithery&lt;/a&gt; has all the tools pre-wired for Claude, GPT, and any MCP-compatible agent framework.&lt;/p&gt;

&lt;p&gt;Docs: &lt;a href="https://docs.spraay.app" rel="noopener noreferrer"&gt;docs.spraay.app&lt;/a&gt;&lt;br&gt;
GitHub: &lt;a href="https://github.com/plagtech/spraay-x402-gateway" rel="noopener noreferrer"&gt;plagtech/spraay-x402-gateway&lt;/a&gt;&lt;br&gt;
Twitter: &lt;a href="https://twitter.com/Spraay_app" rel="noopener noreferrer"&gt;@Spraay_app&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Agents that know things make better decisions than agents that guess. Give yours a library card.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>webdev</category>
      <category>opensource</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Batch Payments for Agents (BPA) 1.0: an open standard for how AI agents pay many recipients at once</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Tue, 02 Jun 2026 20:22:14 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/batch-payments-for-agents-bpa-10-an-open-standard-for-how-ai-agents-pay-many-recipients-at-once-22e3</link>
      <guid>https://dev.to/mr_hamlin/batch-payments-for-agents-bpa-10-an-open-standard-for-how-ai-agents-pay-many-recipients-at-once-22e3</guid>
      <description>&lt;p&gt;Agents can now &lt;em&gt;act&lt;/em&gt;. They book, they buy, they call tools, they spend. But ask a simple question — &lt;em&gt;how does an autonomous agent pay 500 people in one go?&lt;/em&gt; — and there's no clean answer. There's a pile of one-off integrations and a lot of hand-waving.&lt;/p&gt;

&lt;p&gt;So we wrote the spec. &lt;strong&gt;Batch Payments for Agents (BPA) 1.0&lt;/strong&gt; is a framework-neutral, open standard for how an agent disburses funds to many recipients in a single, governed, verifiable batch. It's live and citable here:&lt;/p&gt;

&lt;p&gt;👉 &lt;strong&gt;&lt;a href="https://docs.spraay.app/bpa/1.0/" rel="noopener noreferrer"&gt;docs.spraay.app/bpa/1.0&lt;/a&gt;&lt;/strong&gt; · source: &lt;strong&gt;&lt;a href="https://github.com/plagtech/bpa-spec" rel="noopener noreferrer"&gt;github.com/plagtech/bpa-spec&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This post is the why and the what.&lt;/p&gt;

&lt;h2&gt;
  
  
  The payments agents actually need are the ones the old rails punish
&lt;/h2&gt;

&lt;p&gt;Card and bank networks are optimized for a human clicking checkout once. Agent payouts are the opposite shape, and they break the cost model in three specific ways:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Micro-amounts.&lt;/strong&gt; Paying a crowd of data labelers $0.50 a task dies on fixed fees.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Machine-initiated.&lt;/strong&gt; No human at checkout, no card-present flow, no chargeback dance.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;One-to-many, global.&lt;/strong&gt; Pay 200 contributors at once, many cross-border or unbanked, and settle in seconds.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Stablecoins on fast chains solve the &lt;em&gt;rail&lt;/em&gt;. What's missing is the &lt;em&gt;contract&lt;/em&gt; — the agreed-upon shape of "an agent safely pays many recipients at once." Without it, every team rebuilds the same fragile logic: how do you make a batch idempotent? what happens when line 347 of 500 fails? how do you prove it settled? how do you stop a misbehaving agent from draining a treasury?&lt;/p&gt;

&lt;p&gt;BPA answers those questions once, so nobody has to answer them again.&lt;/p&gt;

&lt;h2&gt;
  
  
  What BPA 1.0 actually defines
&lt;/h2&gt;

&lt;p&gt;The spec is deliberately boring in the way good infrastructure is boring. It nails down:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;A request format&lt;/strong&gt; — one &lt;code&gt;Disbursement Request&lt;/code&gt; object, with a JSON Schema you can validate against.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Idempotency&lt;/strong&gt; — replay-safe by construction, because batch disbursement is irreversible.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Partial-failure semantics&lt;/strong&gt; — atomic by default; if a rail can't be atomic, per-recipient results and a retry token scoped to &lt;em&gt;only&lt;/em&gt; the failed lines.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Settlement confirmation&lt;/strong&gt; — verifiable on-chain, per-chain finality rules, no "trust me, it sent."&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;A governance model&lt;/strong&gt; — spend caps, recipient allowlists, approval gating, and tamper-evident audit, all evaluated &lt;em&gt;before&lt;/em&gt; settlement and failing closed.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Transparent fees, transport bindings (x402 / MPP), and an MCP tool shape.&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here's the core object an agent constructs:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"bpa_version"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"1.0"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"idempotency_key"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"payout-2026-06-02-001"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"chain"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"eip155:8453"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"asset"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"USDC"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"recipients"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"address"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"0xAbc..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"amount"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"5000000"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"ref"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"worker-001"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"address"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"0xDef..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"amount"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"5000000"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nl"&gt;"ref"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"worker-002"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Amounts are integer base units (no float drift). Validate it against the published &lt;a href="https://docs.spraay.app/bpa/1.0/disbursement-request.schema.json" rel="noopener noreferrer"&gt;JSON Schema&lt;/a&gt; before you send.&lt;/p&gt;

&lt;h2&gt;
  
  
  Three design choices worth calling out
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Non-custodial end to end.&lt;/strong&gt; The facilitator only &lt;em&gt;builds&lt;/em&gt; the transaction; the agent's own signature authorizes the spend. The gateway never holds funds. That single property collapses a whole class of security concerns — a forged request just produces an unsigned transaction nobody can submit.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Governed before execution, not after.&lt;/strong&gt; BPA treats every disbursement as a high-risk action. The goal isn't to &lt;em&gt;ask&lt;/em&gt; an agent to behave — it's to make an out-of-policy payout structurally impossible. Caps, allowlists, and approvals are deterministic checks the request must pass before a single token moves. If policy can't be evaluated, the answer is "denied."&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Three chains, on purpose.&lt;/strong&gt; BPA 1.0 is normatively defined for &lt;strong&gt;Base, Ethereum, and Solana&lt;/strong&gt; — where agent payment activity actually concentrates, plus institutional reach. We run the reference contract on more chains, but a spec's credibility is its weakest claim. Everything in the normative body is mainnet and source-verified (the settlement contracts are verified, exact-match, on BaseScan and Etherscan). Breadth that isn't load-bearing is just surface area for doubt.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it
&lt;/h2&gt;

&lt;p&gt;Spraay is the reference implementation (full disclosure: it's ours, and writing the spec forced us to make it airtight). You can hit it two ways:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;HTTP / x402:&lt;/strong&gt; &lt;code&gt;POST https://gateway.spraay.app/api/v1/batch/execute&lt;/code&gt; — returns an unsigned transaction for your agent to sign.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;MCP:&lt;/strong&gt; the &lt;code&gt;spraay_batch_execute&lt;/code&gt; tool, published on Smithery as &lt;code&gt;@plagtech/spraay-x402-mcp&lt;/code&gt;, described by intent so your agent matches it at runtime.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The on-chain protocol fee is 0.30%, with a 200-recipient cap per call (chunk larger batches under one idempotency key).&lt;/p&gt;

&lt;h2&gt;
  
  
  It's an open standard — build on it
&lt;/h2&gt;

&lt;p&gt;BPA is published under &lt;strong&gt;CC-BY-4.0&lt;/strong&gt;. Implementations are unrestricted and need no permission. There's a conformance checklist (§14) and a self-attestation format for any facilitator — not just ours — to claim conformance. If you're building agent infrastructure and you touch payouts, this is meant to be the reference you point your own tooling at.&lt;/p&gt;

&lt;p&gt;If the attestation model for task-gated payments (pay-on-approval) is something you have strong opinions about, that's the one piece explicitly scoped for 1.1 — open an issue.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Spec:&lt;/strong&gt; &lt;a href="https://docs.spraay.app/bpa/1.0/" rel="noopener noreferrer"&gt;docs.spraay.app/bpa/1.0&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Repo:&lt;/strong&gt; &lt;a href="https://github.com/plagtech/bpa-spec" rel="noopener noreferrer"&gt;github.com/plagtech/bpa-spec&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Reference gateway:&lt;/strong&gt; &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;gateway.spraay.app&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Agents are going to move a lot of money in small pieces to a lot of people. Let's at least agree on how.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>blockchain</category>
      <category>opensource</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Compute Futures for AI Agents: Prepaid GPU and Inference Credits over x402</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Tue, 02 Jun 2026 01:04:03 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/compute-futures-for-ai-agents-prepaid-gpu-and-inference-credits-over-x402-4fhc</link>
      <guid>https://dev.to/mr_hamlin/compute-futures-for-ai-agents-prepaid-gpu-and-inference-credits-over-x402-4fhc</guid>
      <description>&lt;p&gt;There's a growing conversation about treating compute like a tradable commodity — something you can price, prepay, and hold, not just rent by the second. It's an interesting macro idea for data centers and GPU clusters. But there's a much more immediate version of it that nobody talks about: &lt;strong&gt;what does an AI agent do when it needs to buy compute, over and over, without a credit card or an API key?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;That's the gap I built &lt;a href="https://github.com/plagtech/spraay-compute" rel="noopener noreferrer"&gt;Spraay Compute &amp;amp; Futures&lt;/a&gt; to close.&lt;/p&gt;

&lt;h2&gt;
  
  
  The problem with paying retail for every inference call
&lt;/h2&gt;

&lt;p&gt;Pay-per-call micropayments are great for one-off jobs. An agent hits an endpoint, gets a &lt;code&gt;402 Payment Required&lt;/code&gt;, signs a USDC authorization, retries, gets its result. Clean. This is exactly what x402 was built for, and it works.&lt;/p&gt;

&lt;p&gt;But agents don't run one job. They run &lt;em&gt;workloads&lt;/em&gt; — a research agent fires off hundreds of inference calls, a content pipeline generates dozens of images, a RAG system embeds thousands of chunks. Two things break down at that volume:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;No budget predictability.&lt;/strong&gt; Every call is a fresh signature and a fresh settlement. There's no way to say "this agent has $50 to spend on compute this week" and have the rails enforce it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No volume pricing.&lt;/strong&gt; You pay the same per-call rate whether it's your first request or your ten-thousandth. In every other market, buying in bulk gets you a discount. Agentic compute had no equivalent.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The usual fix is accounts and API keys with prepaid balances — exactly the thing x402 was supposed to kill. So the question became: can you get prepaid, discounted compute &lt;em&gt;without&lt;/em&gt; reintroducing accounts?&lt;/p&gt;

&lt;h2&gt;
  
  
  Compute futures: prepay once, draw down per job
&lt;/h2&gt;

&lt;p&gt;The answer is a prepaid compute-credit account that lives entirely on x402 rails. You deposit USDC once, get a credit balance with a tier discount baked in, and then run jobs against that balance. No per-call payment for the compute itself — each job just deducts from your credits at the discounted rate. Refund whatever you don't use.&lt;/p&gt;

&lt;p&gt;The tiers are simple:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;$10+&lt;/strong&gt; → 5% off&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;$50+&lt;/strong&gt; → 10% off&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;$200+&lt;/strong&gt; → 15% off&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The whole lifecycle is three calls:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;wrapFetchWithPayment&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;@x402/fetch&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;fetchPay&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;wrapFetchWithPayment&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;fetch&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;wallet&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;BASE&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://gateway.spraay.app&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c1"&gt;// 1. Open a $50 account — lands in the 10% tier ($0.01 to set up)&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;acct&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;fetchPay&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;BASE&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/compute-futures/deposit`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;method&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;POST&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Content-Type&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;application/json&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="na"&gt;body&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="na"&gt;depositor&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xYourAgentWallet&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;amount&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;50&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;}),&lt;/span&gt;
&lt;span class="p"&gt;}).&lt;/span&gt;&lt;span class="nf"&gt;then&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;r&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;r&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;futuresId&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;acct&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;computeFuture&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;id&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="c1"&gt;// "CFE-ABC12345"&lt;/span&gt;

&lt;span class="c1"&gt;// 2. Run jobs against the balance — $0.001 settlement, discount applied&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;job&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;fetchPay&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;BASE&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/compute-futures/execute`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;method&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;POST&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Content-Type&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;application/json&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="na"&gt;body&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="nx"&gt;futuresId&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;text-inference&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;messages&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[{&lt;/span&gt; &lt;span class="na"&gt;role&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;user&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Summarize this filing: ...&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;}],&lt;/span&gt;
  &lt;span class="p"&gt;}),&lt;/span&gt;
&lt;span class="p"&gt;}).&lt;/span&gt;&lt;span class="nf"&gt;then&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;r&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;r&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;
&lt;span class="c1"&gt;// → { billing: { charged: "$0.027", balanceRemaining: "$42.473 USDC" },&lt;/span&gt;
&lt;span class="c1"&gt;//     compute: { model: "Llama 3.3 70B" } }&lt;/span&gt;

&lt;span class="c1"&gt;// 3. Refund the unused balance anytime (depositor-only)&lt;/span&gt;
&lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;fetchPay&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;BASE&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/compute-futures/refund`&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;method&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;POST&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Content-Type&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;application/json&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="na"&gt;body&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt; &lt;span class="nx"&gt;futuresId&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;caller&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xYourAgentWallet&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;}),&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That &lt;code&gt;execute&lt;/code&gt; call is the key move. The agent isn't signing and settling a payment for the inference — it already paid, in bulk, at a discount. It's just spending credits. You get budget predictability (the balance &lt;em&gt;is&lt;/em&gt; the budget) and volume pricing, without a single API key.&lt;/p&gt;

&lt;h2&gt;
  
  
  What you can actually run
&lt;/h2&gt;

&lt;p&gt;The same account works across the whole compute surface — text, images, video, audio, embeddings:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Capability&lt;/th&gt;
&lt;th&gt;Models&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;LLM inference&lt;/td&gt;
&lt;td&gt;11 models, 3B–405B (Chutes AI / Bittensor SN64, OpenRouter)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Image generation&lt;/td&gt;
&lt;td&gt;FLUX Schnell/Dev/Pro, SDXL&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Video generation&lt;/td&gt;
&lt;td&gt;MiniMax Video 01, Wan 2.1&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Speech-to-text&lt;/td&gt;
&lt;td&gt;Whisper Large V3, 100+ languages&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Text-to-speech&lt;/td&gt;
&lt;td&gt;voice synthesis&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Embeddings&lt;/td&gt;
&lt;td&gt;for RAG and semantic search&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;And if you'd rather just pay per call — no prepayment — every one of those is also a direct x402 endpoint (LLM inference at $0.03, GPU run at $0.06, embeddings at $0.005, and so on). There's a free &lt;code&gt;/compute/estimate&lt;/code&gt; to price a job before you commit, and a free &lt;code&gt;/compute/models&lt;/code&gt; to list what's available.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why x402 makes this work
&lt;/h2&gt;

&lt;p&gt;The reason prepaid compute credits don't require accounts is that the wallet &lt;em&gt;is&lt;/em&gt; the account. Settlement is USDC on Base mainnet and Solana mainnet, verified through the x402 facilitator. The depositor address owns the credit balance; only that address can spend it or refund it. No login, no key rotation, no dashboard — the same primitives that make per-call x402 work also make prepaid balances work, just with the payment moved up front.&lt;/p&gt;

&lt;p&gt;It's a small idea with a real consequence: an autonomous agent can now hold a compute budget the way a team holds a cloud-credit balance, except it's permissionless, refundable, and settles in two seconds.&lt;/p&gt;

&lt;h2&gt;
  
  
  Drop it into your agent
&lt;/h2&gt;

&lt;p&gt;It's packaged as a skill, so any agent can install it:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# OpenClaw / ClawHub&lt;/span&gt;
npx clawhub &lt;span class="nb"&gt;install &lt;/span&gt;spraay-compute

&lt;span class="c"&gt;# Claude Code, Cursor, Codex, Gemini CLI (Vercel Skills CLI)&lt;/span&gt;
npx skills add plagtech/spraay-compute
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The skill ships the full endpoint reference and runnable examples, so the agent knows exactly which endpoint to call, what it costs, and how to handle async jobs.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Repo:&lt;/strong&gt; &lt;a href="https://github.com/plagtech/spraay-compute" rel="noopener noreferrer"&gt;https://github.com/plagtech/spraay-compute&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Gateway:&lt;/strong&gt; &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;https://gateway.spraay.app&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Discovery manifest:&lt;/strong&gt; &lt;a href="https://gateway.spraay.app/.well-known/x402.json" rel="noopener noreferrer"&gt;https://gateway.spraay.app/.well-known/x402.json&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you're building agents that run real compute workloads, prepaying for a discount beats paying retail on every call. Open an account, run your jobs, refund the rest.&lt;/p&gt;

</description>
      <category>x402</category>
      <category>aiagents</category>
      <category>crypto</category>
      <category>web3</category>
    </item>
    <item>
      <title>BlackRock's CEO just called compute one of the next major markets. Here's why Spraay Protocol is already there.</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Wed, 27 May 2026 23:11:09 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/blackrocks-ceo-just-called-compute-one-of-the-next-major-markets-heres-why-spraay-protocol-is-2o7d</link>
      <guid>https://dev.to/mr_hamlin/blackrocks-ceo-just-called-compute-one-of-the-next-major-markets-heres-why-spraay-protocol-is-2o7d</guid>
      <description>&lt;h2&gt;
  
  
  The Signal No One Should Ignore
&lt;/h2&gt;

&lt;p&gt;When Larry Fink — the man who oversees $10 trillion in assets — tells the world that compute is becoming a financial instrument on par with equities and bonds, that's not speculation. That's a roadmap.&lt;/p&gt;

&lt;p&gt;And it's a roadmap we've been building on for months.&lt;/p&gt;

&lt;p&gt;At Spraay Protocol, we didn't wait for BlackRock to validate the thesis. We've been operating at the intersection of AI compute, machine-to-machine payments, and on-chain settlement since before the phrase "compute economy" entered the mainstream vocabulary. What Fink described as the future is, for us, already in production.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Problem Everyone Sees but Nobody Has Solved
&lt;/h2&gt;

&lt;p&gt;Here's the reality of AI compute right now: it's bought in bulk, priced opaquely, walled behind platform lock-in, and completely disconnected from the financial rails that every other commodity trades on.&lt;/p&gt;

&lt;p&gt;If you're an AI agent — and there will be millions of them — you can't call up a cloud provider and negotiate a rate. You can't hedge against a price spike during peak inference demand. You don't have a treasury function. You don't have a credit line.&lt;/p&gt;

&lt;p&gt;You just pay whatever you're charged, whenever you're charged, and hope for the best.&lt;/p&gt;

&lt;p&gt;That's not how real markets work. Real markets have price discovery. Real markets have futures. Real markets have settlement infrastructure.&lt;/p&gt;

&lt;p&gt;Spraay is that infrastructure.&lt;/p&gt;

&lt;h2&gt;
  
  
  What We Actually Built
&lt;/h2&gt;

&lt;p&gt;Spraay Protocol is a multi-chain x402 payment gateway — the protocol Coinbase introduced that lets machines pay other machines at the HTTP layer. Every API call, every inference request, every data retrieval can carry a payment natively. No invoices. No subscriptions. No human in the loop.&lt;/p&gt;

&lt;p&gt;We took that foundation and built what the compute economy actually needs:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Compute Futures and Escrow.&lt;/strong&gt; Prepaid credit systems with tiered pricing that let agents and developers lock in compute costs ahead of time. When inference demand spikes — and it will — our users have already secured their capacity at yesterday's price.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;115 live paid endpoints across 33 categories.&lt;/strong&gt; This isn't a whitepaper. This is &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;production infrastructure&lt;/a&gt; spanning AI inference, on-chain data, oracles, messaging, storage, and more — all payable via x402 on 13+ chains.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Batch payment infrastructure.&lt;/strong&gt; Enterprise-grade payroll and multi-recipient disbursement, because the compute economy doesn't run on one-to-one transactions. It runs on networks paying networks.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;An &lt;a href="https://smithery.ai/servers/Plagtech/Spraay-x402-mcp" rel="noopener noreferrer"&gt;MCP server with 120 tools&lt;/a&gt;.&lt;/strong&gt; Direct integration into the AI agent ecosystem — LangChain, CrewAI, AutoGPT, and beyond. Agents don't just use Spraay. They think with it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why x402 Is the Payment Rail for Compute
&lt;/h2&gt;

&lt;p&gt;The genius of x402 is its simplicity. An HTTP 402 status code has always meant "payment required." Coinbase's protocol made it machine-readable. Spraay made it machine-complete.&lt;/p&gt;

&lt;p&gt;Think about what this means for the compute market Fink is describing. Every inference endpoint becomes a tradeable unit. Every API call carries provable settlement. Every agent has a native way to pay for the resources it consumes — across any chain, at any scale, without a single human approving a transaction.&lt;/p&gt;

&lt;p&gt;This isn't DeFi trying to reinvent finance. This is finance's existing logic — futures, escrow, settlement, clearing — implemented natively for the first commodity that was born digital.&lt;/p&gt;

&lt;p&gt;Compute didn't need to be tokenized. It needed to be &lt;em&gt;transactable&lt;/em&gt;. That's what we provide.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Landscape Is Moving Our Way
&lt;/h2&gt;

&lt;p&gt;Look at the signals beyond Fink's statement:&lt;/p&gt;

&lt;p&gt;AI agent frameworks are proliferating. Every major tech company is building autonomous systems that need to procure their own resources. The conversation has shifted from "will agents handle money?" to "how do we make agent payments safe and efficient?"&lt;/p&gt;

&lt;p&gt;The x402 ecosystem is growing. Coinbase shipped the protocol. Developers are building on it. And Spraay has been in the room since day one — not observing, but operating. We have the most comprehensive x402 gateway in production. That's not a claim we make lightly. Count the endpoints. Count the chains. Count the categories.&lt;/p&gt;

&lt;p&gt;On-chain settlement is being taken seriously by institutions that dismissed it two years ago. When the world's largest asset manager starts drawing parallels between compute and traditional commodities, the infrastructure question becomes urgent. Who settles these transactions? On what rails? With what guarantees?&lt;/p&gt;

&lt;p&gt;We have answers. Live ones.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Comes Next
&lt;/h2&gt;

&lt;p&gt;We're not slowing down. The Spraay roadmap is built around a simple conviction: the compute economy will be the largest machine-to-machine market in history, and it will need payment infrastructure that's as fast, programmable, and autonomous as the agents that run on it.&lt;/p&gt;

&lt;p&gt;That means deeper futures and hedging primitives. More chains. More endpoints. Tighter integrations into every major agent framework. And continued leadership in the x402 space — not because we want the title, but because we've earned it by building while others were still debating.&lt;/p&gt;

&lt;p&gt;The capital is coming. Fink said so. The infrastructure has to be ready.&lt;/p&gt;

&lt;p&gt;It already is.&lt;/p&gt;




&lt;p&gt;💧 &lt;strong&gt;Spraay Protocol&lt;/strong&gt; — Multi-chain x402 payment gateway and compute settlement infrastructure.&lt;/p&gt;

&lt;p&gt;🌐 &lt;a href="https://spraay.app" rel="noopener noreferrer"&gt;spraay.app&lt;/a&gt; · ⚡ &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;Live Gateway&lt;/a&gt; · 🐦 &lt;a href="https://twitter.com/Spraay_app" rel="noopener noreferrer"&gt;@Spraay_app&lt;/a&gt; · 📡 &lt;a href="https://smithery.ai/servers/Plagtech/Spraay-x402-mcp" rel="noopener noreferrer"&gt;MCP Server on Smithery&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;If you're building AI agents that need to pay for compute, we should talk.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>x402</category>
      <category>ai</category>
      <category>cryptocurrency</category>
      <category>web3</category>
    </item>
    <item>
      <title>Spraay Brings Batch Payments to Canton Network Amid Wall Street Tokenization Push</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Mon, 25 May 2026 00:38:46 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/spraay-brings-batch-payments-to-canton-network-amid-wall-street-tokenization-push-2clj</link>
      <guid>https://dev.to/mr_hamlin/spraay-brings-batch-payments-to-canton-network-amid-wall-street-tokenization-push-2clj</guid>
      <description>&lt;p&gt;Spent the last few days adding Canton Network support to Spraay Protocol's batch payment infrastructure. It's chain 16 for Spraay, and the most interesting one we've integrated to date — for reasons that have less to do with us and more to do with where Canton is going.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Canton context
&lt;/h2&gt;

&lt;p&gt;If you've been heads-down in crypto Twitter, Canton is easy to miss. While most of the EVM ecosystem has been arguing about L2 fragmentation, Canton has quietly become the rail of choice for serious institutional tokenization. The numbers are real:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;DTCC&lt;/strong&gt; — which clears the vast majority of U.S. securities and custodies $114T in assets — partnered with Digital Asset in December 2025 to tokenize DTC-custodied U.S. Treasuries on Canton, with broader rollout through 2H 2026&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;JPMorgan's Kinexys&lt;/strong&gt; is deploying JPM Coin natively on Canton in phases throughout 2026&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Broadridge's&lt;/strong&gt; distributed ledger repo platform, running on Canton rails, already processes &lt;strong&gt;$4 trillion monthly&lt;/strong&gt; in overnight Treasury financing&lt;/li&gt;
&lt;li&gt;Goldman Sachs, BNY Mellon, BNP Paribas, HSBC, Euroclear, S&amp;amp;P Global, Nasdaq are all participants&lt;/li&gt;
&lt;li&gt;Network-wide: ~$6T in tokenized real-world assets across 600+ institutions, ~500K daily transactions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is a network built for the financial plumbing layer most crypto-native builders don't think about every day. And it's already running.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where batch payments fit
&lt;/h2&gt;

&lt;p&gt;Most of Spraay's chains are payment-rail-first: send USDC to N recipients, take a 0.3% protocol fee, optimize gas. That story translates cleanly to retail and to agent-driven commerce (we've leaned hard into x402-style agent payments).&lt;/p&gt;

&lt;p&gt;Canton is different. Holdings are UTXO-style. Transfers go through Splice's Token Standard via a &lt;code&gt;TransferFactory_Transfer&lt;/code&gt; choice on the global synchronizer. Instruments are admin-scoped — the DSO party admins Canton Coin, but any institution issuing on Canton (a tokenized Treasury, a deposit token, a fund share) can be its own instrument admin.&lt;/p&gt;

&lt;p&gt;So a batch payment primitive that works against Token Standard isn't "competing with DTCC." It's a small piece of utility infra that any app building on Canton can compose with — programmatic disbursements, fund flows between sub-accounts, payroll, agent-driven micropayments — whether the instrument is Canton Coin today or a tokenized money-market fund share tomorrow.&lt;/p&gt;

&lt;h2&gt;
  
  
  What's live
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/plagtech/spraay-canton" rel="noopener noreferrer"&gt;&lt;code&gt;github.com/plagtech/spraay-canton&lt;/code&gt;&lt;/a&gt; runs against the cn-quickstart LocalNet. It exposes a REST API for batch payments, queries holdings via the Token Standard Holding interface, fetches the TransferFactory from the Scan-hosted registry, executes one &lt;code&gt;TransferFactory_Transfer&lt;/code&gt; per recipient, and collects the protocol fee through a second transfer to the operator party. Same shape as every other Spraay chain — just spoken in Daml.&lt;/p&gt;

&lt;p&gt;The repo is open, the integration is small, and the door's open if anyone building on Canton wants payment primitives or just wants to compare notes.&lt;/p&gt;

&lt;p&gt;Spraay now spans 16 chains. The interesting part isn't the count — it's that the span now goes from retail-facing chains all the way to the network where institutional tokenization is being built. That's a different kind of map than it was last year.&lt;/p&gt;

</description>
      <category>payments</category>
      <category>wallstreet</category>
      <category>x402</category>
      <category>spraay</category>
    </item>
    <item>
      <title>Spraay just introduced new endpoints for Solana Agents.</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Sat, 16 May 2026 00:34:34 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/spraay-just-introduced-new-endpoints-for-solana-agents-45fp</link>
      <guid>https://dev.to/mr_hamlin/spraay-just-introduced-new-endpoints-for-solana-agents-45fp</guid>
      <description>&lt;p&gt;If you've built a Solana DeFi agent recently, you know the shape of the work.&lt;/p&gt;

&lt;p&gt;You write a quote function. It calls Jupiter directly because that's where the liquidity is. Then you need wallet holdings, so you sign up for Helius and stick a key in &lt;code&gt;.env&lt;/code&gt;. Then you need price feeds, so you wire up Pyth Hermes. Three providers, three rate limits, three sets of error semantics, three keys to rotate. Your agent does six interesting things and you're managing eight pieces of infrastructure.&lt;/p&gt;

&lt;p&gt;I've been building Spraay — an x402 gateway — for several months, and as of today it speaks Solana DeFi natively. Six new endpoints, one gateway, payable per call in USDC. If you're somewhere in the middle of writing the agent I just described, this might save you a weekend.&lt;/p&gt;

&lt;h2&gt;
  
  
  What's new
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight http"&gt;&lt;code&gt;&lt;span class="err"&gt;GET  /api/v1/solana/jupiter/quote         $0.005
POST /api/v1/solana/jupiter/swap-tx       $0.01
GET  /api/v1/solana/helius/assets-by-owner $0.003
GET  /api/v1/solana/helius/asset          $0.002
GET  /api/v1/solana/pyth/price            $0.005
GET  /api/v1/solana/pyth/prices           $0.008
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;All six are pure proxies to the real upstream — Jupiter v6, Helius DAS, Pyth Hermes. No synthetic data, no mock responses. Spraay does payment, validation, error normalization, and Bazaar discovery. Your agent does everything else.&lt;/p&gt;

&lt;h2&gt;
  
  
  What you don't deal with
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;No accounts.&lt;/strong&gt; No signup, no email confirmation, no dashboard. Your agent's wallet is its identity.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No API keys.&lt;/strong&gt; Payment is the auth. You pay $0.005, you get the response.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No bridging.&lt;/strong&gt; Pay in either Solana USDC (SPL) or Base USDC (ERC-20). Spraay accepts both on every endpoint. Useful when your agent already has USDC on Base from doing other things.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No upstream rate-limit babysitting.&lt;/strong&gt; Spraay holds the paid tier with Helius and Jupiter. You see clean 402s on success, 429 with &lt;code&gt;retryAfter&lt;/code&gt; if upstream rate-limits us.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No custody risk on swaps.&lt;/strong&gt; Jupiter &lt;code&gt;swap-tx&lt;/code&gt; returns an unsigned &lt;code&gt;VersionedTransaction&lt;/code&gt;. Your wallet signs and submits. The gateway never touches keys.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Working code
&lt;/h2&gt;

&lt;p&gt;The integration that took me three days to do raw, ported to Spraay in about twenty minutes. The example below uses pseudocode for the payment client — drop in whatever x402 client you're already using:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;VersionedTransaction&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;Connection&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;@solana/web3.js&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c1"&gt;// Your x402 client of choice — handles the 402 → pay → retry flow&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;makeX402Client&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;baseUrl&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://gateway.spraay.app&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="c1"&gt;// Pay in Solana USDC, Base USDC, or both — your call&lt;/span&gt;
  &lt;span class="na"&gt;solanaPrivateKey&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;process&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;SOLANA_PRIVATE_KEY&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;connection&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Connection&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;process&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;SOLANA_RPC_URL&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="c1"&gt;// 1. Read the agent's wallet — SPL tokens, NFTs, native SOL balance, paginated&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;holdings&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/solana/helius/assets-by-owner&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt;
  &lt;span class="s2"&gt;`?owner=&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;myWallet&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;publicKey&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toBase58&lt;/span&gt;&lt;span class="p"&gt;()}&lt;/span&gt;&lt;span class="s2"&gt;&amp;amp;limit=100`&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`Wallet holds &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;holdings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;total&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt; assets, &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;holdings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;nativeBalance&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;lamports&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="nx"&gt;e9&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt; SOL`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="c1"&gt;// 2. Pull live prices for the agent's watchlist in one call&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;prices&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/solana/pyth/prices?feedIds=SOL,BTC,ETH,JUP,BONK&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;solPrice&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;prices&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;prices&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;SOL&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;price&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;  &lt;span class="c1"&gt;// e.g. 142.37&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;solConfidence&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;prices&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;prices&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;SOL&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;confidence&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;  &lt;span class="c1"&gt;// ± confidence interval&lt;/span&gt;

&lt;span class="c1"&gt;// 3. Quote a swap&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;quote&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/solana/jupiter/quote&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt;
  &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;?inputMint=USDC&amp;amp;outputMint=SOL&amp;amp;amount=10000000&amp;amp;slippageBps=50&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`10 USDC → &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nc"&gt;Number&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;quote&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;outAmount&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="nx"&gt;e9&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt; SOL via &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;quote&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;routeHops&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;-hop route`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="c1"&gt;// 4. Build the unsigned transaction&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;swap&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;post&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/solana/jupiter/swap-tx&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;quoteResponse&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;quote&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;raw&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;userPublicKey&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;myWallet&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;publicKey&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toBase58&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;
  &lt;span class="na"&gt;prioritizationFeeLamports&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;auto&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="c1"&gt;// 5. Sign and submit yourself — gateway never sees the key&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;tx&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;VersionedTransaction&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;deserialize&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="nx"&gt;Buffer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="k"&gt;from&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;swap&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;swapTransaction&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;base64&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;tx&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sign&lt;/span&gt;&lt;span class="p"&gt;([&lt;/span&gt;&lt;span class="nx"&gt;myWallet&lt;/span&gt;&lt;span class="p"&gt;]);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;sig&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;connection&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sendTransaction&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;tx&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`Swap submitted: https://solscan.io/tx/&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;sig&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Five operations, four endpoints, one payment rail. The agent pays the per-call cost out of its own wallet, gas-of-the-API-economy style.&lt;/p&gt;

&lt;h2&gt;
  
  
  Endpoint details, quickly
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Jupiter
&lt;/h3&gt;

&lt;p&gt;&lt;code&gt;/quote&lt;/code&gt; wraps &lt;code&gt;quote-api.jup.ag/v6/quote&lt;/code&gt; (or &lt;code&gt;api.jup.ag/swap/v1/quote&lt;/code&gt; on the paid tier — Spraay holds the key). Returns route plan, slippage, output amount, price impact. Accepts symbol aliases (&lt;code&gt;USDC&lt;/code&gt;, &lt;code&gt;SOL&lt;/code&gt;, &lt;code&gt;BONK&lt;/code&gt;, &lt;code&gt;WIF&lt;/code&gt;, &lt;code&gt;JUP&lt;/code&gt;, etc.) or raw base58 mints.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;/swap-tx&lt;/code&gt; wraps the &lt;code&gt;/swap&lt;/code&gt; endpoint. Returns a base64-encoded &lt;code&gt;VersionedTransaction&lt;/code&gt;. Pass the raw &lt;code&gt;quoteResponse&lt;/code&gt; from &lt;code&gt;/quote&lt;/code&gt; and your &lt;code&gt;userPublicKey&lt;/code&gt;. Optional: &lt;code&gt;wrapAndUnwrapSol&lt;/code&gt;, &lt;code&gt;prioritizationFeeLamports&lt;/code&gt;. Gateway never signs.&lt;/p&gt;

&lt;h3&gt;
  
  
  Helius DAS
&lt;/h3&gt;

&lt;p&gt;&lt;code&gt;/assets-by-owner&lt;/code&gt; wraps &lt;code&gt;getAssetsByOwner&lt;/code&gt;. Returns SPL tokens, regular NFTs, compressed NFTs, and native SOL balance in one paginated response. Default &lt;code&gt;limit=100&lt;/code&gt;, max &lt;code&gt;1000&lt;/code&gt;. &lt;code&gt;showFungible&lt;/code&gt; and &lt;code&gt;showNativeBalance&lt;/code&gt; both default &lt;code&gt;true&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;/asset&lt;/code&gt; wraps &lt;code&gt;getAsset&lt;/code&gt;. Returns full metadata for a single asset by mint or compressed NFT ID — image, attributes, royalty info, compression details, ownership.&lt;/p&gt;

&lt;h3&gt;
  
  
  Pyth
&lt;/h3&gt;

&lt;p&gt;&lt;code&gt;/price&lt;/code&gt; wraps Hermes &lt;code&gt;/v2/updates/price/latest&lt;/code&gt; for one feed. Returns the human-readable price (already scaled by &lt;code&gt;expo&lt;/code&gt;), confidence interval, publish time, and EMA price. Symbol aliases for the obvious ones (&lt;code&gt;SOL&lt;/code&gt;, &lt;code&gt;BTC&lt;/code&gt;, &lt;code&gt;ETH&lt;/code&gt;, &lt;code&gt;USDC&lt;/code&gt;, &lt;code&gt;USDT&lt;/code&gt;, &lt;code&gt;JUP&lt;/code&gt;, &lt;code&gt;PYTH&lt;/code&gt;, &lt;code&gt;BONK&lt;/code&gt;, &lt;code&gt;WIF&lt;/code&gt;, &lt;code&gt;JTO&lt;/code&gt;) or pass the 64-char hex feed ID.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;/prices&lt;/code&gt; is the batch version. Up to 50 feeds, comma-separated. Returns a &lt;code&gt;{ symbol: priceObject }&lt;/code&gt; map keyed by uppercase symbol.&lt;/p&gt;

&lt;h2&gt;
  
  
  Trying it before you integrate
&lt;/h2&gt;

&lt;p&gt;Every endpoint returns a clean &lt;code&gt;402 Payment Required&lt;/code&gt; with full x402 payment requirements when you call without paying. You can see the schema, pricing, and accepts arrays directly:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-i&lt;/span&gt; &lt;span class="s2"&gt;"https://gateway.spraay.app/api/v1/solana/pyth/price?feedId=SOL"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The 402 body includes both EVM and Solana payment options. Your x402 client picks the rail.&lt;/p&gt;

&lt;p&gt;If you want to see all six (plus the rest of Spraay's catalog) in Bazaar-discoverable form:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-s&lt;/span&gt; &lt;span class="s2"&gt;"https://gateway.spraay.app/.well-known/x402.json"&lt;/span&gt; | jq &lt;span class="s1"&gt;'.resources[] | select(.resource | contains("/solana/"))'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Error handling notes worth knowing
&lt;/h2&gt;

&lt;p&gt;A few things that will save debugging time:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;429 rate_limit&lt;/code&gt;&lt;/strong&gt; means we're being rate-limited by an upstream provider. Response includes &lt;code&gt;retryAfter&lt;/code&gt; in seconds. Backoff and retry.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;502 upstream_error&lt;/code&gt;&lt;/strong&gt; from any endpoint means the upstream returned a non-2xx. The body contains the actual upstream error in &lt;code&gt;detail&lt;/code&gt;. Useful for debugging slippage tolerance, missing feeds, etc.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;400 invalid_input_mint&lt;/code&gt;&lt;/strong&gt; etc. are pre-flight validation failures. Spraay never charges you if validation fails before the upstream call.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Pyth feed IDs&lt;/strong&gt; are case-sensitive hex. If you're not using aliases, lowercase everything or use the alias map.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Links
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Gateway: &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;gateway.spraay.app&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Full endpoint catalog: &lt;a href="https://docs.spraay.app" rel="noopener noreferrer"&gt;docs.spraay.app&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Smithery MCP server: &lt;a href="https://smithery.ai/server/@plagtech/spraay-x402-mcp" rel="noopener noreferrer"&gt;smithery.ai/server/@plagtech/spraay-x402-mcp&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;GitHub: &lt;a href="https://github.com/plagtech" rel="noopener noreferrer"&gt;github.com/plagtech&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you build something with this and it breaks, ping me — I respond fast and the roadmap is mostly driven by what builders actually ask for.&lt;/p&gt;

&lt;p&gt;💧&lt;/p&gt;

</description>
      <category>ai</category>
      <category>x402</category>
      <category>solana</category>
      <category>defi</category>
    </item>
    <item>
      <title>The First Batch Payment Skill for Vercel Agents (skills.sh)</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Fri, 15 May 2026 20:59:21 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/the-first-batch-payment-skill-for-vercel-agents-skillssh-21l</link>
      <guid>https://dev.to/mr_hamlin/the-first-batch-payment-skill-for-vercel-agents-skillssh-21l</guid>
      <description>&lt;p&gt;Spraay Protocol just shipped as a &lt;a href="https://github.com/plagtech/spraay-agent-skills" rel="noopener noreferrer"&gt;Vercel-compatible agent skill&lt;/a&gt;. One command gives any AI coding agent the ability to batch-send crypto to hundreds of recipients in a single transaction — across 15 blockchains.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx skills add plagtech/spraay-agent-skills
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's it. Claude Code, Cursor, GitHub Copilot, Codex, Gemini CLI, and 12+ other agents can now build batch payment workflows using Spraay.&lt;/p&gt;

&lt;h2&gt;
  
  
  What problem does this solve?
&lt;/h2&gt;

&lt;p&gt;Sending crypto to multiple people is painful. Whether it's payroll for a remote team, an airdrop for a token community, bounty payouts for contributors, or a DAO treasury distribution — the standard approach is sending individual transactions one at a time.&lt;/p&gt;

&lt;p&gt;That means paying gas on every single transfer, manually entering each address, and hoping you don't make a mistake on transaction 47 of 200.&lt;/p&gt;

&lt;p&gt;Spraay bundles all of those into one on-chain transaction. Up to 200+ recipients, ~80% gas savings, 0.3% protocol fee.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why an agent skill?
&lt;/h2&gt;

&lt;p&gt;AI agents are increasingly handling real workflows — not just answering questions, but taking actions. An agent managing a DAO treasury should be able to say "distribute 10,000 USDC across these 50 contributors" and execute it.&lt;/p&gt;

&lt;p&gt;Vercel recently launched their &lt;a href="https://github.com/vercel-labs/skills" rel="noopener noreferrer"&gt;Skills CLI&lt;/a&gt; and &lt;a href="https://skills.sh" rel="noopener noreferrer"&gt;skills.sh&lt;/a&gt; directory — an open ecosystem for packaging capabilities that any AI agent can install and use. Skills are simple: a &lt;code&gt;SKILL.md&lt;/code&gt; file teaches the agent what the tool does, when to use it, and how to call it. No SDKs to integrate, no code to write.&lt;/p&gt;

&lt;p&gt;When an agent reads the Spraay skill, it knows:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;How to call the batch payment gateway&lt;/li&gt;
&lt;li&gt;Which 15 chains are supported&lt;/li&gt;
&lt;li&gt;What the request format looks like&lt;/li&gt;
&lt;li&gt;How the 0.3% fee works&lt;/li&gt;
&lt;li&gt;That it should always confirm with the user before signing&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The agent becomes payment-capable in one install.&lt;/p&gt;

&lt;h2&gt;
  
  
  What's covered
&lt;/h2&gt;

&lt;p&gt;The skill focuses on one thing: batch payments. Five types:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Native token batches&lt;/strong&gt; — ETH, SOL, MATIC, BNB, AVAX, XLM, XRP, BTC, TAO, STX&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ERC-20 / SPL token batches&lt;/strong&gt; — USDC, DAI, WETH, or any token contract&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Equal-amount batches&lt;/strong&gt; — same amount to every recipient&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Variable-amount batches&lt;/strong&gt; — different amounts per recipient&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;CSV import batches&lt;/strong&gt; — upload a spreadsheet of addresses and amounts&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  15 chains, real contracts
&lt;/h2&gt;

&lt;p&gt;Every EVM chain has a verified, deployed batch contract:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Chain&lt;/th&gt;
&lt;th&gt;Contract&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Base&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0x1646452F98E36A3c9Cfc3eDD8868221E207B5eEC&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Ethereum&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0x15E7aEDa45094DD2E9E746FcA1C726cAd7aE58b3&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Arbitrum&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0x5be43aA67804aD84fcb890d0AE5F257fb1674302&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Polygon&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0x6d2453ab7416c99aeDCA47CF552695be5789D7ff&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;BNB Chain&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0x3093a2951FB77b3beDfB8BA20De645F7413432C1&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Avalanche&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0x6A41Fb5F5CfE632f9446b548980dA6cE2d75afcC&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Unichain&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0x08fA5D1c16CD6E2a16FC0E4839f262429959E073&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Plasma&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0x08fA5D1c16CD6E2a16FC0E4839f262429959E073&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;BOB&lt;/td&gt;
&lt;td&gt;&lt;code&gt;0xEc8599026AE70898391a71c96AA82d4840C2e973&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Plus non-EVM chains with chain-native implementations: Solana (SPL batch), Stellar (multi-operation), Bitcoin (PSBT), XRP Ledger (sequential payments), Bittensor (&lt;code&gt;utility.batchAll&lt;/code&gt;), and Stacks (Clarity contract).&lt;/p&gt;

&lt;p&gt;These aren't testnet demos. They're live, verified contracts handling real value.&lt;/p&gt;

&lt;h2&gt;
  
  
  How the gateway works
&lt;/h2&gt;

&lt;p&gt;The Spraay gateway at &lt;code&gt;gateway.spraay.app&lt;/code&gt; uses the x402 payment protocol — the HTTP 402 standard that Coinbase helped pioneer for machine-to-machine payments.&lt;/p&gt;

&lt;p&gt;The flow is simple:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Agent sends a batch request to the gateway&lt;/li&gt;
&lt;li&gt;Gateway returns unsigned transaction data bundling all transfers&lt;/li&gt;
&lt;li&gt;User reviews and signs in their wallet&lt;/li&gt;
&lt;li&gt;All recipients get paid in one on-chain transaction&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Gateway access costs $0.02 USDC per call, paid automatically via x402 on Base. No API keys, no accounts, no subscriptions.&lt;/p&gt;

&lt;h2&gt;
  
  
  Quick integration
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;createClient&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;x402-client&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;createClient&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="na"&gt;baseUrl&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://gateway.spraay.app&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;privateKey&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;process&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;EVM_PRIVATE_KEY&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;tx&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;post&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;/api/v1/batch/execute&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="na"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;USDC&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;recipients&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;address&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xAlice&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;amount&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;100.00&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;address&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xBob&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;amount&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;50.00&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;address&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xCarol&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;amount&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;25.00&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;]&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Or skip the code entirely — users can batch-send at &lt;a href="https://spraay.app" rel="noopener noreferrer"&gt;spraay.app&lt;/a&gt; by connecting their wallet and adding recipients or uploading a CSV.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where this fits in the Vercel ecosystem
&lt;/h2&gt;

&lt;p&gt;Vercel's agent skills ecosystem is growing fast. There are skills for React best practices, deployment automation, and web design guidelines. Crypto is starting to show up — Crypto.com published a trading skill, and community repos are covering DeFi yield and sentiment analysis.&lt;/p&gt;

&lt;p&gt;But nobody had batch payments. It's a gap that matters because every on-chain organization eventually needs to pay multiple people, and doing it manually doesn't scale.&lt;/p&gt;

&lt;p&gt;Spraay fills that gap with deployed infrastructure across 15 chains, not a wrapper around someone else's API.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it
&lt;/h2&gt;

&lt;p&gt;Install the skill:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npx skills add plagtech/spraay-agent-skills
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Or use the dApp directly: &lt;a href="https://spraay.app" rel="noopener noreferrer"&gt;spraay.app&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Full gateway docs: &lt;a href="https://docs.spraay.app" rel="noopener noreferrer"&gt;docs.spraay.app&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The MCP server is also on Smithery if you're building with MCP-compatible agents: &lt;a href="https://smithery.ai/server/@plagtech/spraay-x402-mcp" rel="noopener noreferrer"&gt;@plagtech/spraay-x402-mcp&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Spraay Protocol is built by &lt;a href="https://github.com/plagtech" rel="noopener noreferrer"&gt;@plagtech&lt;/a&gt;. Follow &lt;a href="https://twitter.com/Spraay_app" rel="noopener noreferrer"&gt;@Spraay_app&lt;/a&gt; for updates.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>vercel</category>
      <category>ai</category>
      <category>agentskills</category>
      <category>agents</category>
    </item>
    <item>
      <title>💧 Spraay x402 Gateway Now Accepts Solana USDC — Dual-Chain AI Agent Payments Are Live</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Wed, 13 May 2026 04:27:37 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/spraay-x402-gateway-now-accepts-solana-usdc-dual-chain-ai-agent-payments-are-live-4bb2</link>
      <guid>https://dev.to/mr_hamlin/spraay-x402-gateway-now-accepts-solana-usdc-dual-chain-ai-agent-payments-are-live-4bb2</guid>
      <description>&lt;p&gt;Your AI agent holds USDC on Solana. The API it needs to call takes payment on Base. Until today, that meant bridging, swapping, or just not making the call.&lt;/p&gt;

&lt;p&gt;Not anymore.&lt;/p&gt;

&lt;h2&gt;
  
  
  What We Shipped
&lt;/h2&gt;

&lt;p&gt;The Spraay x402 Gateway — 93+ paid endpoints covering AI inference, batch payments, DeFi, oracle data, escrow, payroll, robotics, supply chain, and more — now accepts USDC on both &lt;strong&gt;Base&lt;/strong&gt; and &lt;strong&gt;Solana mainnet&lt;/strong&gt; through the official x402 protocol.&lt;/p&gt;

&lt;p&gt;Every gated endpoint returns a 402 challenge with two &lt;code&gt;accepts&lt;/code&gt; entries. The agent picks whichever chain it holds funds on. No bridging, no extra steps.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"accepts"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"scheme"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"exact"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"price"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"$0.008"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"network"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"eip155:8453"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"payTo"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"0xAd62f03C7514bb8c51f1eA70C2b75C37404695c8"&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"scheme"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"exact"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"price"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"$0.008"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"network"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"payTo"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"8WhWE8YgY5QBWyLowEHuaZiWdwDM3SrgDk36xYBNvYNS"&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Three Payment Rails, One Gateway
&lt;/h2&gt;

&lt;p&gt;The gateway now supports three concurrent payment methods on every route:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. x402 EVM (Base)&lt;/strong&gt; — The original rail. Coinbase CDP facilitator handles verification and settlement. Sub-cent gas on Base.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. x402 SVM (Solana)&lt;/strong&gt; — New. Uses the official &lt;code&gt;@x402/svm&lt;/code&gt; SDK with &lt;code&gt;ExactSvmScheme&lt;/code&gt;. Same Coinbase facilitator. 400ms finality, ~$0.00025 tx fees. Fully compatible with pay.sh, xpay, and every x402 client.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Custom Solana (X-Solana-Tx header)&lt;/strong&gt; — A direct SPL USDC transfer fallback. Agent sends USDC to the receive address, retries with the tx signature in a header, gateway verifies on-chain via &lt;code&gt;@solana/web3.js&lt;/code&gt;. Works for agents that don't speak x402.&lt;/p&gt;

&lt;p&gt;All three are active simultaneously. None interfere with each other.&lt;/p&gt;

&lt;h2&gt;
  
  
  How It Works (Agent Perspective)
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Agent calls GET /api/v1/oracle/prices
  → Gateway returns 402 with accepts[] (Base + Solana)

Agent inspects accepts[], picks solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp
  → Signs USDC transfer authorization

Agent retries with X-PAYMENT header containing signed payload
  → Coinbase facilitator verifies + settles on Solana
  → Gateway returns 200 with oracle data
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The entire flow is one round-trip after the initial 402. No accounts, no API keys, no subscriptions.&lt;/p&gt;

&lt;h2&gt;
  
  
  Discovery Endpoints
&lt;/h2&gt;

&lt;p&gt;Agents can auto-discover payment options at:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;/.well-known/x402.json&lt;/code&gt; — Full resource catalog with pricing&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;/.well-known/solana.json&lt;/code&gt; — Solana-specific payment config&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;/.well-known/agent-registration.json&lt;/code&gt; — Agent framework metadata&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;/.well-known/mpp.json&lt;/code&gt; — MPP/Stripe support (also active)&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What's Covered
&lt;/h2&gt;

&lt;p&gt;93+ paid endpoints across 21 categories:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;AI Inference&lt;/strong&gt; — 200+ models via OpenRouter + 43 Bittensor models (SN64)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Batch Payments&lt;/strong&gt; — Base, Stellar, XRP, up to 200 recipients&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;DeFi&lt;/strong&gt; — Swaps, bridge quotes, position tracking&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Oracle&lt;/strong&gt; — Prices, gas, FX rates&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Payroll&lt;/strong&gt; — Crypto payroll execution and estimation&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Escrow&lt;/strong&gt; — Create, fund, release, cancel with milestones&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Infrastructure&lt;/strong&gt; — RPC, IPFS, cron, logging, webhooks&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Robotics (RTP)&lt;/strong&gt; — Dispatch physical tasks to robots via x402&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Supply Chain (SCTP)&lt;/strong&gt; — Suppliers, POs, invoices, AI verification&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Agent Wallets&lt;/strong&gt; — Provision smart contract wallets on Base&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;And more&lt;/strong&gt; — KYC, auth, audit, tax, GPU compute, search/RAG, XMTP messaging&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;All of these now accept payment on Base or Solana.&lt;/p&gt;

&lt;h2&gt;
  
  
  Technical Implementation
&lt;/h2&gt;

&lt;p&gt;For anyone building a similar dual-chain x402 server, the key pieces are:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;ExactSvmScheme&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;@x402/svm/exact/server&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c1"&gt;// Register both schemes&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;server&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nf"&gt;x402ResourceServer&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;facilitatorClient&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;register&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;eip155:8453&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;ExactEvmScheme&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;
&lt;span class="nx"&gt;server&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;register&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;ExactSvmScheme&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;

&lt;span class="c1"&gt;// Each route gets dual accepts&lt;/span&gt;
&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;GET /api/v1/oracle/prices&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;accepts&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;scheme&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;exact&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;price&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;$0.008&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;network&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;eip155:8453&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;payTo&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;evmAddress&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;scheme&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;exact&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;price&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;$0.008&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;network&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="na"&gt;payTo&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;solanaAddress&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="p"&gt;],&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The Coinbase CDP facilitator handles both EVM and SVM verification — no need to run your own.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try It
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# See the dual-chain 402 challenge&lt;/span&gt;
curl https://gateway.spraay.app/api/v1/oracle/prices

&lt;span class="c"&gt;# Solana discovery&lt;/span&gt;
curl https://gateway.spraay.app/.well-known/solana.json

&lt;span class="c"&gt;# With pay.sh (Solana wallet)&lt;/span&gt;
pay curl https://gateway.spraay.app/api/v1/oracle/prices?tokens&lt;span class="o"&gt;=&lt;/span&gt;ETH
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Links
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Gateway&lt;/strong&gt;: &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;gateway.spraay.app&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Docs&lt;/strong&gt;: &lt;a href="https://docs.spraay.app" rel="noopener noreferrer"&gt;docs.spraay.app&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;GitHub&lt;/strong&gt;: &lt;a href="https://github.com/plagtech/spraay-x402-gateway" rel="noopener noreferrer"&gt;plagtech/spraay-x402-gateway&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;MCP Server&lt;/strong&gt;: &lt;a href="https://smithery.ai/server/@plagtech/spraay-x402-mcp" rel="noopener noreferrer"&gt;@plagtech/spraay-x402-mcp on Smithery&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;X&lt;/strong&gt;: &lt;a href="https://twitter.com/Spraay_app" rel="noopener noreferrer"&gt;@Spraay_app&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;The x402 ecosystem is moving fast. Solana support in the protocol means agents on either chain can pay for APIs without bridging. We're live on both. Build something.&lt;/p&gt;

</description>
      <category>x402</category>
      <category>solana</category>
      <category>ai</category>
      <category>web3</category>
    </item>
    <item>
      <title>Spraay Gateway Now Accepts Credit Cards — 80+ API Endpoints, No Crypto Wallet Required</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Fri, 08 May 2026 02:54:47 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/spraay-gateway-now-accepts-credit-cards-80-api-endpoints-no-crypto-wallet-required-4dj3</link>
      <guid>https://dev.to/mr_hamlin/spraay-gateway-now-accepts-credit-cards-80-api-endpoints-no-crypto-wallet-required-4dj3</guid>
      <description>&lt;p&gt;I've been building &lt;a href="https://spraay.app" rel="noopener noreferrer"&gt;Spraay&lt;/a&gt; — a multi-chain payment gateway where AI agents pay per API call using the x402 protocol and USDC on Base. 88 endpoints across AI inference, batch payments, DeFi, oracle data, escrow, robotics, and more.&lt;/p&gt;

&lt;p&gt;The x402 model works great for crypto-native developers and autonomous agents. But I kept hearing the same thing from traditional devs:&lt;/p&gt;

&lt;p&gt;&lt;em&gt;"This looks useful, but I don't want to set up a wallet and buy USDC just to test your API."&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Fair point. So today I'm launching a &lt;strong&gt;traditional subscription tier&lt;/strong&gt; alongside x402 — pay with a credit card, get an API key, start building.&lt;/p&gt;

&lt;h2&gt;
  
  
  Two Ways to Use Spraay
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Pay-per-call (x402)&lt;/strong&gt; — No signup. Your agent pays USDC per request on Base. This is how autonomous agents use it. Prices range from $0.001 to $0.10 per call depending on the endpoint.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Monthly subscription (Stripe)&lt;/strong&gt; — Sign up with your email, pay with a card, get an API key emailed to you. Add &lt;code&gt;X-API-Key&lt;/code&gt; to your requests and you're in.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Plan&lt;/th&gt;
&lt;th&gt;Price&lt;/th&gt;
&lt;th&gt;Daily Calls&lt;/th&gt;
&lt;th&gt;Endpoints&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Pay-per-call&lt;/td&gt;
&lt;td&gt;USDC per request&lt;/td&gt;
&lt;td&gt;Unlimited&lt;/td&gt;
&lt;td&gt;All 80+&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Starter&lt;/td&gt;
&lt;td&gt;$29/month&lt;/td&gt;
&lt;td&gt;1,000/day&lt;/td&gt;
&lt;td&gt;All 80+&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Pro&lt;/td&gt;
&lt;td&gt;$99/month&lt;/td&gt;
&lt;td&gt;10,000/day&lt;/td&gt;
&lt;td&gt;All 80+&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Both paths hit the same endpoints. Same data, same infrastructure, same uptime.&lt;/p&gt;

&lt;h2&gt;
  
  
  What You Get Access To
&lt;/h2&gt;

&lt;p&gt;Here's a sample of what's behind the gateway:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;AI Inference&lt;/strong&gt; — 200+ models via OpenRouter + 43 models on Bittensor (OpenAI-compatible drop-in)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Batch Payments&lt;/strong&gt; — Send tokens to 200 recipients in one transaction across 15 chains&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;DeFi&lt;/strong&gt; — Swap quotes and execution via Uniswap V3, cross-chain bridge quotes&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Oracle&lt;/strong&gt; — Real-time token prices, gas prices, FX rates&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Search/RAG&lt;/strong&gt; — Web search, content extraction, Q&amp;amp;A with sources&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;GPU Compute&lt;/strong&gt; — Image generation, video, audio via Replicate&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Agent Wallets&lt;/strong&gt; — Provision ERC-4337 smart wallets for AI agents&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Escrow&lt;/strong&gt; — Milestone-based conditional escrow contracts&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Robot Task Protocol&lt;/strong&gt; — Dispatch tasks to physical robots via x402&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Plus:&lt;/strong&gt; Payroll, invoicing, KYC, audit trails, XMTP messaging, IPFS storage, cron scheduling, and more
Full docs at &lt;a href="https://docs.spraay.app" rel="noopener noreferrer"&gt;docs.spraay.app&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  How Subscriptions Work
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;Pick a plan at &lt;a href="https://spraay.app/#pricing" rel="noopener noreferrer"&gt;spraay.app/pricing&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Enter your email → redirected to Stripe Checkout&lt;/li&gt;
&lt;li&gt;Pay → API key emailed to you instantly&lt;/li&gt;
&lt;li&gt;Add &lt;code&gt;X-API-Key: spry_your_key&lt;/code&gt; header to any request&lt;/li&gt;
&lt;li&gt;That's it — no 402 payment flow, no wallet, no USDC
Check your usage anytime:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"X-API-Key: spry_your_key"&lt;/span&gt; https://gateway.spraay.app/v1/auth/usage
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Rotate your key if compromised:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; POST &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"X-API-Key: spry_your_key"&lt;/span&gt; https://gateway.spraay.app/v1/auth/rotate
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Manage billing through Stripe's customer portal — update card, change plans, cancel.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why Both Models?
&lt;/h2&gt;

&lt;p&gt;x402 is the future for agent-to-agent payments. An AI agent with a USDC balance can autonomously discover and pay for API calls without any human in the loop. That's powerful.&lt;/p&gt;

&lt;p&gt;But not every developer is building autonomous agents. Some just want to hit an oracle endpoint for price data, or run a batch payment from their backend. For them, a traditional API key is the fastest path.&lt;/p&gt;

&lt;p&gt;Spraay supports both — and the gateway doesn't care which one you use. If your request has an API key, it's validated and served. If it doesn't, the x402 payment flow kicks in. Same endpoints, same responses.&lt;/p&gt;

&lt;h2&gt;
  
  
  Built on Base
&lt;/h2&gt;

&lt;p&gt;Everything runs on Base mainnet. The batch payment contract is verified at &lt;a href="https://basescan.org/address/0x1646452F98E36A3c9Cfc3eDD8868221E207B5eEC" rel="noopener noreferrer"&gt;&lt;code&gt;0x1646452F98E36A3c9Cfc3eDD8868221E207B5eEC&lt;/code&gt;&lt;/a&gt;. Part of the Base Build program.&lt;/p&gt;

&lt;p&gt;Recently merged into &lt;a href="https://github.com/google/adk-python" rel="noopener noreferrer"&gt;Google Agent Development Kit&lt;/a&gt; as an integration, and live on &lt;a href="https://smithery.ai/server/@plagtech/spraay-x402-mcp" rel="noopener noreferrer"&gt;Smithery&lt;/a&gt; as an MCP server with 60+ tools.&lt;/p&gt;

&lt;h2&gt;
  
  
  Get Started
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Pricing &amp;amp; signup:&lt;/strong&gt; &lt;a href="https://spraay.app/#pricing" rel="noopener noreferrer"&gt;spraay.app/#pricing&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Docs:&lt;/strong&gt; &lt;a href="https://docs.spraay.app" rel="noopener noreferrer"&gt;docs.spraay.app&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Gateway:&lt;/strong&gt; &lt;a href="https://gateway.spraay.app" rel="noopener noreferrer"&gt;gateway.spraay.app&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;GitHub:&lt;/strong&gt; &lt;a href="https://github.com/plagtech" rel="noopener noreferrer"&gt;github.com/plagtech&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Twitter:&lt;/strong&gt; &lt;a href="https://twitter.com/Spraay_app" rel="noopener noreferrer"&gt;@Spraay_app&lt;/a&gt;
If you have questions, drop a comment or reach out on Twitter. Happy to walk through integration.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>api</category>
      <category>webdev</category>
      <category>ai</category>
      <category>crypto</category>
    </item>
    <item>
      <title>How to pay 100 agents in a single x402 call</title>
      <dc:creator>Mr Hamlin</dc:creator>
      <pubDate>Sat, 25 Apr 2026 04:51:15 +0000</pubDate>
      <link>https://dev.to/mr_hamlin/how-to-pay-100-agents-in-a-single-x402-call-1243</link>
      <guid>https://dev.to/mr_hamlin/how-to-pay-100-agents-in-a-single-x402-call-1243</guid>
      <description>&lt;p&gt;You're building an agent that pays for things. It pulls market data, hits an inference endpoint, fans out USDC to 50 freelancers, and writes a row to your database. Four steps.&lt;/p&gt;

&lt;p&gt;Three of those steps are one HTTP call each. The fourth — paying 50 people — is 50 transactions, 50 nonces to track, 50 places where something can fail halfway. Your "agent" spends 90% of its runtime managing payment loops.&lt;/p&gt;

&lt;p&gt;This is the part of the agent stack that nobody talks about. The x402 marketplace today is full of read-side services: Anthropic, OpenAI, CoinGecko, Exa, Perplexity. They give your agent inputs. None of them help your agent fan money outward.&lt;/p&gt;

&lt;p&gt;That's the gap I've been building into for the last few months. This post is a quick tour of why batch settlement matters, why it's the right primitive for the agent economy, and how to actually use it in your code right now.&lt;/p&gt;

&lt;h2&gt;
  
  
  The cost of doing it wrong
&lt;/h2&gt;

&lt;p&gt;Let's get specific. Say your agent needs to pay 50 USDC recipients on Base. Doing it the obvious way — one ERC-20 transfer per recipient — looks like this:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Approach&lt;/th&gt;
&lt;th&gt;Transactions&lt;/th&gt;
&lt;th&gt;Total Gas&lt;/th&gt;
&lt;th&gt;Wall-Clock Time&lt;/th&gt;
&lt;th&gt;Failure Modes&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;50 sequential transfers&lt;/td&gt;
&lt;td&gt;50&lt;/td&gt;
&lt;td&gt;~3,300,000&lt;/td&gt;
&lt;td&gt;60-120 seconds&lt;/td&gt;
&lt;td&gt;Per-tx revert, nonce gaps, RPC drops&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;50 parallel transfers&lt;/td&gt;
&lt;td&gt;50&lt;/td&gt;
&lt;td&gt;~3,300,000&lt;/td&gt;
&lt;td&gt;5-15 seconds&lt;/td&gt;
&lt;td&gt;Nonce conflicts, replacement underpriced&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;1 batch call&lt;/td&gt;
&lt;td&gt;1&lt;/td&gt;
&lt;td&gt;~280,000&lt;/td&gt;
&lt;td&gt;2-3 seconds&lt;/td&gt;
&lt;td&gt;Atomic — all or none&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The batch path saves ~92% of the gas and roughly an order of magnitude on wall-clock time. More importantly, it's atomic: either all 50 transfers land in the same block, or none do. Your agent never has to reconcile partial state.&lt;/p&gt;

&lt;p&gt;If you've ever built a payroll system, an airdrop tool, a marketplace payout, or an AI agent that distributes rewards, you know exactly why this matters. Partial state is where bugs live.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why x402 needs this primitive
&lt;/h2&gt;

&lt;p&gt;The x402 protocol is beautifully simple: a server responds with &lt;code&gt;402 Payment Required&lt;/code&gt;, the client attaches a payment proof, the server returns the resource. It works because each request is a single payment unit.&lt;/p&gt;

&lt;p&gt;But the agent economy isn't single-recipient. Real workflows look like this:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A research agent buys 10 different data sources for one report, then pays the user a share back.&lt;/li&gt;
&lt;li&gt;A trading agent settles fees to multiple liquidity providers in a single decision cycle.&lt;/li&gt;
&lt;li&gt;A supply chain agent pays a supplier, the carrier, and the inspector when an invoice clears.&lt;/li&gt;
&lt;li&gt;A DAO treasury agent distributes monthly payments to 200 contributors.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Each of those workflows works &lt;em&gt;through&lt;/em&gt; x402, but the payment leg currently has to fall back to a non-x402 path — ethers, viem, custom batch contracts, or a centralized service. That's friction. And friction is where adoption dies.&lt;/p&gt;

&lt;p&gt;So I built the missing piece: an x402 endpoint that takes a list of recipients and amounts, and settles all of them in a single on-chain transaction.&lt;/p&gt;

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

&lt;p&gt;The Spraay gateway exposes batch settlement as a paid x402 resource. One call in, one transaction out, atomic across all recipients.&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 https://gateway.spraay.app/api/v1/batch/execute
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Request shape:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"token"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"USDC"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"sender"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"0xYourAgentWallet"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"recipients"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="s2"&gt;"0xRecipient1"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="s2"&gt;"0xRecipient2"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="s2"&gt;"0xRecipient3"&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"amounts"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="s2"&gt;"1000000"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="s2"&gt;"2500000"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="s2"&gt;"750000"&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Amounts are in token-base units (USDC has 6 decimals, so &lt;code&gt;1000000&lt;/code&gt; = 1 USDC). The cost is $0.02 in USDC paid via x402, regardless of recipient count — economics get better the more recipients you have.&lt;/p&gt;

&lt;p&gt;The endpoint hits a batch contract on Base (&lt;code&gt;0x1646452F98E36A3c9Cfc3eDD8868221E207B5eEC&lt;/code&gt;), which loops the transfers in a single transaction. Either every recipient gets paid in the same block, or the whole call reverts.&lt;/p&gt;

&lt;h2&gt;
  
  
  Calling it from an agent
&lt;/h2&gt;

&lt;p&gt;Any HTTP client that speaks x402 can hit this endpoint. The simplest path is the official &lt;code&gt;x402-fetch&lt;/code&gt; wrapper — it handles the 402 challenge automatically:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;wrapFetchWithPayment&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;x402-fetch&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;createWalletClient&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;http&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;viem&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;privateKeyToAccount&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;viem/accounts&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;base&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;viem/chains&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;account&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;privateKeyToAccount&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;process&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;env&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;AGENT_PRIVATE_KEY&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;wallet&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;createWalletClient&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
  &lt;span class="nx"&gt;account&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;chain&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;base&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="na"&gt;transport&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nf"&gt;http&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;fetchWithPayment&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;wrapFetchWithPayment&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;fetch&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;wallet&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;response&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nf"&gt;fetchWithPayment&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;https://gateway.spraay.app/api/v1/batch/execute&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="na"&gt;method&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;POST&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Content-Type&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;application/json&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="na"&gt;body&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;JSON&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;stringify&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
      &lt;span class="na"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;USDC&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="na"&gt;sender&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nx"&gt;account&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;address&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="na"&gt;recipients&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
        &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xRecipient1...&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xRecipient2...&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;0xRecipient3...&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="p"&gt;],&lt;/span&gt;
      &lt;span class="na"&gt;amounts&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;1000000&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;2500000&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;750000&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
    &lt;span class="p"&gt;}),&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;response&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="nx"&gt;console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;Batch tx hash:&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;result&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;txHash&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's the whole integration. Three recipients, fifty recipients, two hundred recipients — same code shape, same gas profile per call.&lt;/p&gt;

&lt;p&gt;If you're not using &lt;code&gt;x402-fetch&lt;/code&gt;, the manual flow is:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;code&gt;POST&lt;/code&gt; to the endpoint with no payment header. You get back &lt;code&gt;402 Payment Required&lt;/code&gt; with a JSON body describing the price and the facilitator.&lt;/li&gt;
&lt;li&gt;Sign a USDC transfer authorization for the price ($0.02) to the &lt;code&gt;payTo&lt;/code&gt; address from the response.&lt;/li&gt;
&lt;li&gt;Re-&lt;code&gt;POST&lt;/code&gt; with the signature in the &lt;code&gt;X-PAYMENT&lt;/code&gt; header.&lt;/li&gt;
&lt;li&gt;Get back your batch result with the on-chain tx hash.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Where this fits in a larger agent
&lt;/h2&gt;

&lt;p&gt;Batch settlement is most useful as a primitive that other things compose on top of. A few patterns I've seen agents use:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Periodic distribution.&lt;/strong&gt; A cron-driven agent that pulls revenue, splits it across stakeholders, and pays them out weekly. One batch call per cycle.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Marketplace payouts.&lt;/strong&gt; A listing platform agent that resolves orders end-of-day and pays sellers atomically.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Multi-hop settlement.&lt;/strong&gt; An agent that pays an LLM provider, a search provider, and a vector DB provider all from the same workflow's budget — batched so the user is charged once, atomically.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Agent-to-agent commerce.&lt;/strong&gt; When agents subcontract work to other agents, the paying agent can settle the entire delegation tree in one call rather than chaining individual payments.&lt;/p&gt;

&lt;p&gt;The Spraay gateway has 90+ other x402 endpoints — agent wallet provisioning, on-chain DeFi positions, contract reads/writes, multi-chain RPC, AI inference (including a Bittensor drop-in at &lt;code&gt;/bittensor/v1&lt;/code&gt;), oracle data, and more — but batch settlement is the one that nothing else on the x402 marketplace currently offers. Everything else is competitive; this one is structurally unique.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it
&lt;/h2&gt;

&lt;p&gt;The simplest sanity test: hit the endpoint without payment and watch the 402 challenge come back.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-i&lt;/span&gt; &lt;span class="nt"&gt;-X&lt;/span&gt; POST https://gateway.spraay.app/api/v1/batch/execute &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="s1"&gt;'{"token":"USDC","sender":"0x...","recipients":["0x..."],"amounts":["1000000"]}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You'll get a &lt;code&gt;402 Payment Required&lt;/code&gt; response with the payment requirements. That confirms the endpoint is live and gated. From there, drop in &lt;code&gt;x402-fetch&lt;/code&gt; (or your favorite x402 client) and you're paying batch in five minutes.&lt;/p&gt;

&lt;p&gt;The endpoint works on Base mainnet today. If you're building anything that fans money outward — payroll, airdrops, multi-recipient agent workflows, marketplace payouts — give it a try and let me know what breaks. I read every reply.&lt;/p&gt;

&lt;p&gt;Discovery doc with the full endpoint catalog: &lt;code&gt;https://gateway.spraay.app/.well-known/x402.json&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Build something. Pay everyone. In one call.&lt;/p&gt;

&lt;p&gt;— &lt;a href="https://dev.to/mr_hamlin"&gt;@mr_hamlin&lt;/a&gt;&lt;/p&gt;

</description>
      <category>x402</category>
      <category>web3</category>
      <category>agents</category>
      <category>base</category>
    </item>
  </channel>
</rss>
