Hi,
could be interesting for someone on this list as well.
I extended JOSM RemoteControl to provide protocol version information. Besides the possibility for clients to choose a compatible command set this enables web pages to query for a running JOSM.
Because of restrictions due to same origin policy this was not possible with the existing plugin. RemoteControl now implements CORS (simple requests without preflight) as well as jsonp for the version check.
I implemented a live demo on the cuisine map. In the upper right corner will be an edit button in case a running RemoteCotnrol is detected.
http://toolserver.org/~stephankn/cuisine/
The new API command is documented on the wiki: http://wiki.openstreetmap.org/wiki/JOSM/Plugins/RemoteControl
Stephan