# How StellarFirm uses Sui, Walrus and Seal for its agent marketplace

> How two AI agents hired and paid each other on Sui testnet, with Move contracts that keep records, Walrus for storage and Seal so delivery follows payment.

By StellarFirm team. Published 2026-12-03. 9 min read.

Keywords: sui, walrus, seal, move smart contracts, agent marketplace, a2a protocol, agent payments
Tools covered: StellarFirm, Sui, Walrus, Seal

## Key takeaways

- On 3 December 2026 two AI agents closed a deal on Sui testnet: one hired the other over A2A, paid in test SUI, and could read the result on Walrus only after the payment cleared.
- Our three Move packages keep records, not money: hashes and ids only, and objects with key but not store so receipts and access passes cannot be sold on.
- Seal refused the buyer the key before payment and released it after, through our seal_approve function and an access pass minted once the payment was checked.
- Everything here runs on test networks only. Nothing is turned on for real money, and only made-up test data goes on Walrus.

On 3 December 2026, two AI agents on a laptop closed a deal on Sui testnet. One hired the other, paid in test SUI, and read the result from Walrus only after the payment cleared. Every step was checked on chain, and none of it touched mainnet or real money.

## Why did we build on Sui?

StellarFirm gives companies AI Agent Assistants for their work: a Coder, an Accountant, Marketing, a Scientist and more. Each runs on its own computer and answers to the person who hired it. Our next step is a marketplace where those assistants, and outside agents, hire each other and pay per task.

An agent marketplace needs three things a normal web app does not have:

- **A way to pay an agent that has no bank account.** Agents need to pay each other in small amounts, at any hour, with no human typing a card number.
- **A public record of what happened.** Buyer and seller agents are strangers, so both sides want a record of the order that neither of them controls.
- **Delivery that follows payment.** The buyer should be able to read the work only once it has paid, without trusting the seller to hold up its end.

Sui covers the first two. Walrus and Seal cover the third. This post is how we wired them together, what worked first time and what we would ask Mysten Labs for next.

Everything below runs on test networks today. We have not turned any of it on for real money.

## A2A: how do agents find and hire each other?

We speak Google's Agent2Agent protocol (A2A 0.3.0), so any A2A client can hire one of our listings without a StellarFirm account.

- **A signed Agent Card.** Each listing publishes its card at `/.well-known/agent-card.json` with a JWKS, so a caller can check who it is talking to.
- **JSON-RPC tasks.** `message/send`, `tasks/get` and `tasks/cancel`, with a receipt per task.
- **Payment before work.** A task without payment gets a `402 payment_required` answer with a quote: who to pay, how much, in which coin, a one-time nonce and an expiry. The caller pays, sends the proof, and the task runs.

The same listing can be paid several ways: x402 on Base Sepolia and Solana devnet, Stripe's Machine Payments Protocol, and now Sui. Each rail is its own endpoint on the same listing, for example `POST /a2a/<listing>/sui`, and each can be switched off by staff without a redeploy.

Before any quote, every task passes a safety check for weapons content and a size check that refuses tasks too small to be worth sending. A refused task is never charged.

## Sui payments: why is a transaction digest the proof?

On the Sui rail, the caller pays on chain and sends us the transaction digest. We never take custody: the coins go straight to the seller's address, and we only read the chain to confirm they arrived.

The server endpoint uses Mysten's Payment Kit, in USDC or USDsui. To accept a payment, our server:

1. Reads the transaction over gRPC and checks that it succeeded on testnet.
2. Finds the Payment Kit `PaymentReceipt` event with the quote's nonce, receiver and coin type.
3. Checks the amount on the receipt, then checks the receiver's actual balance changes. The receipt alone is only a claim, so the balance changes are the real check.
4. Records the digest so it can pay only once, then runs the task.

The rail is behind a feature flag and a staff switch, refuses mainnet in code, and fails closed: if the chain cannot be read, the task waits rather than runs.

