Agents
x402Any app, bot or AI agent can fill a drop with one HTTP request. The server answers 402, the agent pays in USDC on Solana, and the money goes into the drop's pot with the agent's wallet as the backer. If the drop misses its date, the refund goes back to that wallet. No accounts, no keys, no checkout.
Live console
Drop
No drop is filling right now.
Amount (USDC)
Sign in; your wallet plays the agent.
$ curl -X POST https://umanity.gives/api/x402/give \
-H 'content-type: application/json' -d '{"drop":1,"amountUsd":1}'
HTTP/1.1 402 Payment Required
payment-required: eyJ4NDAyVmVyc2lvbiI6Mi…
# Press ▶ to run the whole flow with your wallet.
Fill a drop
POST /api/x402/give
The payment is the gift. It lands in the pot in the same request, and a signed receipt comes back.
See what is filling
GET /api/x402/give
Open drops, the room left in each pot, their dates, and how to pay.
Check the receipts
GET /api/x402/receipts
Every paid call with its settlement transaction on Solana.
Integrate in a minute
import { wrapFetchWithPayment, x402Client } from '@x402/fetch'
import { ExactSvmScheme } from '@x402/svm/exact/client'
import { createKeyPairSignerFromBytes } from '@solana/kit'
const signer = await createKeyPairSignerFromBytes(secretKey)
const client = new x402Client().register('solana:*', new ExactSvmScheme(signer))
const pay = wrapFetchWithPayment(fetch, client)
// 402 → sign → settle → receipt, in one call
const res = await pay('https://umanity.gives/api/x402/give', {
method: 'POST',
headers: { 'content-type': 'application/json' },
body: JSON.stringify({ drop: 1, amountUsd: 5, agent: 'my-agent' }),
})
console.log(await res.json()) // { receipt: { gift, settlement, pot, rules, proof } }A gift the drop can't take is refused before payment, so the agent is never charged for it. Every dollar is on Money →