Changes between Version 13 and Version 14 of Help/RemoteControlCommands


Ignore:
Timestamp:
2020-06-09T14:31:35+02:00 (4 years ago)
Author:
skyper
Comment:

add info about new_layer #19308; center one table column

Legend:

Unmodified
Added
Removed
Modified
  • Help/RemoteControlCommands

    v13 v14  
    44
    55== List of Commands ==
    6 
    76A complete list of commands and mandatory/optional parameters is shown at http://127.0.0.1:8111/ (when JOSM is running).
    87
     
    1312}}}
    1413where
    15 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    16 || `bottom` || R || Minimum latitude ||
    17 || `top` || R || Maximum latitude ||
    18 || `left` || R || Minimum longitude ||
    19 || `right` || R || Maximum longitude ||
    20 || `new_layer` || O || If '''true''', downloads to a new layer ||
    21 || `layer_name` || O || Only valid when the data is loaded in a new layer; Gives JOSM a hint on how to name the layer ||
    22 || `layer_locked` || O || Only valid when the data is loaded in a new layer; If '''true''', new layer is [[Action/LockedLayer|locked]] ||
    23 || `download_policy` || O || Only valid when the data is loaded in a new layer; If '''never''' , download is [[Help/Action/BlockDownload|blocked]] ||
    24 || `upload_policy` || O || Only valid when the data is loaded in a new layer; If '''never''' or '''false''', upload is [[Help/Action/EncourageDiscourageUpload|blocked or discouraged]] ||
    25 || `addtags` || O || Optional parameter to add tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". See [#addtags details]. ||
    26 || `select` || O || Comma-separated list of objects that should be selected. Object specifiers are combinations of the words "way", "node", or "relation", and the numerical object id. Example: {{{select=way38473,node12399,node54646}}}. Since r13212 the special value **currentselection** let JOSM keep its previous selection. ||
    27 || `zoom_mode` || O || '''download''' | '''selection''', defaults to selection ||
    28 || `changeset_comment` || O || Comment of the changeset ||
    29 || `changeset_source` || O || Source of the changeset ||
    30 || `changeset_hashtags` || O || Hashtags of the changeset (since r13109) ||
    31 || `changeset_tags` || O || Optional parameter to add changeset tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". This command uses the same syntax as the [#addtags addtags] parameter. `changeset_comment` and `changeset_source` currently override the `comment` and `source` tags passed in this parameter, but this may change in the future. First available in r15316. ||
    32 || `search` || O || Search objects in the current data layer. See [wiki:/Help/Action/Search Search] ||
    33 
    34 ==== Example ====
    35 
     14||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     15|| `bottom` ||  R  || Minimum latitude ||
     16|| `top` ||  R  || Maximum latitude ||
     17|| `left` ||  R  || Minimum longitude ||
     18|| `right` ||  R  || Maximum longitude ||
     19|| `new_layer` ||  O  || If '''true''', downloads to a new layer. (Overwrites user preference, see #19308) ||
     20|| `layer_name` ||  O  || Only valid when the data is loaded in a new layer; Gives JOSM a hint on how to name the layer ||
     21|| `layer_locked` ||  O  || Only valid when the data is loaded in a new layer; If '''true''', new layer is [[Action/LockedLayer|locked]] ||
     22|| `download_policy` ||  O  || Only valid when the data is loaded in a new layer; If '''never''' , download is [[Help/Action/BlockDownload|blocked]] ||
     23|| `upload_policy` ||  O  || Only valid when the data is loaded in a new layer; If '''never''' or '''false''', upload is [[Help/Action/EncourageDiscourageUpload|blocked or discouraged]] ||
     24|| `addtags` ||  O  || Optional parameter to add tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". See [#addtags details]. ||
     25|| `select` ||  O  || Comma-separated list of objects that should be selected. Object specifiers are combinations of the words "way", "node", or "relation", and the numerical object id. Example: {{{select=way38473,node12399,node54646}}}. Since r13212 the special value **currentselection** let JOSM keep its previous selection. ||
     26|| `zoom_mode` ||  O  || '''download''' | '''selection''', defaults to selection ||
     27|| `changeset_comment` ||  O  || Comment of the changeset ||
     28|| `changeset_source` ||  O  || Source of the changeset ||
     29|| `changeset_hashtags` ||  O  || Hashtags of the changeset (since r13109) ||
     30|| `changeset_tags` ||  O  || Optional parameter to add changeset tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". This command uses the same syntax as the [#addtags addtags] parameter. `changeset_comment` and `changeset_source` currently override the `comment` and `source` tags passed in this parameter, but this may change in the future. First available in r15316. ||
     31|| `search` ||  O  || Search objects in the current data layer. See [wiki:/Help/Action/Search Search] ||
     32
     33==== Example ====
    3634Start JOSM (don't forget to enable the !RemoteControl feature), then click on:
    3735
     
    3937
    4038JOSM should now load an area in the German Schwarzwald and have the specified node selected.
     39
    4140
    4241=== {{{zoom}}} ===
     
    4847
    4948**Hint**: This command can also be used to select objects only. Just enter a small arbitrary area to the left..bottom entries and add the object list to the select= option.
     49
    5050=== {{{import}}} ===
    5151Instructs JOSM to download the specified OSM file and add it to the current data set.
     
    5454}}}
    5555where
    56 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    57 || `url` || R || The Request URL, including patterns. Must be the last parameter, everything after "&url=" is interpreted as URL, even if it contains "&" characters. ||
    58 || `new_layer` || O || If '''true''', downloads to a new layer ||
    59 || `layer_name` || O || Only valid when the data is loaded in a new layer; Gives JOSM a hint on how to name the layer ||
    60 || `layer_locked` || O || Only valid when the data is loaded in a new layer; If '''true''', new layer is [[Action/LockedLayer|locked]] ||
    61 || `download_policy` || O || Only valid when the data is loaded in a new layer; If '''never''' , download is [[Help/Action/BlockDownload|blocked]] ||
    62 || `upload_policy` || O || Only valid when the data is loaded in a new layer; If '''never''' or '''false''', upload is [[Help/Action/EncourageDiscourageUpload|blocked or discouraged]] ||
    63 || `changeset_tags` || O || Optional parameter to add changeset tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". This command uses the same syntax as the [#addtags addtags] parameter. First available in r16324. ||
     56||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     57|| `url` ||  R || The Request URL, including patterns. Must be the last parameter, everything after "&url=" is interpreted as URL, even if it contains "&" characters. ||
     58|| `new_layer` ||  O  || If '''true''', downloads to a new layer. (Overwrites user preference, see #19308) ||
     59|| `layer_name` ||  O || Only valid when the data is loaded in a new layer; Gives JOSM a hint on how to name the layer ||
     60|| `layer_locked` ||  O || Only valid when the data is loaded in a new layer; If '''true''', new layer is [[Action/LockedLayer|locked]] ||
     61|| `download_policy` ||  O || Only valid when the data is loaded in a new layer; If '''never''' , download is [[Help/Action/BlockDownload|blocked]] ||
     62|| `upload_policy` ||  O || Only valid when the data is loaded in a new layer; If '''never''' or '''false''', upload is [[Help/Action/EncourageDiscourageUpload|blocked or discouraged]] ||
     63|| `changeset_tags` ||  O || Optional parameter to add changeset tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". This command uses the same syntax as the [#addtags addtags] parameter. First available in r16324. ||
    6464
    6565=== {{{load_data}}} ===
     
    7171}}}
    7272where
    73 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    74 || `data` || R || The XML data to load, this should be URL encoded in a way that also encodes the special characters &, = and ? to resp. %26, %3D and %3F. The JS [https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/encodeURIComponent encodeUriComponent()] method provides this functionality out of the box. ||
    75 || `new_layer` || O || Chose to load the data in a new layer ||
    76 || `mime_type` || O || Mime type of the data, by default this is "application/x-osm+xml", which is currently the only supported mime type, but in the future other mime types could be supported ||
    77 || `layer_name` || O || Only valid when the data is loaded in a new layer; Gives JOSM a hint on how to name the layer ||
    78 || `layer_locked` || O || Only valid when the data is loaded in a new layer; If '''true''', new layer is [[Action/LockedLayer|locked]] ||
    79 || `download_policy` || O || Only valid when the data is loaded in a new layer; If '''never''' , download is [[Help/Action/BlockDownload|blocked]] ||
    80 || `upload_policy` || O || Only valid when the data is loaded in a new layer; If '''never''' or '''false''', upload is [[Help/Action/EncourageDiscourageUpload|blocked or discouraged]] ||
     73||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     74|| `data` ||  R || The XML data to load, this should be URL encoded in a way that also encodes the special characters &, = and ? to resp. %26, %3D and %3F. The JS [https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/encodeURIComponent encodeUriComponent()] method provides this functionality out of the box. ||
     75|| `new_layer` ||  O  || Choose to load the data in a new layer. (Overwrites user preference, see #19308) ||
     76|| `mime_type` ||  O || Mime type of the data, by default this is "application/x-osm+xml", which is currently the only supported mime type, but in the future other mime types could be supported ||
     77|| `layer_name` ||  O || Only valid when the data is loaded in a new layer; Gives JOSM a hint on how to name the layer ||
     78|| `layer_locked` ||  O || Only valid when the data is loaded in a new layer; If '''true''', new layer is [[Action/LockedLayer|locked]] ||
     79|| `download_policy` ||  O || Only valid when the data is loaded in a new layer; If '''never''' , download is [[Help/Action/BlockDownload|blocked]] ||
     80|| `upload_policy` ||  O || Only valid when the data is loaded in a new layer; If '''never''' or '''false''', upload is [[Help/Action/EncourageDiscourageUpload|blocked or discouraged]] ||
    8181
    8282=== {{{open_file }}} ===
     
    8787}}}
    8888where
    89 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    90 || `filename` || R || The local file to open in JOSM (Ie: /tmp/test.osm) ||
     89||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     90|| `filename` ||  R || The local file to open in JOSM (Ie: /tmp/test.osm) ||
    9191
    9292
     
    9797}}}
    9898where
    99 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    100 || `url` || R || The Request URL, including patterns. Must be the last parameter, everything after "&url=" is interpreted as URL, even if it contains "&" characters.  ||
    101 || `title` || O || The display name of the layer ||
    102 || `type` || O || Type of the layer. Possible values are `wms`, `tms` and `bing` [[BR]] (since !RemoteControl Version 1.3) ||
    103 || `cookies` || O ||  ||
    104 || `min_zoom` || O || The minimum zoom level [[BR]] (since !RemoteControl Version 1.4) ||
    105 || `max_zoom` || O || The maximum zoom level. For higher scales, the images of the maximum level is enlarged [[BR]] (since !RemoteControl Version 1.4) ||
     99||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     100|| `url` ||  R || The Request URL, including patterns. Must be the last parameter, everything after "&url=" is interpreted as URL, even if it contains "&" characters.  ||
     101|| `title` ||  O || The display name of the layer ||
     102|| `type` ||  O || Type of the layer. Possible values are `wms`, `tms` and `bing` [[BR]] (since !RemoteControl Version 1.3) ||
     103|| `cookies` ||  O ||  ||
     104|| `min_zoom` ||  O || The minimum zoom level [[BR]] (since !RemoteControl Version 1.4) ||
     105|| `max_zoom` ||  O  || The maximum zoom level. For higher scales, the images of the maximum level is enlarged \\ (since !RemoteControl Version 1.4) ||
    106106
    107107
     
    117117[http://localhost:8111/imagery?title=landsat&type=wms&url=http://irs.gis-lab.info/?layers=landsat&SRS=%7Bproj%7D&WIDTH=%7Bwidth%7D&HEIGHT=%7Bheight%7D&BBOX=%7Bbbox%7D]
    118118
     119
    119120=== {{{load_object}}} ===
    120 
    121121Instructs JOSM to download objects with a given id.
    122122{{{
     
    124124}}}
    125125where
    126 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    127 || `objects` || R || Comma separated list of object ids, e.g. "{{{n1234,n1235,w84,r958493}}}" ||
    128 || `new_layer` || O || If '''true''', downloads to a new layer ||
    129 || `addtags` || O || Optional parameter to add tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". See [#addtags details]. ||
    130 || `relation_members` || O || If '''true''', downloads objects members of the relations as well. ||
    131 || `referrers` || O || If '''true''', downloads referrers of the object as well. I.e. parent relations, and for nodes, additionally, parent ways. (since r6782) ||
    132 || `layer_name` || O || Only valid when the data is loaded in a new layer; Gives JOSM a hint on how to name the layer ||
    133 || `layer_locked` || O || Only valid when the data is loaded in a new layer; If '''true''', new layer is [[Action/LockedLayer|locked]] ||
    134 || `download_policy` || O || Only valid when the data is loaded in a new layer; If '''never''' , download is [[Help/Action/BlockDownload|blocked]] ||
    135 || `upload_policy` || O || Only valid when the data is loaded in a new layer; If '''never''' or '''false''', upload is [[Help/Action/EncourageDiscourageUpload|blocked or discouraged]] ||
    136 
    137 ==== Example ====
    138 
     126||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     127|| `objects` ||  R  || Comma separated list of object ids, e.g. "{{{n1234,n1235,w84,r958493}}}" ||
     128|| `new_layer` ||  O  || If '''true''', downloads to a new layer. (Overwrites user preference, see #19308) ||
     129|| `addtags` ||  O  || Optional parameter to add tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". See [#addtags details]. ||
     130|| `relation_members` ||  O  || If '''true''', downloads objects members of the relations as well. ||
     131|| `referrers` ||  O  || If '''true''', downloads referrers of the object as well. I.e. parent relations, and for nodes, additionally, parent ways. (since r6782) ||
     132|| `layer_name` ||  O  || Only valid when the data is loaded in a new layer; Gives JOSM a hint on how to name the layer ||
     133|| `layer_locked` ||  O  || Only valid when the data is loaded in a new layer; If '''true''', new layer is [[Action/LockedLayer|locked]] ||
     134|| `download_policy` ||  O  || Only valid when the data is loaded in a new layer; If '''never''' , download is [[Help/Action/BlockDownload|blocked]] ||
     135|| `upload_policy` ||  O  || Only valid when the data is loaded in a new layer; If '''never''' or '''false''', upload is [[Help/Action/EncourageDiscourageUpload|blocked or discouraged]] ||
     136
     137==== Example ====
    139138[http://localhost:8111/load_object?new_layer=true&objects=w106159509]
    140139
     140
    141141=== {{{add_node}}} ===
    142 
    143142Instructs JOSM to create a new node at the given coordinates.
    144143
     
    149148}}}
    150149where
    151 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    152 || `lon` || R || The longitude of the node ||
    153 || `lat` || R || The latitude of the node ||
    154 || `addtags` since v1.5|| O || Optional parameter to add tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". See [#addtags details]. ||
     150||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     151|| `lon` ||  R || The longitude of the node ||
     152|| `lat` ||  R || The latitude of the node ||
     153|| `addtags` \\ ''(since v1.5)'' ||  O || Optional parameter to add tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". See [#addtags details]. ||
    155154
    156155==== Example ====
    157156http://localhost:8111/add_node?lon=13.3&lat=53.2
    158157
     158
    159159=== {{{add_way}}} ===
    160 
    161160Instructs JOSM to create a new way with new way nodes at given coordinates.
    162161
     
    167166}}}
    168167where
    169 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    170 || `way` || R || Pairs of latitude, longitude coordinates separated by semicolon. ||
    171 || `addtags` since v1.5|| O || Optional parameter to add tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". See [#addtags details]. ||
    172 
    173 ==== Example ====
    174 
     168||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     169|| `way` ||  R  || Pairs of latitude, longitude coordinates separated by semicolon. ||
     170|| `addtags` ''(since v1.5)'' ||  O  || Optional parameter to add tags. The key and value is separated by "=" and multiple tags can be separated by a Pipe "|". See [#addtags details]. ||
     171
     172==== Example ====
    175173http://localhost:8111/add_way?way=53.2,13.3;53.3,13.3;53.3,13.2
    176174
     
    178176=== {{{version}}} ===
    179177This command returns the current protocol version of the installed !RemoteControl interface. Developers can use it to query for a running instance of JOSM and also determine whether the requested functionality is available in the client.
     178
    180179{{{
    181180GET /version[?jsonp=callback]
    182181}}}
    183182where
    184 ||= **Parameter** =||= **Required/Optional** =||= **Meaning** =||
    185 || `jsonp` || O|| Jsonp callback for older browsers not implementing ​Cross-Origin Resource Sharing (CORS) ||
     183||= **Parameter** =||= **Required/ \\ Optional** =||= **Meaning** =||
     184|| `jsonp` ||  O  || Jsonp callback for older browsers not implementing ​Cross-Origin Resource Sharing (CORS) ||
    186185
    187186The command returns a json object containing an application identifier that is always "JOSM !RemoteControl", a major number and a minor number. Compatible protocol changes result in an increase of the minor number. Incompatible changes increase the major number. So a client application knowing of protocol version 1.0 can still talk to JOSM having 1.1. But it's not guaranteed to be working with 2.0. So the client should verify the major number.
     
    279278
    280279----
    281 
    282 Back to [[Help/Preferences/RemoteControl]][[br]]
    283 Back to [[Help/Preferences]][[br]]
    284 Back to [[Help]]
     280Back to [wikitr:/Help/Preferences/RemoteControl Remote control preferences] \\
     281Back to [wikitr:/Help/Preferences Preferences] \\
     282Back to [wikitr:/Help Main Help]