For the laptop demo we used the simplest possible payment instead: a plain transfer of test SUI. The seller checks that the transaction succeeded, came from the quoted buyer, and moved at least the quoted amount to its address, and accepts each digest once. That is weaker than a Payment Kit receipt, because nothing binds the transfer to the quote's nonce. We note it below as work to do.

## Smart contracts: why records and not custody?

We wrote three small Move packages. All three follow two rules we set ourselves. First, they hold hashes and ids only: never a task's text, an answer, a name or a price, because everything on chain is public and permanent. Second, they hold no money: payment stays on the payment rails, and a contract only records what the server already checked.

| Package | What it records | Status |
| --- | --- | --- |
| `stellarfirm_marketplace` | A task receipt issued to the buyer when a paid task is delivered. It cannot be transferred, can be revoked, and points to the listing and the hashes of the task, its scope and its outcome. | Built, behind a flag |
| `stellarfirm_work_orders` | A short public timeline for each paid task: open, delivered, disputed, accepted, refunded, failed or cancelled, in a shared book only our server can write to. | Published on testnet, 17 November 2026 |
| `stellarfirm_access_gate` | Who may read a deliverable. A `Deliverable` holds the hash of the task's terms and the Walrus blob id. An `AccessPass` that cannot be moved is minted to the buyer once the server has verified the payment. `seal_approve` lets Seal release the key only to that buyer. | Published on testnet, 3 December 2026 |

We gave every object that matters to a buyer `key` but not `store`, so a receipt or a pass cannot be sold on or handed to someone else. The access gate also checks that the transaction's sender is the buyer named on the pass, and that the Seal identity starts with that deliverable's own object id. That way, one task's key can never open another task's deliverable.

## Walrus and Seal: how does delivery follow payment?

Walrus is where the deliverable lives. Seal is what keeps it closed until the buyer has paid.

The seller team writes its answer and encrypts it with Seal under an identity built from the deliverable's object id. It stores the ciphertext on Walrus testnet and records the blob id in the `Deliverable` object on chain. Anyone can download the ciphertext, but no one can read it yet.

When the buyer asks for the key, Seal's key servers dry-run our `seal_approve` function with the buyer's `AccessPass`. Without a pass, the dry run aborts and every server refuses. With a pass, two of two servers answer and the buyer decrypts locally. We used Mysten's two open-mode testnet servers with a threshold of 2.

This split fits an agent marketplace well. Storage stays out of our servers, and only a pass on chain can unlock a deliverable, never our say-so. Payment stays on the payment rail, and the contract only ties the two together.

We hold one more rule here. Everything on Walrus is public and cannot reliably be erased, so for now only made-up test data goes there, even encrypted. Putting real customer deliverables on Walrus is a decision we have left open until we have legal advice on it.

## What happened in the run on testnet?

We ran two agents on one Mac. A seller research team of two made-up members published an A2A card on `127.0.0.1`. A separate buyer agent hired it with its own testnet key. Every step below is on Sui testnet and can be checked in the explorer.

1. The buyer asks the seller for the work and is refused the key, since it has not paid.
2. The buyer pays the quoted amount in test SUI to the seller's address.
3. The seller checks the payment on chain and mints the buyer an access pass.
4. The buyer asks again, Seal's key servers release the key, and the buyer decrypts the deliverable it downloaded from Walrus.

The buyer was refused the key before paying, and given it after, which is the behaviour we wanted to prove.

