ParseForge Scrapers

Singapore Open Data Scraper

parseforge/singapore-data-gov-sg-scraper

BusinessOtherAutomation

Scrapes any dataset from data.gov.sg using its resource ID. Returns each row as a flat object with optional full-text search and exact field filters.

Run this scraper See the API call
Total users
2
Monthly active
1
Total runs
106
Bookmarked
0
Rating
Not rated yet
Last modified
12 days ago

Overview

ParseForge

Singapore Open Data Scraper

Scrape any public dataset from data.gov.sg by resource ID, with full-text search and exact field filters. Returns every row in a flat, analysis-ready schema. Export to CSV, JSON, Excel, or XML.

Singapore's open data portal holds thousands of government datasets, but downloading and cleaning them manually is slow. This Actor reads any dataset directly from data.gov.sg using its resource ID, applies your search terms and field filters, and returns the rows in one consistent format. No API key or registration needed.

Who uses it What they scrape Singapore Open Data for
Property analysts Pull HDB resale flat prices by town and flat type for valuation models.
Policy researchers Track dengue cluster locations or PSI readings over time for public health reports.
Data journalists Grab the latest traffic accident data or school directory for a story.
App builders Feed real-time weather readings or carpark availability into a mobile app.

What it does

This Actor collects rows from a specified data.gov.sg dataset and returns each record as a flat object.

  • ๐Ÿ” Full-text search: filter rows by any keyword across all fields with the searchQuery input.
  • ๐ŸŽฏ Exact field filters: pass a JSON object like {"town":"BISHAN"} to match only those rows.
  • ๐Ÿ“ฆ Bulk collection: set maxItems up to 1,000,000 to pull the entire dataset in one run.

Results export to CSV, JSON, Excel, or XML, or straight from the API.

What you can do with Singapore Open Data data

๐Ÿ  Monitor HDB resale prices.

A property analyst pulls the latest resale flat transactions filtered by town and flat type to update a pricing dashboard.

๐ŸฆŸ Track dengue clusters.

A health researcher collects the weekly dengue cluster dataset to map outbreak hotspots and alert residents.

๐Ÿš— Analyse traffic incidents.

A data journalist scrapes the traffic accident dataset to find the most dangerous roads and publish an interactive map.

๐ŸŒค๏ธ Feed real-time weather data.

An app developer pulls the latest PSI and temperature readings to show a live environment widget.

Why choose this scraper

What you get
No API key Reads the public CKAN API directly, no registration.
Fixed schema Every run returns the same flat structure, ready for pandas or Excel.
Full dataset Collect up to a million rows per run for large historical datasets.

How it compares

This Actor is built specifically for Singapore's open data portal, while the competitors below target different sources.

Feature ParseForge Shopee Scraper
Scrapes data.gov.sg datasets Yes Not listed
Full-text search across dataset rows Yes Not listed
Exact field filters via JSON Yes Not listed
No API key required Yes Not listed
Returns government open data Yes Not listed

Configure the run

Drive the Actor with a resource ID from data.gov.sg, and optionally narrow results with a keyword search or exact-match field filters. The Input tab lists every parameter.

A first run with the defaults:

{
  "maxItems": 10,
  "resourceId": "d_8b84c4ee58e3cfc0ece0d773c8ca6abc"
}

A larger pull:

{
  "maxItems": 200,
  "resourceId": "d_8b84c4ee58e3cfc0ece0d773c8ca6abc"
}

Pricing

Pay-per-result: $0.01867 per result collected. You pay only for the results written to your dataset.

Results collected Approximate cost
100 results $1.87
1,000 results $18.67
10,000 results $186.70

New Apify accounts start with $5 in free credit.

Free users

Free-plan runs return up to 10 results as a preview. Upgrade your Apify plan to collect up to 1,000,000 results per run.

Run it

  1. Create a free Apify account with $5 in credit.
  2. Open the Singapore Open Data Scraper.
  3. Set your inputs and any filters, then click Start.
  4. Export the results as CSV, Excel, JSON, or XML from the Dataset tab.

Run it programmatically through the Apify API (run-sync-get-dataset-items) or the ApifyClient for JavaScript and Python.

Use with AI agents (MCP)

Give an AI agent live access to Singapore Open Data through the Model Context Protocol. Add the Actor to Claude, Cursor, or any MCP client:

claude mcp add --transport http apify "https://mcp.apify.com?tools=parseforge/singapore-data-gov-sg-scraper"

Then prompt it in plain language to run the scraper and read back the results.

