You cannot do this directly using the user APIs, but see this question for alternative options:
Instead of using the UserService API to log out, you can manually delete the specific AppEngine cookies that are installed. Check out this blog post for a discussion of how to do this (written in Python, but you should be able to modify it for Java). This should effectively bring the user out of their own application, but not from other Google services (although I have not tested this myself).
A more robust approach would be to create your own user class and manage your own session cookies when wrapping the UserService API. The disadvantage of this approach is the additional work required to configure it, compared to the very easy to use UserService API. However, the advantage of supporting your own users is that you can use authentication methods other than Google (for example, now you can also use your Facebook account or even your own login if you decide to set this up).
source share