| Step | On chain |
| --- | --- |
| Access gate package published | [transaction](https://suiscan.xyz/testnet/tx/F3Mr8JSV5xg75rQJN4MRoXXMoZJCyYHQ3k8rgopR3m4A) |
| Deliverable opened by the seller | [transaction](https://suiscan.xyz/testnet/tx/869ewuGrkHdkcKfDAKvnpAeM5hedBmeJyEdb3uGaR96r) |
| Walrus blob id recorded on the deliverable | [transaction](https://suiscan.xyz/testnet/tx/GnWd5mnXChghwbnckA4ci9nJqZKqQLhQH4Qprnx7nBpE) |
| Buyer pays in test SUI | [transaction](https://suiscan.xyz/testnet/tx/EPMWaRy38MeSmM2tLKx6QbiXT4im5qZuJvfAEP7cEW7r) |
| Seller grants the access pass | [transaction](https://suiscan.xyz/testnet/tx/3K7dUfWUkFCFuJVgisvbVSqxjtZfenQVkvxwDABWjjH3) |
| The buyer's access pass | [object](https://suiscan.xyz/testnet/object/0x1540e7161181694f54dd2b5ad8250e8e629ee167d6fc8eacbe6be2cacc22695d) |

The deliverable itself was 708 bytes of Seal ciphertext over a made-up note. The buyer checked its SHA-256 after decrypting.

## What did we learn, and what would we ask Mysten for?

Seal worked the first time we ran it live. The refusal before payment, and the release after it, behaved exactly as the docs describe. Move's `key` without `store` gave us non-transferable receipts and passes for free, and the gRPC transaction read gave us everything we needed to check a payment.

Where we lost time:

- **The public Walrus testnet publisher ran out of WAL.** Every upload was refused with "could not find WAL coins with sufficient balance". We fell back to the `walrus` CLI and our own test WAL. A status page or a clearer error for the public publisher would save others the same hunt.
- **Faucet coins land in the address balance, but `walrus get-wal` only spends coin objects.** The CLI said we had too little SUI while the wallet showed more than a coin's worth. A hint in the error, or support for address balances, would help.
- **A failed publish costs its whole gas budget.** Our first publish ran out of gas, and the CLI script stopped with no message. A dry run first, which we now do, catches it.

What we would like from Mysten:

1. **Confirmed Payment Kit details for testnet:** the package id and the exact `PaymentReceipt` field names, so we can move the demo from plain transfers to nonce-bound receipts.
2. **Guidance on putting encrypted customer data on Walrus:** what deletion and expiry mean for personal data under GDPR, and how others handle it.
3. **A Seal pattern for paid access:** an example of `seal_approve` gated on a payment, reviewed by your team, which we would happily contribute ours to.

## How can I try this with my own assistants?

The marketplace rail is still on testnet, but the Coder can already help you build on Sui, Walrus and Seal in your own repository, with your own wallet. Every transaction and deploy waits for your Approve.

```prompt title="Plan a Sui payment check"
Coder, on [repository], sketch how our server should check a Sui testnet payment from a transaction digest: read it over gRPC, find the receipt event, check the receiver's balance changes and accept each digest once. Do not send any transaction.
```

```prompt title="Gate a file with Seal"
Coder, on [repository], write a Move function seal_approve that releases a Seal key only to the holder of an access pass for one deliverable. Keep the pass key without store, add unit tests, and run them. Do not publish the package.
```

```prompt title="Store test data on Walrus"
Coder, on [repository], write a script that encrypts a made-up test note with Seal and stores it on Walrus testnet, then prints the blob id. Use only test data, and show me the commands before you run anything that spends test coins.
```

Next on our side: bind the payment to the quote's nonce with Payment Kit, wire the access gate into our hosted A2A route, and record each delivery in our work order book. Until our counsel and founder decide otherwise, all of it stays on testnet.

## Frequently asked questions

### Does StellarFirm hold the buyer's coins?

No. On the Sui rail the buyer pays the seller's address directly and sends us the transaction digest. We only read the chain to check that the payment arrived, and our contracts hold no money.

### What goes on chain?

Hashes and ids only: never a task's text, an answer, a name or a price, because everything on chain is public and permanent.

### How does the buyer get the work only after paying?

The seller encrypts the deliverable with Seal and stores it on Walrus. Seal's key servers release the key only to a buyer holding the access pass our server mints once the payment is verified.

### Is this live with real money?

No. It runs on Sui testnet and Walrus testnet only, behind feature flags and staff switches, and mainnet is refused in code.

## Sources

- [A2A protocol](https://a2a-protocol.org)
- [Sui documentation](https://docs.sui.io)
- [Walrus documentation](https://docs.wal.app)
- [Seal documentation](https://seal-docs.wal.app)

---

Source: https://stellarfirm.ai/blog/sui
