{
  "$schema": "../../../skill/references/schemap.schema.json",
  "kind": "lifecycle",
  "title": "Payment",
  "subtitle": "States of one card payment",
  "lanes": [
    { "id": "main", "label": "Happy path" },
    { "id": "action", "label": "Customer action" },
    { "id": "bad", "label": "Failure", "tone": "exception" }
  ],
  "nodes": [
    { "id": "created", "type": "start", "lane": "main", "card": { "title": "Created" } },
    { "id": "processing", "type": "active", "lane": "main", "card": { "title": "Processing" } },
    {
      "id": "authorized",
      "type": "active",
      "lane": "main",
      "card": { "title": "Authorized", "subtitle": "funds held 7 days" }
    },
    { "id": "captured", "type": "success", "lane": "main", "card": { "title": "Captured" } },
    {
      "id": "sca",
      "type": "waiting",
      "lane": "action",
      "card": { "title": "Requires action", "subtitle": "3-D Secure" }
    },
    { "id": "declined", "type": "failure", "lane": "bad", "card": { "title": "Declined" } },
    { "id": "refunded", "type": "neutral", "lane": "bad", "card": { "title": "Refunded" } }
  ],
  "edges": [
    { "id": "t1", "from": "created", "to": "processing", "label": "confirm", "tone": "main" },
    { "id": "t2", "from": "processing", "to": "sca", "label": "challenge" },
    { "id": "t3", "from": "sca", "to": "processing", "label": "passed", "kind": "return" },
    { "id": "t4", "from": "processing", "to": "authorized", "tone": "main" },
    { "id": "t5", "from": "authorized", "to": "captured", "label": "capture", "tone": "main" },
    { "id": "t6", "from": "processing", "to": "declined", "label": "issuer says no", "tone": "error" },
    { "id": "t7", "from": "captured", "to": "refunded", "label": "refund" }
  ]
}
