{
  "$schema": "https://datapackage.org/profiles/2.0/datapackage.json",
  "name": "taipei-metro-od-monthly",
  "title": "臺北捷運站間起訖運量（月彙總）",
  "version": "1.0.0",
  "description": "Taipei Metro station-to-station origin–destination flows (monthly)",
  "licenses": [
    {
      "name": "OGDL-Taiwan-1.0",
      "path": "https://data.gov.tw/license"
    }
  ],
  "x-netscied": {
    "kind": "graph",
    "directed": true,
    "multi_edges": true
  },
  "resources": [
    {
      "name": "nodes",
      "path": "nodes.csv",
      "type": "table",
      "format": "csv",
      "mediatype": "text/csv",
      "encoding": "utf-8",
      "schema": {
        "fields": [
          {
            "name": "index",
            "type": "integer"
          },
          {
            "name": "id",
            "type": "string"
          },
          {
            "name": "appears_as",
            "type": "string"
          }
        ],
        "primaryKey": [
          "id"
        ]
      }
    },
    {
      "name": "edges",
      "path": "edges.csv",
      "type": "table",
      "format": "csv",
      "mediatype": "text/csv",
      "encoding": "utf-8",
      "schema": {
        "fields": [
          {
            "name": "id",
            "type": "string"
          },
          {
            "name": "source",
            "type": "string"
          },
          {
            "name": "target",
            "type": "string"
          },
          {
            "name": "month",
            "type": "string"
          },
          {
            "name": "trips",
            "type": "integer"
          }
        ],
        "primaryKey": [
          "id"
        ],
        "foreignKeys": [
          {
            "fields": [
              "source"
            ],
            "reference": {
              "resource": "nodes",
              "fields": [
                "id"
              ]
            }
          },
          {
            "fields": [
              "target"
            ],
            "reference": {
              "resource": "nodes",
              "fields": [
                "id"
              ]
            }
          }
        ]
      }
    }
  ]
}
