oneapi
Sign in
Locations v1 / Referință & business

City hall of an administrative unit

The city hall's tax id plus the seat, for an administrative unit (cod_siruta).

GET
https://oneapi.ro/api/locations/v1/uat/{cod}/primarie

Path parameters

NameTypeDescriptionExample
codrequired string SIRUTA code of the administrative-territorial unit (e.g. 54975 for Cluj-Napoca).

Query parameters

This route accepts no query parameters.

How it behaves

  • The tax id is known for about 89% of administrative units; otherwise 404.

What it is for

  • Getting a city hall's tax id in order to invoice a local authority
  • Prefilling billing details when contracting with an administrative unit
  • Checking whether a known city hall exists for a given unit

Response structure

FieldTypeDescription
data.cui string The city hall's tax identification number.
data.uat object The unit served: cod_siruta, nume, tip.
data.uat.cod_siruta integer The SIRUTA code of the administrative unit — chainable to /uat/{cod}.
data.uat.nume string The name of the administrative unit.
data.uat.tip string The type of unit (municipality/town/commune).
data.judet.cod string The county's registration prefix.
data.judet.nume string The name of the county.
data.resedinta string | null The unit's seat.
meta.actualizat object Prospețimea datelor pe domenii (dată ISO 8601).

Response examples

GEThttps://oneapi.ro/api/locations/v1/uat/2915/primarie
{
    "data": {
        "cui": "4561898",
        "uat": {
            "cod_siruta": 2915,
            "nume": "Baia de Arieș",
            "tip": "oras"
        },
        "judet": {
            "cod": "AB",
            "nume": "Alba"
        },
        "resedinta": "Baia de Arieș"
    },
    "meta": {
        "actualizat": {
            "administrativ": "2026-08-15T16: 39: 14+03: 00"
        }
    }
}

Error codes

CodeSlugWhen it occurs
401neautentificatToken missing, invalid, expired or revoked.
403feature_indisponibilThe current plan does not include the feature the route depends on.
404negasitThe unit's tax id is not known.
429cota_depasitaThe plan's monthly quota has been exceeded (see Retry-After).

All errors share the same shape. eroare.cod is stable and is the value you should branch on in code — not the text in mesaj, which may change.

{
    "eroare": {
        "cod": "negasit",
        "mesaj": "The unit's tax id is not known."
    }
}