The Madlanga Commission

Getting API access to public records: the practical route

Unlock public records easily with sector APIs like Municipal Money and Laws.Africa. Learn how to access data quickly and efficiently.

Published 2026-08-24

Getting API access to public records: the practical route

Getting API access to public records: the practical route

Hands connecting network cable at legal workspace

Use sector APIs where they already exist. Municipal Money covers municipal finance data, and Laws.Africa covers legislation. When a record isn’t published in either, file a request under the Promotion of Access to Information Act (PAIA). That’s the whole decision tree.

In the next hour, you can actually do something with this. Pull up the Municipal Money documentation and check whether the municipal data you need is already in bulk CSV or Excel form. Check the Laws.Africa Content API docs if you’re after legislation, judgments, or point-in-time legal text. If neither covers your target, find the PAIA manual for the relevant public body and locate its prescribed request form.

Most open endpoints need no login at all. Token-based APIs, like Laws.Africa’s, require a bearer token issued after registration. Know which model you’re dealing with before you start writing code.

Key Takeaways

Programmatic access to South African public records works best through sector APIs like Municipal Money and Laws.Africa, with PAIA as the legal fallback when nothing is published.

Point Details
Start with sector APIs Check Municipal Money for finance data and Laws.Africa for legislation before filing any request.
Know the auth model Municipal Money’s bulk endpoints are open; Laws.Africa uses bearer-token authentication.
PAIA is the legal fallback File the prescribed form with the Deputy Information Officer when records aren’t already published.
Expect fragmentation Data.gov.za’s 2015 pilot stalled near 409 datasets, so expect to work across separate department sources.
Validate before you trust Reconcile municipal IDs, check update dates, and track provenance on every ingested record.

Table of Contents

When do you need PAIA instead of an API?

PAIA is the legal fallback for anything a public body hasn’t already published. It exists because South African law gives citizens a right to request records, not just a hope that agencies will publish them voluntarily.

The process runs like this:

  1. Check the relevant body’s PAIA manual first. Many records are listed as automatically available, which skips the formal request entirely.
  2. If the record isn’t automatically available, complete the prescribed request form and submit it to the body’s Deputy Information Officer.
  3. Pay the request fee if one applies; access fees may follow once the body locates and reproduces the record.
  4. Wait out the statutory response timeline, and if the body misses it or refuses, use the internal appeal route before considering court action.

Parliament’s own PAIA manual lays out exactly this structure and is a good template for how other bodies handle it, even though fees and specific timelines vary by institution.

Pro Tip: Include every reference number, case identifier, or date range you have when filing the form. Vague requests get bounced back for clarification, and that round trip alone can add weeks to a process that’s already slow.

How do you build a developer workflow for public records APIs?

Start with discovery, not code. Search departmental portals, data.gov.za, Municipal Money, and Laws.Africa for anything matching your topic, then inspect the metadata: last update date, licensing terms, and whether the data carries point-in-time versioning.

  1. Identify the authentication model. Municipal Money’s bulk CSV endpoints are open, no token required. Laws.Africa’s Content API uses bearer-token authentication, so you register, get a token, and attach it as an Authorization: Bearer header on each request.
  2. Choose bulk versus paginated access. Municipal finance data typically comes as bulk CSV or Excel downloads meant for a full refresh. Legislation and structured content are usually paginated JSON, better suited to incremental syncing.
  3. Decide which Laws.Africa API fits your product. Laws.Africa splits its offering in two: Knowledge Bases, optimized for fast retrieval in AI grounding or search tools, and the Content API, built for full local copies with point-in-time snapshots, XML/HTML/PDF exports, and webhooks for change notifications. Pick Knowledge Bases for a quick RAG integration; pick the Content API when you need a complete, versioned local archive.
  4. Normalize on ingestion. Parsing a spreadsheet is the easy part. Standardizing column names, reconciling municipality IDs against the source LGDRS identifiers, and flagging missing fiscal years is where real validation work happens.
  5. Track provenance. Store the source URL, retrieval timestamp, and version identifier alongside every record you ingest, so a downstream user can trace any figure back to its origin.

Watch for rate limits on token-based endpoints, and build retry logic with backoff rather than hammering an API after a failed call.

A fragmentation problem worth naming: the 2015 data.gov.za pilot loaded 409 datasets and then largely stopped growing. That’s the clearest documented signal that South Africa’s programmatic public-records landscape is spread across individual sector APIs rather than consolidated in one place, and your architecture should assume that stays true.

How reliable is the data once you actually pull it?

