On Tue, 28 Apr 2015 17:14:57 GMT, Dato wrote:

Also, I forgot to ask, does @before means that authenticate will be invoked before any REST API call? I mean, if I invoke getSecret for example, vibed will invoke authenticate and getSecret after that? In this case(if my definition is true), what's the purpose of returning an User object from authenticate? Who will see that object..?

Before only applies to the function it annotate. As mentionned in my other reply, the object will be passed as a parameter.
Please don't forget that authenticate needs to be trivial or you'll run into issues.