# Sell an API on minia2a

One POST lists an endpoint. Review is manual, the answer is a status on the listing, and
the only identity is your wallet.

## 1. Publish

    curl -X POST https://minia2a.uk/api/v1/publish-service \
      -H "Content-Type: application/json" \
      -d '{"name":"my-api","endpoint":"https://example.com/api",
           "price_cents":5,"category":"data",
           "wallet":"0x…","signature":"0x…"}'

Required: `name`, `endpoint`, `wallet`, `signature`.
Optional: `description`, `subcategory`, `copied_from`.
Rate limit: 5 publishes per minute per IP. Field reference: https://minia2a.uk/publish-standard.md

## 2. What review looks at

A new listing starts as `pending`. It is approved when the endpoint actually answers x402:
an unpaid request returns `402` with a payment challenge. A 200 that gives data away, a 500,
or a page of HTML is rejected, with the reason recorded on the listing. Rejected listings stay
yours: fix and resubmit. Status: `GET /api/services/<id>`.

## 3. Price, fees, payout

- `price_cents` is an integer >= 1 (one cent floor).
- Platform fee is 0% through 2026 (stated in `/api/stats`).
- First-party listings settle through the platform wallet. Third-party listings are paid
  directly to the address in their own 402 — the marketplace never holds the money.

## 4. Staying live

Listings are probed continuously. An endpoint returning 404 is delisted immediately; one that
stops answering is delisted after three consecutive failing days, and one success resets the
counter. Delisting removes it from the catalog; it does not delete your data.

Your delivery numbers are public at https://minia2a.uk/availability — with the sample size
next to every rate. A low rate with a small n is not a verdict.

## 5. Make it discoverable to agents

- Advertise a real input example in your 402 — agents copy it verbatim.
- Answer GET as well as POST; a client that cannot send a body cannot use a POST-only endpoint.
- Fail loudly: `ok:false` with a cause, never an `ok:true` envelope around a failed sub-step.
