{
  "id": "fr_sandre_cours_eau_code",
  "kind": "datatype",
  "status": "draft",
  "name": "French hydrographic entity code (Sandre, cours d'eau)",
  "doc": "Sandre code of a hydrographic entity (river, canal) of the Sandre hydrographic reference: eight characters. The first four are the zone code kept only as far as the entity stays inside one hydrographic region, sector or sub-sector, padded with hyphens (---- for an entity across regions), then come a 3-digit order number and a milieu character (0 for a natural watercourse).",
  "is_pii": false,
  "categories": [
    "environment",
    "geo"
  ],
  "country": [
    "FR"
  ],
  "langs": [
    "fr"
  ],
  "classification": "identifier",
  "regexp": "^(?:[A-Z](?:\\d{3}|\\d{2}-|\\d--|---)|----)\\d{3}[0-9A-Z]$",
  "examples": [
    {
      "value": "K---0090",
      "description": "Vigicrues station reference, entity of region K",
      "valid": true
    },
    {
      "value": "Y34-0400",
      "description": "Entity of sub-sector Y34",
      "valid": true
    },
    {
      "value": "H6123301",
      "description": "Entity inside zone H612",
      "valid": true
    },
    {
      "value": "----0010",
      "description": "The Seine",
      "valid": true
    },
    {
      "value": "K---009",
      "description": "seven characters",
      "valid": false
    },
    {
      "value": "K-1-0090",
      "description": "hyphen before a digit",
      "valid": false
    }
  ],
  "mappings": {
    "wikidata": "P1717"
  },
  "links": [
    {
      "type": "doc",
      "url": "https://www.sandre.eaufrance.fr/sites/default/files/IMG/pdf/Point_CodeHydrographique.pdf"
    },
    {
      "type": "wikidata",
      "url": "https://www.wikidata.org/wiki/Property:P1717"
    }
  ],
  "translations": {
    "fr": {
      "name": "Code de l'entité hydrographique"
    }
  },
  "detected_by": {
    "tools": [
      "metacrafter"
    ],
    "metacrafter_rules": [
      {
        "rule": "frsandrecourseaubyhydroname",
        "type": "field",
        "match": "regex",
        "file": "fr/fr_environment.yaml"
      },
      {
        "rule": "frsandrecourseaubyname",
        "type": "field",
        "match": "regex",
        "file": "fr/fr_environment.yaml"
      },
      {
        "rule": "frsandrecourseauvalue",
        "type": "data",
        "match": "regex",
        "file": "fr/fr_environment.yaml"
      }
    ]
  },
  "quality": {
    "score": 100,
    "missing": []
  },
  "source": {
    "path": "data/datatypes/FR/environment/fr_sandre_cours_eau_code.yaml",
    "url": "https://github.com/apicrafter/metacrafter-registry/blob/main/data/datatypes/FR/environment/fr_sandre_cours_eau_code.yaml",
    "edit_url": "https://github.com/apicrafter/metacrafter-registry/edit/main/data/datatypes/FR/environment/fr_sandre_cours_eau_code.yaml"
  },
  "urls": {
    "html": "https://registry.apicrafter.io/datatype/fr_sandre_cours_eau_code",
    "json": "https://registry.apicrafter.io/api/v1/datatypes/fr_sandre_cours_eau_code.json"
  }
}