Firmenbuch (JustizOnline HVD): register numbers and politicians' company functions

- firmenbuch.search: register number for companies linked to people/parties, only for
  one current register entry with the same name
- firmenbuch.extracts: current extracts; officers/shareholders who are politicians in
  the database (exact birth date + name, new person hint birth_date) become company_role
  claims; nobody else is stored, raw responses are not archived, addresses never read;
  the register's daily change list triggers re-extracts
- enrich.firmenbuch closes roles a newer extract no longer lists
- Request.data (raw body, part of the fingerprint); SOAP faults are not retried
- firmenbuch_number drops leading zeros; migration 0009 adds company_role and aligns
  stored numbers; internal politrack_org ids are no longer stored as identifiers
- company_role in API types, MCP docs, person money tab, connections, labels

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
simonandClaude Opus 5.5 committed 2026-11-19 11:33:01 +01:00
1 parent 68be25a953
commit 10c677ca70
30 files changed
+597 -20

No files matched your search

+1 -1
View File
@@ -160,7 +160,7 @@ def get_organization(conn: Connection, slug: str) -> dict | None:
SELECT DISTINCT ON (p.id, c.claim_type) p.slug, p.full_name, c.claim_type AS via, c.summary_de
FROM claim c JOIN person p ON p.id = c.person_id
WHERE c.counterpart_org_id = %(id)s AND c.merged_into IS NULL AND c.review_status = 'published'
AND c.claim_type IN ('side_job', 'career', 'meeting', 'role', 'lobbying')
AND c.claim_type IN ('side_job', 'company_role', 'career', 'meeting', 'role', 'lobbying')
ORDER BY p.id, c.claim_type LIMIT 100
""",
{"id": oid},