ARES Business Registry (CZ)
Use scripts/ares_client.py for ICO lookup and business search.
Working directory
- From workspace root:
python3 skills/ares-business-registry/scripts/ares_client.py ...
- From
skills/ares-business-registry:
python3 scripts/ares_client.py ...
Commands
You can run via the wrapper (recommended):
./ares ico <ico>
./ares name "NAME" [--nace CODE ...] [--city CITY] [--limit N] [--offset N] [--pick INDEX]
The underlying script also supports:
python3 scripts/ares_client.py search --name "NAME" ...
python3 scripts/ares_client.py search --nace CODE [CODE ...] ...
python3 scripts/ares_client.py search --name "NAME" --nace CODE ... (combined)
Output modes
- default: human-readable summary
--json: normalized JSON output (stable keys)
--raw: full raw ARES payload
Examples
# ICO lookup
python3 scripts/ares_client.py ico 27604977
python3 scripts/ares_client.py ico 27604977 --json
python3 scripts/ares_client.py ico 27604977 --raw
# Search by name
python3 scripts/ares_client.py search --name Google
python3 scripts/ares_client.py search --name Google --limit 3 --json
python3 scripts/ares_client.py search --name Google --city Praha --limit 10 --offset 0
python3 scripts/ares_client.py search --name Google --limit 3 --pick 1
# Search by NACE code (CZ-NACE, exactly 5 digits)
python3 scripts/ares_client.py search --nace 47710 --limit 10 # all clothing retailers
python3 scripts/ares_client.py search --nace 47710 --city Praha --json # clothing retailers in Praha
python3 scripts/ares_client.py search --nace 47710 47910 --limit 5 # clothing retail + mail order
# Combined: name + NACE (AND filter)
python3 scripts/ares_client.py search --name sport --nace 47710 --json # "sport" in clothing retail
Normalized JSON
ico output:
{ "subject": { "name", "ico", "dic", "datumVzniku", "address", "codes", "decoded" } }
search output:
{ "query", "total", "items", "picked?" }
query includes: name (nullable), city (nullable), nace (nullable array), limit, offset
dic can be null.
datumVzniku can be null.
Error JSON contract (--json only)
{
"error": {
"code": "validation_error | ares_error | network_error",
"message": "Human readable message",
"status": 429,
"details": {}
}
}
Validation and exits
- ICO: exactly 8 digits + mod11 checksum
- Search: at least
--name (length >= 3) or --nace required; both can be combined
--nace: exactly 5 digits per code (CZ-NACE format, e.g. 47710); multiple codes accepted (space-separated)
--limit: default 10, capped to 100
--offset: must be >= 0
- Exit codes:
0 success
1 validation error
2 ARES non-OK response
3 network/timeout
Caching and decoding
- Legal form decoding (
PravniForma) is loaded via POST /ciselniky-nazevniky/vyhledat
- Cache path:
skills/ares-business-registry/.cache/pravni_forma.json
- Cache TTL: 24h
- In-memory fallback is used if cache file is stale/unavailable
- Curated overrides:
112 -> s.r.o.
121 -> a.s.
141 -> z.s.
701 -> OSVČ
301 -> s.p.
331 -> p.o.
NACE code search
--nace sends the czNace field to the ARES complex filter endpoint
- Codes must be exactly 5 digits (CZ-NACE_2025 format)
- Multiple codes can be passed (space-separated) — ARES returns entities matching any of them
- When combined with
--name, both filters apply as AND (entities must match name AND have the NACE code)
- NACE-only search (without
--name) is supported — useful for browsing all entities in a sector
- Common e-commerce NACE codes:
47710 — Retail sale of clothing
47910 — Retail sale via mail order or internet
47410 — Retail sale of computers and software
47750 — Retail sale of cosmetic and toilet articles
46420 — Wholesale of clothing and footwear
- Full CZ-NACE list: https://www.czso.cz/csu/czso/klasifikace_ekonomickych_cinnosti_cz_nace
City filter limitation
--city maps to sidlo.nazevObce (structured filter).
- Matching remains best-effort only; ARES server-side matching/ranking can still return records outside the expected municipality.
Retries and rate limits
- HTTP timeout: connect 5s, read 20s
- Retries for transient failures:
429/502/503/504 + network timeout/connection issues
- Backoff:
1s, 2s, 4s
- Honors
Retry-After for 429 where provided
1---2name: ares-business-registry3description: Query Czech ARES business registry by ICO or name with human/JSON/raw outputs, retries, and legal-form decoding.4---56# ARES Business Registry (CZ)78Use `scripts/ares_client.py` for ICO lookup and business search.910## Working directory1112- From workspace root:13 - `python3 skills/ares-business-registry/scripts/ares_client.py ...`14- From `skills/ares-business-registry`:15 - `python3 scripts/ares_client.py ...`1617## Commands1819You can run via the wrapper (recommended):20- `./ares ico <ico>`21- `./ares name "NAME" [--nace CODE ...] [--city CITY] [--limit N] [--offset N] [--pick INDEX]`2223The underlying script also supports:24- `python3 scripts/ares_client.py search --name "NAME" ...`25- `python3 scripts/ares_client.py search --nace CODE [CODE ...] ...`26- `python3 scripts/ares_client.py search --name "NAME" --nace CODE ...` (combined)2728## Output modes2930- default: human-readable summary31- `--json`: normalized JSON output (stable keys)32- `--raw`: full raw ARES payload3334## Examples3536```bash37# ICO lookup38python3 scripts/ares_client.py ico 2760497739python3 scripts/ares_client.py ico 27604977 --json40python3 scripts/ares_client.py ico 27604977 --raw4142# Search by name43python3 scripts/ares_client.py search --name Google44python3 scripts/ares_client.py search --name Google --limit 3 --json45python3 scripts/ares_client.py search --name Google --city Praha --limit 10 --offset 046python3 scripts/ares_client.py search --name Google --limit 3 --pick 14748# Search by NACE code (CZ-NACE, exactly 5 digits)49python3 scripts/ares_client.py search --nace 47710 --limit 10 # all clothing retailers50python3 scripts/ares_client.py search --nace 47710 --city Praha --json # clothing retailers in Praha51python3 scripts/ares_client.py search --nace 47710 47910 --limit 5 # clothing retail + mail order5253# Combined: name + NACE (AND filter)54python3 scripts/ares_client.py search --name sport --nace 47710 --json # "sport" in clothing retail55```5657## Normalized JSON5859- `ico` output:60 - `{ "subject": { "name", "ico", "dic", "datumVzniku", "address", "codes", "decoded" } }`61- `search` output:62 - `{ "query", "total", "items", "picked?" }`63 - `query` includes: `name` (nullable), `city` (nullable), `nace` (nullable array), `limit`, `offset`64- `dic` can be `null`.65- `datumVzniku` can be `null`.6667## Error JSON contract (`--json` only)6869```json70{71 "error": {72 "code": "validation_error | ares_error | network_error",73 "message": "Human readable message",74 "status": 429,75 "details": {}76 }77}78```7980## Validation and exits8182- ICO: exactly 8 digits + mod11 checksum83- Search: at least `--name` (length >= 3) or `--nace` required; both can be combined84- `--nace`: exactly 5 digits per code (CZ-NACE format, e.g. `47710`); multiple codes accepted (space-separated)85- `--limit`: default 10, capped to 10086- `--offset`: must be >= 087- Exit codes:88 - `0` success89 - `1` validation error90 - `2` ARES non-OK response91 - `3` network/timeout9293## Caching and decoding9495- Legal form decoding (`PravniForma`) is loaded via POST `/ciselniky-nazevniky/vyhledat`96- Cache path: `skills/ares-business-registry/.cache/pravni_forma.json`97- Cache TTL: 24h98- In-memory fallback is used if cache file is stale/unavailable99- Curated overrides:100 - `112 -> s.r.o.`101 - `121 -> a.s.`102 - `141 -> z.s.`103 - `701 -> OSVČ`104 - `301 -> s.p.`105 - `331 -> p.o.`106107## NACE code search108109- `--nace` sends the `czNace` field to the ARES complex filter endpoint110- Codes must be exactly 5 digits (CZ-NACE_2025 format)111- Multiple codes can be passed (space-separated) — ARES returns entities matching **any** of them112- When combined with `--name`, both filters apply as AND (entities must match name AND have the NACE code)113- NACE-only search (without `--name`) is supported — useful for browsing all entities in a sector114- Common e-commerce NACE codes:115 - `47710` — Retail sale of clothing116 - `47910` — Retail sale via mail order or internet117 - `47410` — Retail sale of computers and software118 - `47750` — Retail sale of cosmetic and toilet articles119 - `46420` — Wholesale of clothing and footwear120- Full CZ-NACE list: https://www.czso.cz/csu/czso/klasifikace_ekonomickych_cinnosti_cz_nace121122## City filter limitation123124- `--city` maps to `sidlo.nazevObce` (structured filter).125- Matching remains best-effort only; ARES server-side matching/ranking can still return records outside the expected municipality.126127## Retries and rate limits128129- HTTP timeout: connect 5s, read 20s130- Retries for transient failures: `429/502/503/504` + network timeout/connection issues131- Backoff: `1s`, `2s`, `4s`132- Honors `Retry-After` for 429 where provided