{
  "schemaVersion": 1,
  "appId": "swissdlt_explorer",
  "kind": "data",
  "title": "SwissDLT Explorer",
  "summary": "Open SwissDLT chain-94 data from the Explorer: the hourly GOG voucher-transfer index and the Urstamm product-passport candidate registry.",
  "category": "flows",
  "icon": "https://explorer.swissdlt.tech/mark.svg",
  "docsUrl": "https://explorer.swissdlt.tech/llms-full.txt",
  "upstream": {
    "transport": "rest",
    "url": "https://explorer.swissdlt.tech",
    "auth": "none"
  },
  "pricing": {
    "model": "none"
  },
  "redistribution": {
    "displayValues": true,
    "displayRaw": true,
    "attribution": "SwissDLT Explorer public-chain data"
  },
  "manifestVersion": 1,
  "actions": [
    {
      "action": "get_swissdlt_gog_activity",
      "readOnly": true,
      "billingTier": "read_offchain",
      "credits": 0.045,
      "description": "Hourly index of GOG voucher-token Transfer events on SwissDLT chain 94 (acrevis / Gossau, token 0x43cf…106f). Returns coverage (coverageStart to lastIndexedBlock), event count and each transfer: block, transaction hash, log index, from, to, raw value (18 decimals) and block timestamp. Not a full-history index, and not a count of customers, merchants, redemptions or fiat turnover.",
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "description": "GOG Transfer index written hourly by scripts/index-gog.mjs. Values are raw integer strings with 18 decimals. Not a full-history index: coverage is coverageStart to lastIndexedBlock.",
        "properties": {
          "schemaVersion": {
            "const": 1
          },
          "chainId": {
            "const": 94
          },
          "application": {
            "type": "string"
          },
          "token": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "address": {
                "type": "string",
                "pattern": "^0x[0-9a-fA-F]{40}$"
              },
              "decimals": {
                "type": "integer",
                "minimum": 0
              }
            },
            "required": [
              "name",
              "address",
              "decimals"
            ]
          },
          "generatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "coverageStart": {
            "type": "integer",
            "minimum": 0
          },
          "lastIndexedBlock": {
            "type": "integer",
            "minimum": 0
          },
          "completeThrough": {
            "type": "integer",
            "minimum": 0
          },
          "eventCount": {
            "type": "integer",
            "minimum": 0
          },
          "newEventCount": {
            "type": "integer",
            "minimum": 0
          },
          "blockTimes": {
            "type": "object",
            "description": "Block number to unix timestamp (seconds).",
            "propertyNames": {
              "pattern": "^[0-9]+$"
            },
            "additionalProperties": {
              "type": "integer",
              "minimum": 0
            }
          },
          "events": {
            "type": "array",
            "description": "Newest first. Identity is transactionHash:logIndex.",
            "items": {
              "type": "object",
              "properties": {
                "blockNumber": {
                  "type": "integer",
                  "minimum": 0
                },
                "blockHash": {
                  "type": "string",
                  "pattern": "^0x[0-9a-fA-F]{64}$"
                },
                "transactionHash": {
                  "type": "string",
                  "pattern": "^0x[0-9a-fA-F]{64}$"
                },
                "logIndex": {
                  "type": "integer",
                  "minimum": 0
                },
                "from": {
                  "type": "string",
                  "pattern": "^0x[0-9a-fA-F]{40}$"
                },
                "to": {
                  "type": "string",
                  "pattern": "^0x[0-9a-fA-F]{40}$"
                },
                "value": {
                  "type": "string",
                  "pattern": "^[0-9]+$",
                  "description": "Raw token units, 18 decimals."
                },
                "timestamp": {
                  "type": "integer",
                  "minimum": 0,
                  "description": "Block timestamp in unix seconds, present when the block time was read."
                }
              },
              "required": [
                "blockNumber",
                "blockHash",
                "transactionHash",
                "logIndex",
                "from",
                "to",
                "value"
              ]
            }
          }
        },
        "required": [
          "schemaVersion",
          "chainId",
          "token",
          "generatedAt",
          "coverageStart",
          "lastIndexedBlock",
          "eventCount",
          "events"
        ]
      },
      "invoke": {
        "method": "GET",
        "path": "/data/gog.json"
      },
      "fixtureParams": {},
      "signals": [],
      "ttlMs": 300000
    },
    {
      "action": "get_swissdlt_urstamm_registry",
      "readOnly": true,
      "billingTier": "read_offchain",
      "credits": 0.045,
      "description": "Urstamm product-passport registry on SwissDLT chain 94: the urstamm.eth identity and candidate certificate contracts with status, registered document hash (null when none), provenance events and notes. Entries are unverified research candidates, not an official issuer registry; issuer mapping needs confirmation from Urstamm or the association.",
      "inputSchema": {
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "outputSchema": {
        "type": "object",
        "description": "Urstamm product-passport candidate registry. Entries are unverified research candidates, not an official issuer registry.",
        "properties": {
          "schemaVersion": {
            "const": 1
          },
          "application": {
            "type": "string"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "registryStatus": {
            "type": "string"
          },
          "notice": {
            "type": "string"
          },
          "identity": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "ens": {
                "type": "string"
              },
              "address": {
                "type": "string",
                "pattern": "^0x[0-9a-fA-F]{40}$"
              },
              "verified": {
                "type": "boolean"
              },
              "relation": {
                "type": "string"
              }
            },
            "required": [
              "name",
              "ens",
              "address",
              "verified",
              "relation"
            ]
          },
          "entries": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "address": {
                  "type": "string",
                  "pattern": "^0x[0-9a-fA-F]{40}$"
                },
                "status": {
                  "type": "string"
                },
                "documentHash": {
                  "anyOf": [
                    {
                      "type": "string",
                      "pattern": "^0x[0-9a-fA-F]{64}$"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "events": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "type": {
                        "type": "string"
                      },
                      "transactionHash": {
                        "type": "string",
                        "pattern": "^0x[0-9a-fA-F]{64}$"
                      },
                      "timestamp": {
                        "anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "integer",
                            "minimum": 0
                          }
                        ]
                      },
                      "evidence": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "type",
                      "transactionHash"
                    ]
                  }
                },
                "note": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "address",
                "status",
                "documentHash",
                "events",
                "note"
              ]
            }
          }
        },
        "required": [
          "schemaVersion",
          "registryStatus",
          "notice",
          "identity",
          "entries"
        ]
      },
      "invoke": {
        "method": "GET",
        "path": "/data/urstamm-registry.json"
      },
      "fixtureParams": {},
      "signals": [],
      "ttlMs": 300000
    }
  ]
}
