Home > Geopedia API > markers


Controls the map markers, which are symbols placed on some geographic position on the map. If map is moved, the markers are moved with it.

Command JSON members:

  • command: markers,
  • operation: operation string (see below),
  • x: x coordinate number,
  • y: y coordinate number
  • index: <marker index, zero based>

"operation" can be one of the following:

  • add: waits for the user to mouse click to add a new marker
  • addXY: uses x and y members
  • remove: uses index member
  • clear: clears markers
  • get: returns a list of markers, same as "execute" command "getMarkers"

"get" operation returns:

  • markers: [<list of markers>] where markers consist of {x:<x>, y:<y>} pairs

No response is returned, except for "get" operation.



     {"x":123.456,"y":987.654}, {"x":111.222,"y":333.444}