Skip to content
SAATOSAATO

How it works

Four states. One gate.

Scroll to move one request through the mechanism.

01 → 04

State · BLOCKED

PRICE0.001 ETH

01

Request

A request arrives for an action you defined. It has no access yet.

  1. Request
  2. Price
  3. Pay
  4. Action

Action states

Every action is in exactly one.

  1. 01DRAFTMissing a field. The gate stays shut.
  2. 02INVALIDSomething is wrong, like a bad price. The gate stays shut.
  3. 03PAYMENT REQUIREDValid and priced. The gate holds until payment.
  4. 04AVAILABLEValid and free. The gate opens on request.
  5. 05UNAVAILABLESwitched off by its owner. The gate stays shut.

For developers

One definition. One gate.

Today, actions are defined and gated in the browser. Settlement plugs in through a single adapter.

  1. 01RequestCaller opens /action/[id]
  2. 02PriceDefinition is validated and priced
  3. 03PayPaymentAdapter settles on Robinhood Chain
  4. 04ActionResource is released to the caller

Step 03 has no adapter configured yet. Nothing is charged.

lib/actions/types.ts

type ActionDefinition = {
  id: string            // "act_…" generated locally
  name: string
  description: string
  type: 'API' | 'FILE' | 'COMPUTE' | 'GENERATION' | 'CUSTOM'
  resource: string      // endpoint, URI or identifier
  price: string         // decimal, in ETH
  currency: 'ETH'
  metadata: { key: string; value: string }[]
  enabled: boolean
  storage: 'local'      // stored in this browser
}

Try the gate.

Create an action