Javascript Client - SurrealTools/Documentation GitHub Wiki
Get User
So once you have signed in and got the token you can get the user info as follows...
let token = await db.signin({
NS: "purelygigs",
DB: "purelygigs",
SC: "allusers",
email,
password,
});
let user = await db.info();
console.log(user);
// You can also do the following, which is almost the same thing
let auth = await db.query('SELECT * FROM $auth');
console.log(auth);