Government datasets rarely arrive clean. Expect inconsistent column naming between municipalities, missing fields in older submissions, and update cycles that don’t follow a fixed schedule. None of that means the data is unusable, it means your pipeline needs to check for it.

How reliable is the data once you actually pull it? — overview diagram

Municipal Money is a genuinely strong source, but per-municipality variability is real: some municipalities submit late, some use different account code conventions, and reconciling against the source LGDRS IDs catches most of these problems before they reach your application.

The Madlanga Commission archive offers a useful contrast in how structured public records should look. Its searchable hearing records, witness profiles, and case files are organized with clear provenance, letting researchers trace testimony and exhibits without following live proceedings day by day.

Structured metadata isn’t decoration. It’s what lets a researcher confirm that a document they’re citing is the actual version presented on a specific hearing day, not a later revision or a duplicate upload.

Mitigate quality gaps with three habits: attach provenance fields to every record you store, run automated validation on ingestion rather than trusting the source blindly, and fall back to a PAIA request when an API’s metadata is too thin to confirm what you’re actually looking at.

A researcher’s honest read on this landscape

Most guidance on accessing government data treats PAIA and open APIs as competing philosophies, transparency-by-law versus transparency-by-design. That framing misses the point for anyone actually building something. They’re sequential tools, not rival ideologies. Check the API first because it’s faster and free of bureaucratic friction. File PAIA only when the API doesn’t cover what you need.

The bigger blind spot is treating data.gov.za’s stall as a temporary glitch rather than a structural reality. A portal that hasn’t grown meaningfully since 2015 isn’t waiting for a policy fix, it’s telling you that centralized, general-purpose open data initiatives in this environment tend to lose momentum once initial funding dries up. Sector-specific efforts with a clear constituency, Municipal Money’s civic-oversight mandate, Laws.Africa’s legal-tech use case, tend to survive because someone keeps using them daily.

That’s also why an archive like the Madlanga Commission’s structured hearing records matters as a model. It’s not trying to be everything. It’s trying to make one category of record trustworthy and traceable, which is a more realistic ambition than most national open-data efforts ever set for themselves.

A researcher's honest read on this landscape — overview diagram

Sources

Two sources stand out as genuinely programmatic, and one cautionary tale explains why there aren’t more.

Municipal Money, run by National Treasury, is the strongest example of a working government API. It pulls from the Local Government Database and Reporting System and publishes municipal finance data in bulk, machine-readable formats, with regular submissions from municipalities feeding the underlying dataset. It’s built in partnership with civil-society groups like Code for South Africa specifically to widen civic oversight of local spending, not just to satisfy developers.

The Laws.Africa Content API does for legislation what Municipal Money does for municipal budgets. It exposes structured, machine-friendly legislation, including point-in-time historical versions, so you can see exactly what a law said on a given date rather than just its current form.

Then there’s data.gov.za, the national open data portal, which tells a less encouraging story. A 2015 pilot loaded 409 datasets onto the platform, but sustainability constraints meant the effort stalled shortly after. Almost no new government datasets have been added since, and the broader African open-data landscape shows the same pattern of centralized portals losing momentum once initial funding runs out.

Beyond those three, expect to hunt at the department level. Treasury publishes MFMA-related datasets outside Municipal Money too, and individual departments sometimes maintain their own downloads without a formal API. Typical use cases span municipal spending trackers, legal research tools, and civic dashboards that mix legislation with budget data.

FAQ

What is an API, in the context of public records?

An API is a defined set of rules that lets software request data directly from a source system, rather than a person navigating a website manually. For public records, it means requesting a dataset like municipal budgets or legislation and receiving structured data back in a consistent format.

What is an API with examples relevant here?

Municipal Money’s API returns municipal finance figures as bulk CSV or Excel files, while the Laws.Africa Content API returns legislation as structured JSON with point-in-time versioning. Both let a developer pull data without visiting a webpage.

How do I get access to a public records API?

For open sources like Municipal Money, you typically call the endpoint or download the file directly with no signup. For token-based sources like Laws.Africa, you register as a developer and receive a bearer token to include in your requests.

Is an API key public or private?

An API key or token should be treated as private, similar to a password, even when the underlying data is public. Sharing it lets others make requests under your account, which can trigger rate limits or usage restrictions tied to your access.

When should I file a PAIA request instead of using an API?

File a PAIA request when the record you need isn’t published through an existing API or listed as automatically available in the relevant body’s PAIA manual. Check that manual and contact the Deputy Information Officer before assuming a formal request is necessary.