---
id: "br_siafi_municipality_code"
kind: "pattern"
status: "draft"
is_pii: false
categories: ["geo", "government"]
country: ["BR"]
langs: ["pt"]
quality: 65
url: "https://registry.apicrafter.io/datatype/br_siafi_municipality_code"
---

# Brazilian municipality code (SIAFI) (`br_siafi_municipality_code`)

> **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.

Four-digit code of a Brazilian municipality in SIAFI, the financial administration system of the federal government, which federal transfer data uses (for example FUNDEB transfers). It differs from the seven-digit IBGE code (br_municipality_code). Leading zeros are part of the code.

- Pattern of: `br_municipality`
- Personal data (PII): no
- Categories: Geographic identifiers (geo), Government related (government)
- Countries: Brazil (BR)
- Languages: Portuguese (pt)
- Classification: identifier

## Detection

Regular expression (Python `re`):

```
^\d{4}$
```

## Examples

- `0643` — Municipality in FUNDEB transfer data
- `0157` — Municipality in FUNDEB transfer data
- `643` (invalid example) — Leading zero dropped
- `3550308` (invalid example) — IBGE code

## Translations

- pt: Código SIAFI do município

## Quality

Score 65/100. Missing: source link, mapping (Wikidata, Schema.org, ...), detector coverage.

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