Troubleshooting

Why am I getting no results?

Check that the resource ID is correct and the dataset is still active on data.gov.sg. If you are using filters or searchQuery, try removing them to see if the dataset returns rows without filtering.

The Actor returns fewer rows than expected.

The API may paginate results. Increase maxItems and ensure your filters are not too restrictive. Some datasets also have a server-side row limit.

I get an error about an invalid resource ID.

Verify the resource ID by visiting the dataset page on data.gov.sg. The ID is case-sensitive and must include the d_ prefix.

My JSON filter is not working.

Ensure the filters input is valid JSON. Use double quotes for keys and string values, like {"town":"BISHAN"}. Test the filter on the data.gov.sg API explorer first.

The run times out on large datasets.

Lower maxItems or increase the Actor's timeout in the run settings. For very large datasets, consider splitting by date or category filters across multiple runs.

FAQ

Question Answer
How do I find the resource ID for a dataset? Browse data.gov.sg, open the dataset you want, and copy the resource ID from the URL or the API section. It looks like d_8b84c4ee58e3cfc0ece0d773c8ca6abc.
Can I scrape multiple datasets in one run? Each run targets one resource ID. To collect multiple datasets, run the Actor once per resource ID, or use an Apify workflow to chain runs.
What format does the data come in? The Actor returns JSON rows. You can export the dataset to CSV, JSON, Excel, or XML from the Apify console.
Do I need a data.gov.sg API key? No. The Actor reads the public CKAN API, which does not require authentication or an API key.
How do I filter by a specific column? Use the filters input with a JSON object. For example, {"town":"BISHAN","flat_type":"4 ROOM"} returns only rows matching those exact values.
Is there a limit to how many rows I can get? You can set maxItems up to 1,000,000. The actual number depends on the dataset size and the API's pagination limits.
Can I search for a keyword across all fields? Yes. The searchQuery input performs a full-text search on the dataset, returning rows where any field contains your term.
What if the dataset has nested fields? The Actor flattens the response into a flat object. Nested structures are returned as stringified JSON within the row.
Does this work for real-time datasets like carpark availability? Yes. You can point it at any dataset on data.gov.sg, including real-time ones, and schedule the Actor to run every few minutes.
Can I use this for commercial projects? The data is provided by the Singapore government under open licence terms. Check the specific dataset's licence on data.gov.sg for commercial use.

Related actors

Browse the full ParseForge collection for more scrapers.

๐Ÿ†˜ Need help? Email parseforge@protonmail.com with your run ID, your input, and what you expected.

โš ๏ธ Disclaimer. This Actor is unofficial and is not affiliated with, endorsed by, or sponsored by Government Technology Agency (GovTech). It collects only publicly available data. You are responsible for using the collected data in compliance with the source's terms of service and applicable data-protection laws, including GDPR, CCPA, and PIPL. Do not use it to collect personal data unlawfully.

Input

FieldTypeWhat it doesDefault
maxItems integer How many datasets to collect per run. 10
resourceId required string Dataset resource identifier from data.gov.sg. Example: d_8b84c4ee58e3cfc0ece0d773c8ca6abc (HDB resale flat prices). d_8b84c4ee58e3cfc0ece0d773c8ca6abc
searchQuery string Full-text search across all fields. Leave blank to return all rows. not set
filters object Exact-match filters as a JSON object. Example: {"town":"BISHAN","flat_type":"4 ROOM"}. not set

Pricing

from $14.00 per 1,000 results

Charged forWhat it isPrice each
Result Item Charged once per result collected. $0.014 to $0.01867

Tiered: the lower figure is the price on a higher Apify plan. Billing and the free credit live on Apify.

API

One POST returns the dataset directly. Same shape for every scraper in the library, so swapping the slug is the only change.

POST ยท run and get results
curl -X POST "https://api.apify.com/v2/acts/parseforge~singapore-data-gov-sg-scraper/run-sync-get-dataset-items?token=$APIFY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "helloWorld": 123
  }'

Examples

Input that runs as-is.

input.json
{
  "helloWorld": 123
}

Reviews

No reviews yet. Be the first.

Issues

We build and maintain this scraper, so a problem with it comes to us. Report it on the Apify listing and the thread stays attached to the scraper where the next person can find it: open an issue.

Broken and urgent, or you would rather not post in public? Write to parseforge@protonmail.com and it reaches the people who wrote it.

Related scrapers

Run Singapore Open Data Scraper on Apify All scrapers