{
  "id": "magnet_link",
  "name": "Magnet URI (BitTorrent)",
  "status": "stable",
  "doc": "URI of the magnet: scheme that identifies a file or a torrent by a hash of its content instead of by its location, used by BitTorrent and other peer-to-peer clients. The parameter xt (exact topic) holds a URN such as urn:btih:<info hash> for BitTorrent v1 (BEP 9) or urn:btmh:<multihash> for v2 (BEP 52); optional parameters include dn (display name), tr (tracker URL), ws (web seed) and xs (exact source). The regexp requires an xt parameter, in any position.",
  "parent": {
    "type": "uri"
  },
  "categories": [
    {
      "id": "internet",
      "name": "Internet"
    },
    {
      "id": "identifiers",
      "name": "Universal unique identifiers"
    }
  ],
  "langs": [
    {
      "id": "common",
      "name": "Common to most languages"
    }
  ],
  "is_pii": false,
  "classification": "identifier",
  "regexp": "^magnet:\\?(?:[^\\s&#]*&)*xt(?:\\.[0-9]+)?=urn:[A-Za-z0-9][A-Za-z0-9-]{0,31}:[^\\s&#]+(?:&[^\\s#]*)?$",
  "examples": [
    {
      "value": "magnet:?xt=urn:btih:08ada5a7a6183aae1e09d831df6748d566095a10&dn=Sintel&tr=udp%3A%2F%2Fexplodie.org%3A6969",
      "description": "Sintel magnet link published by WebTorrent, cut to one tracker"
    },
    {
      "value": "magnet:?xt=urn:btih:dd8255ecdc7ca55fb0bbf81323d87062db1f6d1c&dn=Big+Buck+Bunny",
      "description": "Big Buck Bunny, published by WebTorrent"
    },
    {
      "value": "magnet:?dn=Sintel&xt=urn:btih:08ada5a7a6183aae1e09d831df6748d566095a10",
      "description": "Display name before the exact topic"
    },
    {
      "value": "magnet:?xt=urn:btih:08ada5a7a6183aae1e09d831df6748d566095a10",
      "description": "Exact topic only"
    },
    {
      "value": "magnet:?dn=Sintel&tr=udp%3A%2F%2Fexplodie.org%3A6969",
      "valid": false,
      "description": "No exact topic (xt)"
    },
    {
      "value": "https://webtorrent.io/torrents/sintel.torrent",
      "valid": false,
      "description": "URL of a .torrent file"
    }
  ],
  "links": [
    {
      "type": "wikipedia",
      "url": "https://en.wikipedia.org/wiki/Magnet_URI_scheme"
    },
    {
      "type": "doc",
      "url": "https://www.bittorrent.org/beps/bep_0009.html"
    },
    {
      "type": "doc",
      "url": "https://www.bittorrent.org/beps/bep_0052.html"
    }
  ],
  "translations": {
    "ru": {
      "name": "Magnet-ссылка",
      "doc": "URI схемы magnet:, который указывает файл или торрент по хешу содержимого, а не по адресу."
    }
  },
  "type": "datatype"
}