{"id":20657601,"url":"https://github.com/emilioriosvz/openstreetmap-geojson","last_synced_at":"2026-04-21T01:32:10.157Z","repository":{"id":40751686,"uuid":"163680670","full_name":"emilioriosvz/openstreetmap-geojson","owner":"emilioriosvz","description":"🤩🗺 Get GeoJSON from OpenStreetMaps","archived":false,"fork":false,"pushed_at":"2022-06-24T21:23:25.000Z","size":133,"stargazers_count":2,"open_issues_count":6,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-17T11:31:56.992Z","etag":null,"topics":["api","geojson","maps","openstreetmap","openstreetmap-data","osm","osm-data"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/emilioriosvz.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-12-31T15:51:44.000Z","updated_at":"2023-12-20T20:12:58.000Z","dependencies_parsed_at":"2022-07-29T07:59:19.359Z","dependency_job_id":null,"html_url":"https://github.com/emilioriosvz/openstreetmap-geojson","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emilioriosvz%2Fopenstreetmap-geojson","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emilioriosvz%2Fopenstreetmap-geojson/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emilioriosvz%2Fopenstreetmap-geojson/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emilioriosvz%2Fopenstreetmap-geojson/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/emilioriosvz","download_url":"https://codeload.github.com/emilioriosvz/openstreetmap-geojson/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242768074,"owners_count":20182098,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","geojson","maps","openstreetmap","openstreetmap-data","osm","osm-data"],"created_at":"2024-11-16T18:21:47.722Z","updated_at":"2025-12-13T13:10:28.900Z","avatar_url":"https://github.com/emilioriosvz.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# openstreetmap-geojson\nGet the geojsons from openstreetmaps\n\n## Install\n```\nnpm install openstreetmap-geojson\n```\n\n## How to use?\nIf you just need one geojson you can do that:\n\n```js\nconst osm = require('openstreetmap-geojson')\n\n// 347950 is the osm relation id for Barcelona\nconst geojson = await osm.getGeoJSON(347950)\n  .catch(console.error)\n```\n\nIf you are going to need more than one Geojson, consider using this function so as not to abuse the api\n\n```js\nconst osm = require('openstreetmap-geojson')\n\nconst ids = [340783, 342563, 3657693, 344522, 347950]\n\nconst geojsons = await Promise.all(ids.map(id =\u003e osm.getGeoJSONPolitely(id, 200)))\n```\n\n## API\n\n### `.getGeoJSON(osmId)`\nGiven a osm relation id returns a Promise that resolves with the GeoJSON.\n\n### `.getGeoJSONPolitely(osmId, milliseconds)`\nWait the indicated milliseconds and then Given a osm relation id returns a Promise that resolves with the GeoJSON.\n\n## Todo\n* Tests","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femilioriosvz%2Fopenstreetmap-geojson","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Femilioriosvz%2Fopenstreetmap-geojson","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femilioriosvz%2Fopenstreetmap-geojson/lists"}