{
  "$schema": "https://farmslot.io/schemas/recipe-v1.schema.json",
  "title": "Swap release surface",
  "description": "Opens Swap through visible product navigation and proves both token selectors, amount inputs, and settings are available without development-only bridges.",
  "paramsSchema": {
    "type": "object",
    "additionalProperties": false,
    "properties": {
      "source_symbol": { "type": "string", "default": "" },
      "destination_symbol": { "type": "string", "default": "" },
      "timeout_ms": { "type": "integer", "minimum": 1000, "default": 45000 }
    }
  },
  "workflow": {
    "entry": "open-swap",
    "nodes": {
      "open-swap": {
        "action": "ui.navigate",
        "page": "swap",
        "timeout_ms": "{{params.timeout_ms}}",
        "intent": "Open Swap through visible product navigation",
        "next": "assert-swap"
      },
      "assert-swap": {
        "action": "metamask.swap_bridge.read_visible_state",
        "source_symbol": "{{params.source_symbol}}",
        "destination_symbol": "{{params.destination_symbol}}",
        "require_amount_inputs": true,
        "require_settings": true,
        "intent": "Prove the visible Swap inputs, token selectors, and settings control",
        "next": "capture-swap"
      },
      "capture-swap": {
        "action": "ui.screenshot",
        "path": "screenshots/swap-surface.png",
        "label": "Swap release surface",
        "intent": "Preserve reviewer-visible proof of the Swap surface",
        "next": "done"
      },
      "done": { "action": "end", "status": "pass" }
    }
  }
}
