Locations v1 / Referință & business
City hall by tax id
The city hall's details (the unit served + its seat) by tax identification number.
GET
https://oneapi.ro/api/locations/v1/primarii/{cui}
Path parameters
NameTypeDescriptionExample
cuirequired
string
Tax identification number of the city hall (of the administrative-territorial unit as a legal entity).
Query parameters
This route accepts no query parameters.
How it behaves
- An exact reverse lookup on the tax id. The tax id is known for about 89% of administrative units (parity with
/uat/{cod}/primarie); the rest → 404.
What it is for
- Reverse lookup from a tax id to the unit served, for reconciling invoices or payments
- Validating a public institution's tax id entered in a form
- Enriching a public-supplier database with the corresponding unit and county
Response structure
FieldTypeDescription
data.cui
string
The city hall's tax identification number.
data.uat
object
The unit the city hall serves (cod_siruta, nume, tip) — a link downwards.
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
object
The county: registration prefix + name.
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/primarii/4561898
{
"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"
}
}
}
GEThttps://oneapi.ro/api/locations/v1/primarii/14756536
{
"data": {
"cui": "14756536",
"uat": {
"cod_siruta": 155243,
"nume": "Timișoara",
"tip": "municipiu"
},
"judet": {
"cod": "TM",
"nume": "Timiș"
},
"resedinta": "Timișoara"
},
"meta": {
"actualizat": {
"administrativ": "2026-08-15T16: 39: 14+03: 00"
}
}
}
GEThttps://oneapi.ro/api/locations/v1/primarii/4541580
{
"data": {
"cui": "4541580",
"uat": {
"cod_siruta": 95060,
"nume": "Iași",
"tip": "municipiu"
},
"judet": {
"cod": "IS",
"nume": "Iași"
},
"resedinta": "Iași"
},
"meta": {
"actualizat": {
"administrativ": "2026-08-15T16: 39: 14+03: 00"
}
}
}
GEThttps://oneapi.ro/api/locations/v1/primarii/4562516
{
"data": {
"cui": "4562516",
"uat": {
"cod_siruta": 1071,
"nume": "Ciugud",
"tip": "comuna"
},
"judet": {
"cod": "AB",
"nume": "Alba"
},
"resedinta": "Ciugud"
},
"meta": {
"actualizat": {
"administrativ": "2026-08-15T16: 39: 14+03: 00"
}
}
}
Error codes
| Code | Slug | When it occurs |
|---|---|---|
| 401 | neautentificat | Token missing, invalid, expired or revoked. |
| 403 | feature_indisponibil | The current plan does not include the feature the route depends on. |
| 404 | negasit | Unknown tax id. |
| 429 | cota_depasita | The 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": "Unknown tax id."
}
}