Please go to browser and add token in front of any service for which token is generated to access as per below example. You find the user name on the top right corner of the rest end point service marked in screen capture provided below.
In Java Script API, you can try the following:
Use method findCredential() in "IdentityManager" which will return "credential". Then get user information using "userId" from credential property.