---
id: "osm_relation_id"
kind: "datatype"
status: "draft"
is_pii: false
categories: ["geo"]
langs: ["common"]
quality: 90
url: "http://registry.apicrafter.io/datatype/osm_relation_id"
---

# OpenStreetMap relation ID (`osm_relation_id`)

> **Draft.** Draft records have not been reviewed yet and may be incomplete or wrong; do not treat them as authoritative for legal or compliance decisions.

Numeric ID of an OpenStreetMap relation, a group of nodes, ways and other relations with roles. Relations model administrative boundaries, multipolygons and transport routes.

- Parent datatype: `osm_id`
- Personal data (PII): no
- Categories: Geographic identifiers (geo)
- Countries: global
- Languages: Common to most languages (common)
- Classification: identifier

## Detection

Regular expression (Python `re`):

```
^[1-9][0-9]{0,18}$
```

## Examples

- `62422` — Berlin boundary
- `51701` — Switzerland boundary
- `r62422` (invalid example) — type-prefixed form of osm_id, not a bare relation ID

## Mappings

- wikidata: `P402`

## Translations

- fr: Identifiant de relation OpenStreetMap
- ru: Идентификатор отношения OpenStreetMap

## Sources

- wikidata: <https://www.wikidata.org/wiki/Property:P402>
- doc: <https://wiki.openstreetmap.org/wiki/Relation>

## Quality

Score 90/100. Missing: detector coverage.

JSON: <http://registry.apicrafter.io/api/v1/datatypes/osm_relation_id.json> · Edit: <https://github.com/apicrafter/metacrafter-registry/edit/main/data/datatypes/any/geo/osm_relation_id.yaml>
