The directory, ready to use.
A public, read-only JSON API for the same records used by WC Finder. No account, API key or installation required.
Download the manifest for the current record count, snapshot and file sizes.
Endpoints
All paths below are relative to /wc-finder/api/v1/.
GET index.json- Current snapshot identifier, record count, source update metadata, page links, download sizes and SHA-256 checksums.
GET toilets.json- Every bundled record in a
toiletsarray, plus original directory metadata,apiVersionandsnapshot. This is a large download. GET toilets.json.gz- The same JSON as a gzip file. Download and decompress explicitly; this endpoint does not return parsed JSON.
GET snapshots/{snapshot}/pages/{page}.json- Up to 1,000 records per page. Start with the manifest's
links.firstPageand follownextuntil it isnull. Resolve each relative link against the URL of the document containing it.
Read pages in JavaScript
const base = 'https://saschb2b.github.io/wc-finder/api/v1/';
async function json(url) {
const response = await fetch(url);
if (!response.ok) throw new Error(`HTTP ${response.status}`);
return response.json();
}
const manifestURL = new URL('index.json', base);
const manifest = await json(manifestURL);
let url = new URL(manifest.links.firstPage, manifestURL);
while (url) {
const page = await json(url);
if (page.snapshot !== manifest.snapshot) throw new Error('Snapshot changed');
// Use page.toilets here; filter by coordinates, tags or equipment locally.
console.log(page.toilets);
url = page.next ? new URL(page.next, url) : null;
}
Download everything
curl --fail --location \
https://saschb2b.github.io/wc-finder/api/v1/toilets.json.gz \
--output toilets.json.gz
gzip --decompress toilets.json.gz
Data and updates
- All existing fields are preserved, including accessibility tags, opening hours, care equipment, availability dates, access notes and source attribution where present. Optional fields can be absent.
- Coordinates use WGS84 latitude and longitude. Opening-hour schedules use Sunday = 0 through Saturday = 6, with periods in minutes from midnight. Stored
isOpenNowvalues are historical; calculate status using the schedule and availability dates. - Counts describe records, not verified distinct accessible public facilities. Legacy duplicate IDs and uncertain accessibility labels remain in the directory. Eurokey access alone does not establish wheelchair accessibility.
- Updates appear after website deployments.
builtAtis the export time; original source dates stay in the data. This is not live opening or closure information. - Check the manifest's
snapshotbefore downloading again. Page URLs identify a snapshot so separate releases cannot silently mix. Old snapshots are not archived: if a page returns 404 after a deployment, reload the manifest and restart.
Hosting and reuse
The API consists of static HTTPS resources on GitHub Pages. GET and HEAD work without authentication; browser fetches from other origins are allowed. There are no write operations or server-side queries. Parameters such as ?bbox=, ?limit= or ?page= are ignored. Missing resources return GitHub's HTML 404 page.
Cache downloads and use pages or the gzip export for larger imports. Hosting limits and HTTP cache headers are controlled by GitHub Pages; this API has no availability guarantee or per-client rate-limit controls.
Source-specific data terms apply. Preserve sources, care.sourceUrls and available attribution. The project's MIT licence covers app code and does not replace the original data terms; older records may lack per-record licence metadata. See the source and licence guide.
Found incorrect data? Report it on GitHub.