It seems that using the javascript XML RPC client (there is a jquery plugin for this) along with the XML RPC server is a good way.
The jquery plugin will introspect your rpc service and populate the method names, which makes it impossible for the method name to be called incorrectly without an early warning. However, it will not check the number of arguments you pass, or their type.
It seems that there is no such support for introspection on json rpc (or rather, there is no agreed standard). This approach can also be used with django.
I compiled an example code and uploaded it here (I hope that a link to one blog post is not considered a terrible form - a brief search on the Internet did not seem to suggest that it was ...)
source share