NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum

Hi. I use osmium for export map.osm to map.geojson (use in mobile app). How can i add node id to geojson file?

My code:

osmium export map.osm -o data.geojson

asked 12 Oct '22, 11:55

kadi4's gravatar image

kadi4
36112
accept rate: 100%


I close ticket.

I edit config file:

"id":        true,

and then:

osmium export -c config map.osm -o data.geojson

Result:

{"type":"Feature","geometry":{"type":"Point","coordinates":[40.5024238,55.9909894]},"properties":{"@id":1562589184,"power":"tower"}}
permanent link

answered 12 Oct '22, 12:39

kadi4's gravatar image

kadi4
36112
accept rate: 100%

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×38

question asked: 12 Oct '22, 11:55

question was seen: 1,059 times

last updated: 12 Oct '22, 12:39

NOTICE: help.openstreetmap.org is no longer in use from 1st March 2024. Please use the OpenStreetMap Community Forum