Developer Data Guide
This documentation outlines how to consume and utilize the static JSON datasets that power the Local Government Services catalog. By relying on static JSON files rather than active backend calls, developers can achieve sub-millisecond query times and easily filter services client-side.
All examples interact directly with the JSON files hosted
in /data/. No complex backend
authentication or active API routing is required.
Data File Structure
The core application state is derived from two primary JSON files located
in the /data/ directory:
-
services.json
The master catalogue containing all available capabilities. Each
service includes a
LocalAuthorityIDsarray which tracks exactly which counties offer that specific service. - service_mappings.json Contains the semantic mappings that group services by LifeEvent or ServiceTopic, enabling the Kanban view organization.
Example Service Record Format:
{
"ReferenceID": "152",
"Name": "Social Housing Support",
"Description": "Apply for permission to be placed on the social housing waiting list.",
"LocalAuthorityIDs": [1, 2, 3, 7, 10, ...], // County IDs that offer this
"LifeEvent": ["accessing_social_housing", "finding_and_maintaining_a_home"],
"ServiceTopic": ["housing"]
}
Life Events Vocabulary
You can filter services array elements by looking for the presence of
these exact string literals in the LifeEvent attribute
array. When using the API, pass these as the life_event URL parameter.
Service Topics List
Similar to Life Events, services may be universally categorized by the
ServiceTopic attribute using these standard
identifiers. When using the API, pass these as the topic URL parameter.
Local Authority (County) Reference Map
To find services belonging to a specific county, inspect the
LocalAuthorityIDs integer array on the service objects
against this table. When using the API, pass the integer ID as the county URL
parameter.
| ID | County / Local Authority Name |
|---|
Filters & API URL Parameters
The backend API provides a highly performant interface for querying the compiled service catalogue via URL parameters. This saves you from parsing the entire JSON file manually on the frontend.
1. Sub-select by County ID
Fetches exclusively services that Tipperary County Council (ID: 27) accommodates.
2. Fetch by Life Event
Fetches all services tagged with the 'retire' Life Event nationwide.
3. Complex Mix-and-Match Filtering
Combines multiple vectors: "Show me all environment services in Galway City (10) related to adverse weather."
// Equivalent Javascript Fetch Data call:
async function getGalwayWeatherEnvironmentServices() {
const response = await fetch('/api/services?county=10&topic=environment&life_event=adverse_weather_event');
const results = await response.json();
return results;
}
4. Frontend Deep-Linking
The main user portal supports deep-linking via the
?county= URL parameter.
Passing a county name directly in the browser's address bar will automatically update the
dropdown and load all relevant services and news feeds for that county.