On Wed, 04 Nov 2015 08:07:18 GMT, Sönke Ludwig wrote:

The REST interface generator is generally designed to enforce the RESTful aspects of the interface as far as possible. Since REST requests are supposed to be state-less, sessions are not directly supported.

However, you could (ab)use the @before attribute to get the desired effect:

[snip]

One problem I hit trying this was that serveRestJSClient requires an interface (without the session argument) and the implementation of the interface doesn't match the signature because of the additional argument from @before. Not sure if there is a way around this.

But this sounds like we should put some effort into fully supporting JSON based routes in the web interface generator. Return values of type Json are already supported, but not much more than that.

That would be nice.

Also nice would be some sort of authentication scheme for the REST stuff. I'm new to REST and nobody seems to agree on how this should be done but tokens seem to be popular. OAuth, too, of course.

For now I think I'll move back to the Web interface to get around these issues.

Someone in the IRC channel mentioned userman. The Readme says "A major revision of the source code is currently underway. More instructions will be added in that process." Does that mean it's not ready for any sort of use yet? I don't mind breaking changes as my use case is extremely simple.